summaryrefslogtreecommitdiff
authorzecke <zecke>2004-03-14 18:05:28 (UTC)
committer zecke <zecke>2004-03-14 18:05:28 (UTC)
commit9e54b8bd8343af7c301da17d82596d6027e53309 (patch) (side-by-side diff)
tree693613ff9f1a0f3415e0623e636d47ac4798da2d
parent98bbe5561e8e1a862e19a3d0a0d49ed90ef15b54 (diff)
downloadopie-9e54b8bd8343af7c301da17d82596d6027e53309.zip
opie-9e54b8bd8343af7c301da17d82596d6027e53309.tar.gz
opie-9e54b8bd8343af7c301da17d82596d6027e53309.tar.bz2
OpiePlayer -> ODP
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--core/multimedia/opieplayer/audiowidget.cpp1
-rw-r--r--core/multimedia/opieplayer/audiowidget.h4
-rw-r--r--core/multimedia/opieplayer/config.in2
-rw-r--r--core/multimedia/opieplayer/inputDialog.cpp3
-rw-r--r--core/multimedia/opieplayer/libflash/libflashpluginimpl.cpp2
-rw-r--r--core/multimedia/opieplayer/libmad/libmadpluginimpl.cpp2
-rw-r--r--core/multimedia/opieplayer/libmpeg3/libmpeg3pluginimpl.cpp2
-rw-r--r--core/multimedia/opieplayer/modplug/modpluginimpl.cpp2
-rw-r--r--core/multimedia/opieplayer/opieplayer.pro2
-rw-r--r--core/multimedia/opieplayer/videowidget.cpp6
-rw-r--r--core/multimedia/opieplayer/vorbis/libtremorpluginimpl.cpp2
-rw-r--r--core/multimedia/opieplayer/wavplugin/wavpluginimpl.cpp2
12 files changed, 23 insertions, 7 deletions
diff --git a/core/multimedia/opieplayer/audiowidget.cpp b/core/multimedia/opieplayer/audiowidget.cpp
index 8bcc567..7da2d54 100644
--- a/core/multimedia/opieplayer/audiowidget.cpp
+++ b/core/multimedia/opieplayer/audiowidget.cpp
@@ -25,24 +25,25 @@
#include "audiowidget.h"
#include "mediaplayerstate.h"
#include <stdlib.h>
#include <stdio.h>
extern MediaPlayerState *mediaPlayerState;
static const int xo = -2; // movable x offset
static const int yo = 22; // movable y offset
+using namespace Opie::Ui;
struct MediaButton {
bool isToggle, isHeld, isDown;
};
//Layout information for the audioButtons (and if it is a toggle button or not)
MediaButton audioButtons[] = {
{ TRUE, FALSE, FALSE }, // play
{ FALSE, FALSE, FALSE }, // stop
{ FALSE, FALSE, FALSE }, // next
{ FALSE, FALSE, FALSE }, // previous
{ FALSE, FALSE, FALSE }, // volume up
{ FALSE, FALSE, FALSE }, // volume down
diff --git a/core/multimedia/opieplayer/audiowidget.h b/core/multimedia/opieplayer/audiowidget.h
index 96bc55c..0a7cb26 100644
--- a/core/multimedia/opieplayer/audiowidget.h
+++ b/core/multimedia/opieplayer/audiowidget.h
@@ -22,25 +22,25 @@
#define AUDIO_WIDGET_H
#include <qwidget.h>
#include <qpainter.h>
#include <qdrawutil.h>
#include <qpixmap.h>
#include <qbitmap.h>
#include <qstring.h>
#include <qslider.h>
#include <qlineedit.h>
#include <qframe.h>
-#include <opie/oticker.h>
+#include <opie2/oticker.h>
class QPixmap;
enum AudioButtons {
AudioPlay=0,
AudioStop,
AudioNext,
AudioPrevious,
AudioVolumeUp,
AudioVolumeDown,
AudioLoop,
AudioPlayList,
@@ -97,22 +97,22 @@ private:
void setToggleButton( int, bool );
void paintButton( QPainter *p, int i );
QString skin;
QPixmap *pixBg;
QImage *imgUp;
QImage *imgDn;
QImage *imgButtonMask;
QBitmap *masks[11];
QPixmap *buttonPixUp[11];
QPixmap *buttonPixDown[11];
QPixmap *pixmaps[4];
- OTicker songInfo;
+ Opie::Ui::OTicker songInfo;
QSlider slider;
QLineEdit time;
int xoff, yoff;
};
#endif // AUDIO_WIDGET_H
diff --git a/core/multimedia/opieplayer/config.in b/core/multimedia/opieplayer/config.in
index dc1b79a..d25b11f 100644
--- a/core/multimedia/opieplayer/config.in
+++ b/core/multimedia/opieplayer/config.in
@@ -1,12 +1,12 @@
config OPIEPLAYER
boolean "opie-mediaplayer (mediaplayer that plays mp3, mpeg, and wav)"
default "y"
- depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE
+ depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIEUI2
source core/multimedia/opieplayer/libflash/config.in
source core/multimedia/opieplayer/libmad/config.in
source core/multimedia/opieplayer/libmpeg3/config.in
source core/multimedia/opieplayer/modplug/config.in
source core/multimedia/opieplayer/wavplugin/config.in
source core/multimedia/opieplayer/vorbis/tremor/config.in
source core/multimedia/opieplayer/vorbis/config.in
diff --git a/core/multimedia/opieplayer/inputDialog.cpp b/core/multimedia/opieplayer/inputDialog.cpp
index 38b8f53..44a1cdd 100644
--- a/core/multimedia/opieplayer/inputDialog.cpp
+++ b/core/multimedia/opieplayer/inputDialog.cpp
@@ -1,21 +1,22 @@
#include "inputDialog.h"
#include <qpe/resource.h>
-#include <opie/ofiledialog.h>
+#include <opie2/ofiledialog.h>
#include <qlineedit.h>
#include <qpushbutton.h>
+using namespace Opie::Ui;
InputDialog::InputDialog( QWidget* parent, const char* name, bool modal, WFlags fl )
: QDialog( parent, name, modal, fl ) {
if ( !name ) {
setName( "InputDialog" );
}
resize( 234, 115);
setMaximumSize( QSize( 240, 40));
setCaption( tr( name ) );
QPushButton *browserButton;
browserButton = new QPushButton( Resource::loadIconSet("fileopen"),"",this,"BrowseButton");
browserButton->setGeometry( QRect( 205, 10, 22, 22));
diff --git a/core/multimedia/opieplayer/libflash/libflashpluginimpl.cpp b/core/multimedia/opieplayer/libflash/libflashpluginimpl.cpp
index af2c07e..b2a1b5d 100644
--- a/core/multimedia/opieplayer/libflash/libflashpluginimpl.cpp
+++ b/core/multimedia/opieplayer/libflash/libflashpluginimpl.cpp
@@ -47,24 +47,26 @@ MediaPlayerEncoder *LibFlashPluginImpl::encoder()
return NULL;
}
#ifndef QT_NO_COMPONENT
QRESULT LibFlashPluginImpl::queryInterface( const QUuid &uuid, QUnknownInterface **iface )
{
*iface = 0;
if ( ( uuid == IID_QUnknown ) || ( uuid == IID_MediaPlayerPlugin ) )
*iface = this, (*iface)->addRef();
+ else
+ return QS_FALSE;
return QS_OK;
}
Q_EXPORT_INTERFACE()
{
Q_CREATE_INSTANCE( LibFlashPluginImpl )
}
#endif
diff --git a/core/multimedia/opieplayer/libmad/libmadpluginimpl.cpp b/core/multimedia/opieplayer/libmad/libmadpluginimpl.cpp
index 67779e8..b3e01e5 100644
--- a/core/multimedia/opieplayer/libmad/libmadpluginimpl.cpp
+++ b/core/multimedia/opieplayer/libmad/libmadpluginimpl.cpp
@@ -47,24 +47,26 @@ MediaPlayerEncoder *LibMadPluginImpl::encoder()
return NULL;
}
#ifndef QT_NO_COMPONENT
QRESULT LibMadPluginImpl::queryInterface( const QUuid &uuid, QUnknownInterface **iface )
{
*iface = 0;
if ( ( uuid == IID_QUnknown ) || ( uuid == IID_MediaPlayerPlugin ) )
*iface = this, (*iface)->addRef();
+ else
+ return QS_FALSE;
return QS_OK;
}
Q_EXPORT_INTERFACE()
{
Q_CREATE_INSTANCE( LibMadPluginImpl )
}
#endif
diff --git a/core/multimedia/opieplayer/libmpeg3/libmpeg3pluginimpl.cpp b/core/multimedia/opieplayer/libmpeg3/libmpeg3pluginimpl.cpp
index bf3f372..f6d34b8 100644
--- a/core/multimedia/opieplayer/libmpeg3/libmpeg3pluginimpl.cpp
+++ b/core/multimedia/opieplayer/libmpeg3/libmpeg3pluginimpl.cpp
@@ -47,24 +47,26 @@ MediaPlayerEncoder *LibMpeg3PluginImpl::encoder()
return NULL;
}
#ifndef QT_NO_COMPONENT
QRESULT LibMpeg3PluginImpl::queryInterface( const QUuid &uuid, QUnknownInterface **iface )
{
*iface = 0;
if ( ( uuid == IID_QUnknown ) || ( uuid == IID_MediaPlayerPlugin ) )
*iface = this, (*iface)->addRef();
+ else
+ return QS_FALSE;
return QS_OK;
}
Q_EXPORT_INTERFACE()
{
Q_CREATE_INSTANCE( LibMpeg3PluginImpl )
}
#endif
diff --git a/core/multimedia/opieplayer/modplug/modpluginimpl.cpp b/core/multimedia/opieplayer/modplug/modpluginimpl.cpp
index 6e64e76..6205779 100644
--- a/core/multimedia/opieplayer/modplug/modpluginimpl.cpp
+++ b/core/multimedia/opieplayer/modplug/modpluginimpl.cpp
@@ -28,24 +28,26 @@ ModPluginImpl::ModPluginImpl()
ModPluginImpl::~ModPluginImpl()
{
delete m_plugin;
}
#ifndef QT_NO_COMPONENT
QRESULT ModPluginImpl::queryInterface( const QUuid &uuid, QUnknownInterface **iface )
{
*iface = 0;
if ( ( uuid == IID_QUnknown ) || ( uuid == IID_MediaPlayerPlugin ) )
*iface = this, (*iface)->addRef();
+ else
+ return QS_FALSE;
return QS_OK;
}
Q_EXPORT_INTERFACE()
{
Q_CREATE_INSTANCE( ModPluginImpl )
}
#endif
MediaPlayerDecoder *ModPluginImpl::decoder()
{
diff --git a/core/multimedia/opieplayer/opieplayer.pro b/core/multimedia/opieplayer/opieplayer.pro
index 03d8a89..d7b0fb8 100644
--- a/core/multimedia/opieplayer/opieplayer.pro
+++ b/core/multimedia/opieplayer/opieplayer.pro
@@ -4,18 +4,18 @@ CONFIG = qt warn_on release
DESTDIR = $(OPIEDIR)/bin
HEADERS = loopcontrol.h mediaplayerplugininterface.h \
playlistselection.h mediaplayerstate.h \
videowidget.h audiowidget.h playlistwidget.h \
mediaplayer.h audiodevice.h inputDialog.h om3u.h
SOURCES = main.cpp \
loopcontrol.cpp playlistselection.cpp mediaplayerstate.cpp \
videowidget.cpp audiowidget.cpp playlistwidget.cpp \
mediaplayer.cpp audiodevice.cpp inputDialog.cpp om3u.cpp
TARGET = opieplayer
INCLUDEPATH += $(OPIEDIR)/include
DEPENDPATH += $(OPIEDIR)/include
-LIBS += -lqpe -lpthread -lopie
+LIBS += -lqpe -lpthread -lopieui2
INCLUDEPATH += $(OPIEDIR)/include
DEPENDPATH += $(OPIEDIR)/include
include ( $(OPIEDIR)/include.pro )
diff --git a/core/multimedia/opieplayer/videowidget.cpp b/core/multimedia/opieplayer/videowidget.cpp
index d002c42..164458b 100644
--- a/core/multimedia/opieplayer/videowidget.cpp
+++ b/core/multimedia/opieplayer/videowidget.cpp
@@ -556,28 +556,30 @@ bool VideoWidget::playVideo() {
for (int x=0; x<h; x++)
{
if ( bytes == 2 )
{
ushort* lout = out++ + (w - 1)*spl;
for (int y=0; y<w; y++) {
*lout=*in++;
lout-=spl;
}
}
else
{
- ulong* lout = ((ulong *)out)++ + (w - 1)*spl;
+ ulong* _out = (ulong *)out;
+ ulong* lout = _out++ + (w - 1)*spl;
for (int y=0; y<w; y++)
{
- *lout=*((ulong*)in)++;
+ ulong *_in = (ulong*)in;
+ *lout=*_in++;
lout-=spl;
}
}
}
p.drawImage( (240 - rw) / 2, (320 - rh) / 2, rotatedFrame, 0, 0, rw, rh );
}
#ifdef USE_DIRECT_PAINTER
}
#endif
}
else
diff --git a/core/multimedia/opieplayer/vorbis/libtremorpluginimpl.cpp b/core/multimedia/opieplayer/vorbis/libtremorpluginimpl.cpp
index 440747a..0c7b1ea 100644
--- a/core/multimedia/opieplayer/vorbis/libtremorpluginimpl.cpp
+++ b/core/multimedia/opieplayer/vorbis/libtremorpluginimpl.cpp
@@ -48,24 +48,26 @@ MediaPlayerEncoder *LibTremorPluginImpl::encoder()
return NULL;
}
#ifndef QT_NO_COMPONENT
QRESULT LibTremorPluginImpl::queryInterface( const QUuid &uuid, QUnknownInterface **iface )
{
*iface = 0;
if ( ( uuid == IID_QUnknown ) || ( uuid == IID_MediaPlayerPlugin ) )
*iface = this, (*iface)->addRef();
+ else
+ return QS_FALSE;
return QS_OK;
}
Q_EXPORT_INTERFACE()
{
Q_CREATE_INSTANCE( LibTremorPluginImpl )
}
#endif
diff --git a/core/multimedia/opieplayer/wavplugin/wavpluginimpl.cpp b/core/multimedia/opieplayer/wavplugin/wavpluginimpl.cpp
index c232d7b..4280880 100644
--- a/core/multimedia/opieplayer/wavplugin/wavpluginimpl.cpp
+++ b/core/multimedia/opieplayer/wavplugin/wavpluginimpl.cpp
@@ -46,24 +46,26 @@ MediaPlayerEncoder *WavPluginImpl::encoder()
return NULL;
}
#ifndef QT_NO_COMPONENT
QRESULT WavPluginImpl::queryInterface( const QUuid &uuid, QUnknownInterface **iface )
{
*iface = 0;
if ( ( uuid == IID_QUnknown ) || ( uuid == IID_MediaPlayerPlugin ) )
*iface = this, (*iface)->addRef();
+ else
+ return QS_FALSE;
return QS_OK;
}
Q_EXPORT_INTERFACE()
{
Q_CREATE_INSTANCE( WavPluginImpl )
}
#endif