summaryrefslogtreecommitdiff
authorsimon <simon>2002-12-04 11:55:24 (UTC)
committer simon <simon>2002-12-04 11:55:24 (UTC)
commitba2de7d7233c0fbbd8ef31fae7aa5a9ded70225e (patch) (unidiff)
treeb84f73c9df4610b4cf957031c8ca7d0ece407614
parentd75c4d9a27fcfc38ac3f9fd58f6b398809ec6a94 (diff)
downloadopie-ba2de7d7233c0fbbd8ef31fae7aa5a9ded70225e.zip
opie-ba2de7d7233c0fbbd8ef31fae7aa5a9ded70225e.tar.gz
opie-ba2de7d7233c0fbbd8ef31fae7aa5a9ded70225e.tar.bz2
- scanForAudio and scanForVideo is scanFiles in the file list view, so
removed the former and connect to the latter
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/multimedia/opieplayer2/playlistwidget.cpp13
-rw-r--r--noncore/multimedia/opieplayer2/playlistwidget.h2
2 files changed, 2 insertions, 13 deletions
diff --git a/noncore/multimedia/opieplayer2/playlistwidget.cpp b/noncore/multimedia/opieplayer2/playlistwidget.cpp
index e754067..86b3424 100644
--- a/noncore/multimedia/opieplayer2/playlistwidget.cpp
+++ b/noncore/multimedia/opieplayer2/playlistwidget.cpp
@@ -82,35 +82,35 @@ PlayListWidget::PlayListWidget( MediaPlayerState &mediaPlayerState, QWidget* par
82 (void)new MenuItem( pmPlayList, tr( "Add all audio files" ), 82 (void)new MenuItem( pmPlayList, tr( "Add all audio files" ),
83 this, SLOT( addAllMusicToList() ) ); 83 this, SLOT( addAllMusicToList() ) );
84 (void)new MenuItem( pmPlayList, tr( "Add all video files" ), 84 (void)new MenuItem( pmPlayList, tr( "Add all video files" ),
85 this, SLOT( addAllVideoToList() ) ); 85 this, SLOT( addAllVideoToList() ) );
86 (void)new MenuItem( pmPlayList, tr( "Add all files" ), 86 (void)new MenuItem( pmPlayList, tr( "Add all files" ),
87 this, SLOT( addAllToList() ) ); 87 this, SLOT( addAllToList() ) );
88 pmPlayList->insertSeparator(-1); 88 pmPlayList->insertSeparator(-1);
89// (void)new MenuItem( pmPlayList, tr( "Save PlayList" ), 89// (void)new MenuItem( pmPlayList, tr( "Save PlayList" ),
90// this, SLOT( saveList() ) ); 90// this, SLOT( saveList() ) );
91 (void)new MenuItem( pmPlayList, tr( "Save Playlist" ), 91 (void)new MenuItem( pmPlayList, tr( "Save Playlist" ),
92 this, SLOT(writem3u() ) ); 92 this, SLOT(writem3u() ) );
93 pmPlayList->insertSeparator(-1); 93 pmPlayList->insertSeparator(-1);
94 (void)new MenuItem( pmPlayList, tr( "Open File or URL" ), 94 (void)new MenuItem( pmPlayList, tr( "Open File or URL" ),
95 this,SLOT( openFile() ) ); 95 this,SLOT( openFile() ) );
96 pmPlayList->insertSeparator(-1); 96 pmPlayList->insertSeparator(-1);
97 (void)new MenuItem( pmPlayList, tr( "Rescan for Audio Files" ), 97 (void)new MenuItem( pmPlayList, tr( "Rescan for Audio Files" ),
98 this,SLOT( scanForAudio() ) ); 98 audioView, SLOT( scanFiles() ) );
99 (void)new MenuItem( pmPlayList, tr( "Rescan for Video Files" ), 99 (void)new MenuItem( pmPlayList, tr( "Rescan for Video Files" ),
100 this,SLOT( scanForVideo() ) ); 100 videoView, SLOT( scanFiles() ) );
101 101
102 pmView->insertItem( Resource::loadPixmap("fullscreen") , tr( "Full Screen"), 102 pmView->insertItem( Resource::loadPixmap("fullscreen") , tr( "Full Screen"),
103 &mediaPlayerState, SLOT( toggleFullscreen() ) ); 103 &mediaPlayerState, SLOT( toggleFullscreen() ) );
104 104
105 Config cfg( "OpiePlayer" ); 105 Config cfg( "OpiePlayer" );
106 bool b= cfg.readBoolEntry("FullScreen", 0); 106 bool b= cfg.readBoolEntry("FullScreen", 0);
107 mediaPlayerState.setFullscreen( b ); 107 mediaPlayerState.setFullscreen( b );
108 pmView->setItemChecked( -16, b ); 108 pmView->setItemChecked( -16, b );
109 109
110 (void)new ToolButton( vbox1, tr( "Move Up" ), "opieplayer2/up", 110 (void)new ToolButton( vbox1, tr( "Move Up" ), "opieplayer2/up",
111 d->selectedFiles, SLOT(moveSelectedUp() ) ); 111 d->selectedFiles, SLOT(moveSelectedUp() ) );
112 (void)new ToolButton( vbox1, tr( "Remove" ), "opieplayer2/cut", 112 (void)new ToolButton( vbox1, tr( "Remove" ), "opieplayer2/cut",
113 d->selectedFiles, SLOT(removeSelected() ) ); 113 d->selectedFiles, SLOT(removeSelected() ) );
114 (void)new ToolButton( vbox1, tr( "Move Down" ), "opieplayer2/down", 114 (void)new ToolButton( vbox1, tr( "Move Down" ), "opieplayer2/down",
115 d->selectedFiles, SLOT(moveSelectedDown() ) ); 115 d->selectedFiles, SLOT(moveSelectedDown() ) );
116 // QVBox *stretch2 = new QVBox( vbox1 ); 116 // QVBox *stretch2 = new QVBox( vbox1 );
@@ -604,41 +604,32 @@ void PlayListWidget::deletePlaylist() {
604 (tr("Yes")), (tr("No")), 0 )){ 604 (tr("Yes")), (tr("No")), 0 )){
605 case 0: // Yes clicked, 605 case 0: // Yes clicked,
606 QFile().remove(playLists->selectedDocument().file()); 606 QFile().remove(playLists->selectedDocument().file());
607 QFile().remove(playLists->selectedDocument().linkFile()); 607 QFile().remove(playLists->selectedDocument().linkFile());
608 playLists->reread(); 608 playLists->reread();
609 break; 609 break;
610 case 1: // Cancel 610 case 1: // Cancel
611 break; 611 break;
612 }; 612 };
613} 613}
614 614
615 615
616void PlayListWidget::playSelected() { 616void PlayListWidget::playSelected() {
617 btnPlay( TRUE); 617 btnPlay( TRUE);
618} 618}
619 619
620
621void PlayListWidget::scanForAudio() {
622 audioView->scanFiles();
623}
624
625void PlayListWidget::scanForVideo() {
626 videoView->scanFiles();
627}
628
629QListView *PlayListWidget::currentFileListView() const 620QListView *PlayListWidget::currentFileListView() const
630{ 621{
631 switch ( currentTab() ) { 622 switch ( currentTab() ) {
632 case AudioFiles: return audioView; 623 case AudioFiles: return audioView;
633 case VideoFiles: return videoView; 624 case VideoFiles: return videoView;
634 default: assert( false ); 625 default: assert( false );
635 } 626 }
636 return 0; 627 return 0;
637} 628}
638 629
639bool PlayListWidget::inFileListMode() const 630bool PlayListWidget::inFileListMode() const
640{ 631{
641 TabType tab = currentTab(); 632 TabType tab = currentTab();
642 return tab == AudioFiles || tab == VideoFiles; 633 return tab == AudioFiles || tab == VideoFiles;
643} 634}
644 635
diff --git a/noncore/multimedia/opieplayer2/playlistwidget.h b/noncore/multimedia/opieplayer2/playlistwidget.h
index 8c22f17..5c8f30c 100644
--- a/noncore/multimedia/opieplayer2/playlistwidget.h
+++ b/noncore/multimedia/opieplayer2/playlistwidget.h
@@ -95,34 +95,32 @@ signals:
95private: 95private:
96 int defaultSkinIndex; 96 int defaultSkinIndex;
97 void readm3u(const QString &); 97 void readm3u(const QString &);
98 void readPls(const QString &); 98 void readPls(const QString &);
99 void initializeStates(); 99 void initializeStates();
100 100
101 QListView *currentFileListView() const; 101 QListView *currentFileListView() const;
102 102
103 bool inFileListMode() const; 103 bool inFileListMode() const;
104 104
105private slots: 105private slots:
106 void populateSkinsMenu(); 106 void populateSkinsMenu();
107 void skinsMenuActivated(int); 107 void skinsMenuActivated(int);
108 void pmViewActivated(int); 108 void pmViewActivated(int);
109 void writem3u(); 109 void writem3u();
110 void writeCurrentM3u(); 110 void writeCurrentM3u();
111 void scanForAudio();
112 void scanForVideo();
113 void openFile(); 111 void openFile();
114 void setDocument( const QString& fileref ); 112 void setDocument( const QString& fileref );
115 void addToSelection( const DocLnk& ); // Add a media file to the playlist 113 void addToSelection( const DocLnk& ); // Add a media file to the playlist
116 void addToSelection( QListViewItem* ); // Add a media file to the playlist 114 void addToSelection( QListViewItem* ); // Add a media file to the playlist
117 void clearList(); 115 void clearList();
118 void addAllToList(); 116 void addAllToList();
119 void addAllMusicToList(); 117 void addAllMusicToList();
120 void addAllVideoToList(); 118 void addAllVideoToList();
121 void saveList(); // Save the playlist 119 void saveList(); // Save the playlist
122 void loadList( const DocLnk &); // Load a playlist 120 void loadList( const DocLnk &); // Load a playlist
123 void playIt( QListViewItem *); 121 void playIt( QListViewItem *);
124 void btnPlay(bool); 122 void btnPlay(bool);
125 void deletePlaylist(); 123 void deletePlaylist();
126 void addSelected(); 124 void addSelected();
127 void removeSelected(); 125 void removeSelected();
128 void tabChanged(QWidget*); 126 void tabChanged(QWidget*);