summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/multimedia/opieplayer/mediaplayerstate.cpp4
-rw-r--r--core/multimedia/opieplayer/playlistwidget.cpp12
2 files changed, 8 insertions, 8 deletions
diff --git a/core/multimedia/opieplayer/mediaplayerstate.cpp b/core/multimedia/opieplayer/mediaplayerstate.cpp
index a960c49..4e14436 100644
--- a/core/multimedia/opieplayer/mediaplayerstate.cpp
+++ b/core/multimedia/opieplayer/mediaplayerstate.cpp
@@ -33,32 +33,32 @@
#include "libmad/libmadpluginimpl.h"
#include "libmpeg3/libmpeg3pluginimpl.h"
#include "wavplugin/wavpluginimpl.h"
#endif
//#define MediaPlayerDebug(x) qDebug x
#define MediaPlayerDebug(x)
MediaPlayerState::MediaPlayerState( QObject *parent, const char *name )
: QObject( parent, name ), decoder( NULL ), libmpeg3decoder( NULL ) {
- Config cfg( "MediaPlayer" );
+ Config cfg( "OpiePlayer" );
readConfig( cfg );
loadPlugins();
}
MediaPlayerState::~MediaPlayerState() {
- Config cfg( "MediaPlayer" );
+ Config cfg( "OpiePlayer" );
writeConfig( cfg );
}
void MediaPlayerState::readConfig( Config& cfg ) {
cfg.setGroup("Options");
isFullscreen = cfg.readBoolEntry( "FullScreen" );
isScaled = cfg.readBoolEntry( "Scaling" );
isLooping = cfg.readBoolEntry( "Looping" );
isShuffled = cfg.readBoolEntry( "Shuffle" );
usePlaylist = cfg.readBoolEntry( "UsePlayList" );
usePlaylist = TRUE;
diff --git a/core/multimedia/opieplayer/playlistwidget.cpp b/core/multimedia/opieplayer/playlistwidget.cpp
index 4b1ff22..218fd49 100644
--- a/core/multimedia/opieplayer/playlistwidget.cpp
+++ b/core/multimedia/opieplayer/playlistwidget.cpp
@@ -280,37 +280,37 @@ populateVideoView();
connect( tabWidget, SIGNAL (currentChanged(QWidget*)),this,SLOT(tabChanged(QWidget*)));
connect( mediaPlayerState, SIGNAL( playingToggled( bool ) ), d->tbPlay, SLOT( setOn( bool ) ) );
connect( mediaPlayerState, SIGNAL( loopingToggled( bool ) ), d->tbLoop, SLOT( setOn( bool ) ) );
connect( mediaPlayerState, SIGNAL( shuffledToggled( bool ) ), d->tbShuffle, SLOT( setOn( bool ) ) );
connect( mediaPlayerState, SIGNAL( playlistToggled( bool ) ), this, SLOT( setPlaylist( bool ) ) );
connect( d->selectedFiles, SIGNAL( doubleClicked( QListViewItem *) ), this, SLOT( playIt( QListViewItem *) ) );
// connect( d->selectedFiles, SIGNAL( fileSelected( const DocLnk & ) ), this, SLOT( addToSelection( const DocLnk & ) ) );
setCentralWidget( vbox5 );
- Config cfg( "MediaPlayer" );
+ Config cfg( "OpiePlayer" );
readConfig( cfg );
QString currentPlaylist = cfg.readEntry("CurrentPlaylist","");
// qDebug("currentList is "+currentPlaylist);
loadList(DocLnk( currentPlaylist));
setCaption(tr("OpiePlayer: ")+ currentPlaylist );
initializeStates();
}
PlayListWidget::~PlayListWidget() {
- Config cfg( "MediaPlayer" );
+ Config cfg( "OpiePlayer" );
writeConfig( cfg );
if ( d->current )
delete d->current;
delete d;
}
void PlayListWidget::initializeStates() {
d->tbPlay->setOn( mediaPlayerState->playing() );
@@ -616,68 +616,68 @@ void PlayListWidget::saveList() {
// }
// qDebug("new doclnk");
DocLnk lnk;
// lnk.setComment( "");
lnk.setFile(QDir::homeDirPath()+"/Settings/"+filename+".playlist.conf"); //sets File property
lnk.setType("playlist/plain");// hey is this a REGISTERED mime type?!?!? ;D
lnk.setIcon("mpegplayer/playlist2");
lnk.setName( filename); //sets file name
// qDebug(filename);
if(!lnk.writeLink())
qDebug("Writing doclink did not work");
}
- Config config( "MediaPlayer" );
+ Config config( "OpiePlayer" );
config.writeEntry("CurrentPlaylist",filename);
setCaption(tr("OpiePlayer: ")+filename);
d->selectedFiles->first();
if(fileDlg)
delete fileDlg;
}
void PlayListWidget::loadList( const DocLnk & lnk) {
QString name= lnk.name();
// qDebug("currentList is "+name);
if( name.length()>1) {
setCaption("OpiePlayer: "+name);
// qDebug("load list "+ name+".playlist");
clearList();
Config cfg( name+".playlist");
readConfig(cfg);
tabWidget->setCurrentPage(0);
- Config config( "MediaPlayer" );
+ Config config( "OpiePlayer" );
config.writeEntry("CurrentPlaylist", name);
// d->selectedFiles->first();
}
}
void PlayListWidget::setPlaylist( bool shown ) {
if ( shown )
d->playListFrame->show();
else
d->playListFrame->hide();
}
void PlayListWidget::setView( char view ) {
if ( view == 'l' )
showMaximized();
else
hide();
}
void PlayListWidget::addSelected() {
- Config cfg( "MediaPlayer" );
+ Config cfg( "OpiePlayer" );
cfg.setGroup("PlayList");
QString currentPlaylist = cfg.readEntry("CurrentPlaylist","");
int noOfFiles = cfg.readNumEntry("NumberOfFiles", 0 );
switch (tabWidget->currentPageIndex()) {
case 0: //playlist
break;
case 1: { //audio
for ( int i = 0; i < noOfFiles; i++ ) {
QString entryName;
entryName.sprintf( "File%i", i + 1 );
QString linkFile = cfg.readEntry( entryName );
@@ -870,25 +870,25 @@ void PlayListWidget::playlistViewPressed( int mouse, QListViewItem *item, const
QPopupMenu m;
m.insertItem( tr( "Play Selected" ), this, SLOT( playSelected() ));
m.insertItem( tr( "Remove" ), this, SLOT( removeSelected() ));
// m.insertSeparator();
m.exec( QCursor::pos() );
}
break;
};
}
void PlayListWidget::listDelete() {
- Config cfg( "MediaPlayer" );
+ Config cfg( "OpiePlayer" );
cfg.setGroup("PlayList");
QString currentPlaylist = cfg.readEntry("CurrentPlaylist","");
QString file;
int noOfFiles = cfg.readNumEntry("NumberOfFiles", 0 );
switch ( tabWidget->currentPageIndex()) {
case 0:
break;
case 1:
{
file = audioView->selectedItem()->text(0);
// Global::findDocuments(&files, "audio/*");
// AppLnkSet appFiles;