summaryrefslogtreecommitdiff
path: root/core/multimedia/opieplayer/videowidget.cpp
Unidiff
Diffstat (limited to 'core/multimedia/opieplayer/videowidget.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/multimedia/opieplayer/videowidget.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/core/multimedia/opieplayer/videowidget.cpp b/core/multimedia/opieplayer/videowidget.cpp
index c545511..89dd89e 100644
--- a/core/multimedia/opieplayer/videowidget.cpp
+++ b/core/multimedia/opieplayer/videowidget.cpp
@@ -13,31 +13,32 @@
13 ** 13 **
14 ** See http://www.trolltech.com/gpl/ for GPL licensing information. 14 ** See http://www.trolltech.com/gpl/ for GPL licensing information.
15 ** 15 **
16 ** Contact info@trolltech.com if any conditions of this licensing are 16 ** Contact info@trolltech.com if any conditions of this licensing are
17 ** not clear to you. 17 ** not clear to you.
18 ** 18 **
19 **********************************************************************/ 19 **********************************************************************/
20 20
21#include "videowidget.h" 21#include "videowidget.h"
22#include "mediaplayerstate.h" 22#include "mediaplayerstate.h"
23 23
24/* OPIE */ 24/* OPIE */
25#include <qpe/resource.h>
26#include <qpe/mediaplayerplugininterface.h> 25#include <qpe/mediaplayerplugininterface.h>
27#include <qpe/config.h> 26#include <qpe/config.h>
28#include <qpe/qpeapplication.h> 27#include <qpe/qpeapplication.h>
29#include <opie2/odebug.h> 28#include <opie2/odebug.h>
29#include <opie2/oresource.h>
30 30
31/* QT */ 31/* QT */
32#include <qbitmap.h>
32#include <qdir.h> 33#include <qdir.h>
33#include <qslider.h> 34#include <qslider.h>
34 35
35 36
36#ifdef Q_WS_QWS 37#ifdef Q_WS_QWS
37# define USE_DIRECT_PAINTER 38# define USE_DIRECT_PAINTER
38# include <qdirectpainter_qws.h> 39# include <qdirectpainter_qws.h>
39# include <qgfxraster_qws.h> 40# include <qgfxraster_qws.h>
40#endif 41#endif
41 42
42 43
43extern MediaPlayerState *mediaPlayerState; 44extern MediaPlayerState *mediaPlayerState;
@@ -81,27 +82,27 @@ VideoWidget::VideoWidget(QWidget* parent, const char* name, WFlags f) :
81 82
82 cfg.setGroup("Options"); 83 cfg.setGroup("Options");
83 skin = cfg.readEntry("Skin","default"); 84 skin = cfg.readEntry("Skin","default");
84 85
85 QString skinPath; 86 QString skinPath;
86 skinPath = "opieplayer2/skins/" + skin; 87 skinPath = "opieplayer2/skins/" + skin;
87 if(!QDir(QString(getenv("OPIEDIR")) +"/pics/"+skinPath).exists()) 88 if(!QDir(QString(getenv("OPIEDIR")) +"/pics/"+skinPath).exists())
88 skinPath = "opieplayer2/skins/default"; 89 skinPath = "opieplayer2/skins/default";
89 90
90 91
91// QString skinPath = "opieplayer2/skins/" + skin; 92// QString skinPath = "opieplayer2/skins/" + skin;
92 93
93 pixBg = new QPixmap( Resource::loadPixmap( QString("%1/background").arg(skinPath) ) ); 94 pixBg = new QPixmap( Opie::Core::OResource::loadPixmap( QString("%1/background").arg(skinPath) ) );
94 imgUp = new QImage( Resource::loadImage( QString("%1/skinV_up").arg(skinPath) ) ); 95 imgUp = new QImage( Opie::Core::OResource::loadImage( QString("%1/skinV_up").arg(skinPath) ) );
95 imgDn = new QImage( Resource::loadImage( QString("%1/skinV_down").arg(skinPath) ) ); 96 imgDn = new QImage( Opie::Core::OResource::loadImage( QString("%1/skinV_down").arg(skinPath) ) );
96 97
97 imgButtonMask = new QImage( imgUp->width(), imgUp->height(), 8, 255 ); 98 imgButtonMask = new QImage( imgUp->width(), imgUp->height(), 8, 255 );
98 imgButtonMask->fill( 0 ); 99 imgButtonMask->fill( 0 );
99 100
100 for ( int i = 0; i < 7; i++ ) { 101 for ( int i = 0; i < 7; i++ ) {
101 QString filename = QString( QPEApplication::qpeDir() + "pics/" + skinPath + 102 QString filename = QString( QPEApplication::qpeDir() + "pics/" + skinPath +
102 "/skinV_mask_" + skinV_mask_file_names[i] + ".png" ); 103 "/skinV_mask_" + skinV_mask_file_names[i] + ".png" );
103 // odebug << "loading "+filename << oendl; 104 // odebug << "loading "+filename << oendl;
104 masks[i] = new QBitmap( filename ); 105 masks[i] = new QBitmap( filename );
105 106
106 if ( !masks[i]->isNull() ) { 107 if ( !masks[i]->isNull() ) {
107 QImage imgMask = masks[i]->convertToImage(); 108 QImage imgMask = masks[i]->convertToImage();