-rw-r--r-- | noncore/multimedia/opieplayer2/audiowidget.cpp | 1 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/audiowidget.h | 4 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/main.cpp | 4 | ||||
-rw-r--r-- | noncore/multimedia/opieplayer2/playlistwidget.cpp | 3 | ||||
-rw-r--r-- | noncore/multimedia/showimg/main.cpp | 2 | ||||
-rw-r--r-- | noncore/multimedia/showimg/showimg.cpp | 5 |
6 files changed, 13 insertions, 6 deletions
diff --git a/noncore/multimedia/opieplayer2/audiowidget.cpp b/noncore/multimedia/opieplayer2/audiowidget.cpp index 452117c..28a42eb 100644 --- a/noncore/multimedia/opieplayer2/audiowidget.cpp +++ b/noncore/multimedia/opieplayer2/audiowidget.cpp @@ -15,48 +15,49 @@ ._= =} : or (at your option) any later version. .%`+i> _;_. .i_,=:_. -<s. This program is distributed in the hope that + . -:. = it will be useful, but WITHOUT ANY WARRANTY; : .. .:, . . . without even the implied warranty of =_ + =;=|` MERCHANTABILITY or FITNESS FOR A _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU ..}^=.= = ; Library General Public License for more ++= -. .` .: details. : = ...= . :.=- -. .:....=;==+<; You should have received a copy of the GNU -_. . . )=. = Library General Public License along with -- :-=` this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include "audiowidget.h" #include <qpe/qpeapplication.h> +using namespace Opie::Ui; namespace { const int xo = -2; // movable x offset const int yo = 22; // movable y offset const MediaWidget::SkinButtonInfo skinInfo[] = { { MediaWidget::Play, "play", MediaWidget::ToggleButton }, { MediaWidget::Stop, "stop", MediaWidget::NormalButton }, { MediaWidget::Next, "next", MediaWidget::NormalButton }, { MediaWidget::Previous, "prev", MediaWidget::NormalButton }, { MediaWidget::VolumeUp, "up", MediaWidget::NormalButton }, { MediaWidget::VolumeDown, "down", MediaWidget::NormalButton }, { MediaWidget::Loop, "loop", MediaWidget::ToggleButton }, { MediaWidget::PlayList, "playlist", MediaWidget::NormalButton }, { MediaWidget::Forward, "forward", MediaWidget::NormalButton }, { MediaWidget::Back, "back", MediaWidget::NormalButton } }; const uint buttonCount = sizeof( skinInfo ) / sizeof( skinInfo[ 0 ] ); void changeTextColor( QWidget * w) { QPalette p = w->palette(); diff --git a/noncore/multimedia/opieplayer2/audiowidget.h b/noncore/multimedia/opieplayer2/audiowidget.h index b436239..aea4146 100644 --- a/noncore/multimedia/opieplayer2/audiowidget.h +++ b/noncore/multimedia/opieplayer2/audiowidget.h @@ -15,81 +15,81 @@ ._= =} : or (at your option) any later version. .%`+i> _;_. .i_,=:_. -<s. This program is distributed in the hope that + . -:. = it will be useful, but WITHOUT ANY WARRANTY; : .. .:, . . . without even the implied warranty of =_ + =;=|` MERCHANTABILITY or FITNESS FOR A _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU ..}^=.= = ; Library General Public License for more ++= -. .` .: details. : = ...= . :.=- -. .:....=;==+<; You should have received a copy of the GNU -_. . . )=. = Library General Public License along with -- :-=` this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #ifndef AUDIO_WIDGET_H #define AUDIO_WIDGET_H #include <qlineedit.h> -#include <opie/oticker.h> +#include <opie2/oticker.h> #include "mediawidget.h" class QPixmap; class AudioWidget : public MediaWidget { Q_OBJECT public: AudioWidget( PlayListWidget &playList, MediaPlayerState &mediaPlayerState, QWidget* parent=0, const char* name=0 ); ~AudioWidget(); void setTickerText( const QString &text ) { songInfo.setText( text ); } static MediaWidget::GUIInfo guiInfo(); public slots: void updateSlider( long, long ); void sliderPressed( ); void sliderReleased( ); void setLooping( bool b) { setToggleButton( Loop, b ); } void setPosition( long ); void setSeekable( bool ); public: virtual void setLength( long ); virtual void setPlaying( bool b) { setToggleButton( Play, b ); } virtual void setDisplayType( MediaPlayerState::DisplayType displayType ); virtual void loadSkin(); signals: void sliderMoved(long); protected: void doBlank(); void doUnblank(); void resizeEvent( QResizeEvent *re ); void timerEvent( QTimerEvent *event ); void keyReleaseEvent( QKeyEvent *e); private slots: void skipFor(); void skipBack(); void stopSkip(); private: int skipDirection; QString skin; - OTicker songInfo; + Opie::Ui::OTicker songInfo; QSlider slider; QLineEdit time; bool isStreaming : 1; bool audioSliderBeingMoved : 1; }; #endif // AUDIO_WIDGET_H diff --git a/noncore/multimedia/opieplayer2/main.cpp b/noncore/multimedia/opieplayer2/main.cpp index 00f72d1..6283ae3 100644 --- a/noncore/multimedia/opieplayer2/main.cpp +++ b/noncore/multimedia/opieplayer2/main.cpp @@ -1,26 +1,28 @@ #include "mediaplayer.h" -#include <opie/oapplicationfactory.h> +#include <opie2/oapplicationfactory.h> +using namespace Opie::Core; OPIE_EXPORT_APP( OApplicationFactory<PlayListWidget> ) #if 0 +using namespace Opie::Core; int main(int argc, char **argv) { QPEApplication a(argc,argv); MediaPlayerState st( 0, "mediaPlayerState" ); PlayListWidget pl( st, 0, "playList" ); pl.showMaximized(); MediaPlayer mp( pl, st, 0, "mediaPlayer" ); QObject::connect( &pl, SIGNAL( skinSelected() ), &mp, SLOT( reloadSkins() ) ); a.showMainDocumentWidget(&pl); return a.exec(); } #endif diff --git a/noncore/multimedia/opieplayer2/playlistwidget.cpp b/noncore/multimedia/opieplayer2/playlistwidget.cpp index 84aba55..1a5e474 100644 --- a/noncore/multimedia/opieplayer2/playlistwidget.cpp +++ b/noncore/multimedia/opieplayer2/playlistwidget.cpp @@ -12,62 +12,63 @@ :`=1 )Y*s>-.-- : the terms of the GNU General Public .="- .-=="i, .._ License as published by the Free Software - . .-<_> .<> Foundation; either version 2 of the License, ._= =} : or (at your option) any later version. .%`+i> _;_. .i_,=:_. -<s. This program is distributed in the hope that + . -:. = it will be useful, but WITHOUT ANY WARRANTY; : .. .:, . . . without even the implied warranty of =_ + =;=|` MERCHANTABILITY or FITNESS FOR A _.=:. : :=>`: PARTICULAR PURPOSE. See the GNU ..}^=.= = ; General Public License for more ++= -. .` .: details. : = ...= . :.=- -. .:....=;==+<; You should have received a copy of the GNU -_. . . )=. = General Public License along with -- :-=` this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include <qtoolbar.h> -#include <opie/ofiledialog.h> +#include <opie2/ofiledialog.h> #include <qmessagebox.h> #include "playlistselection.h" #include "playlistwidget.h" #include "mediaplayer.h" #include "inputDialog.h" #include "om3u.h" #include "playlistfileview.h" //only needed for the random play #include <assert.h> +using namespace Opie::Ui; PlayListWidget::PlayListWidget(QWidget* parent, const char* name, WFlags fl ) : PlayListWidgetGui( parent, "playList" ) , currentFileListView( 0 ) { mediaPlayerState = new MediaPlayerState(0, "mediaPlayerState" ); m_mp = new MediaPlayer(*this, *mediaPlayerState, 0, "mediaPlayer"); d->tbAddToList = new ToolButton( bar, tr( "Add to Playlist" ), "opieplayer2/add_to_playlist", this , SLOT(addSelected() ) ); d->tbRemoveFromList = new ToolButton( bar, tr( "Remove from Playlist" ), "opieplayer2/remove_from_playlist", this , SLOT(removeSelected() ) ); d->tbPlay = new ToolButton( bar, tr( "Play" ), "opieplayer2/play", this , SLOT( btnPlay(bool) ), TRUE ); d->tbShuffle = new ToolButton( bar, tr( "Randomize" ),"opieplayer2/shuffle", mediaPlayerState, SLOT( setShuffled(bool) ), TRUE ); d->tbLoop = new ToolButton( bar, tr( "Loop" ), "opieplayer2/loop", mediaPlayerState, SLOT( setLooping(bool) ), TRUE ); (void)new MenuItem( pmPlayList, tr( "Clear List" ), this, SLOT( clearList() ) ); (void)new MenuItem( pmPlayList, tr( "Add all audio files" ), this, SLOT( addAllMusicToList() ) ); diff --git a/noncore/multimedia/showimg/main.cpp b/noncore/multimedia/showimg/main.cpp index b61cffb..b7ea071 100644 --- a/noncore/multimedia/showimg/main.cpp +++ b/noncore/multimedia/showimg/main.cpp @@ -2,25 +2,27 @@ ** Copyright (C) 2000 Trolltech AS. All rights reserved. ** ** This file is part of Qtopia Environment. ** ** This file may be distributed and/or modified under the terms of the ** GNU General Public License version 2 as published by the Free Software ** Foundation and appearing in the file LICENSE.GPL included in the ** packaging of this file. ** ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ** ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ #include "showimg.h" #include <opie2/oapplicationfactory.h> +using namespace Opie::Core; +using namespace Opie::Core; OPIE_EXPORT_APP( OApplicationFactory<ImageViewer> ) diff --git a/noncore/multimedia/showimg/showimg.cpp b/noncore/multimedia/showimg/showimg.cpp index 6c0c4db..696a57b 100644 --- a/noncore/multimedia/showimg/showimg.cpp +++ b/noncore/multimedia/showimg/showimg.cpp @@ -11,58 +11,59 @@ ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. ** ** See http://www.trolltech.com/gpl/ for GPL licensing information. ** ** Contact info@trolltech.com if any conditions of this licensing are ** not clear to you. ** **********************************************************************/ // // Full-screen and rotation options contributed by Robert Wittams <robert@wittams.com> // #include "showimg.h" #include "ImageFileSelector.h" #include "settingsdialog.h" #include <opie2/ofiledialog.h> #include <qpe/qpeapplication.h> #include <qpe/config.h> #include <qpe/resource.h> -#include <qpe/qpetoolbar.h> +#include <qtoolbar.h> #include <qaction.h> #include <qfiledialog.h> #include <qmenubar.h> #include <qspinbox.h> #include <math.h> +using namespace Opie::Ui; ControlsDialog::ControlsDialog(const QString &caption,QImage image,int *brightness,QWidget *parent) : QDialog(parent,0,true) { setCaption(caption); if ( parent ) { setPalette(parent->palette()); } b=brightness; img=image; setMinimumSize(140,80); QGridLayout *gl= new QGridLayout(this,2,2,4,4); pixmap =new ImageWidget(this);; QPixmap pm; pm.convertFromImage(img); pixmap->setPixmap(pm); pixmap->setMinimumSize(pm.width(),pm.height()); gl->addMultiCellWidget(pixmap,0,0,0,2,AlignCenter); QLabel *l=new QLabel(tr("Brightness")+":",this); gl->addWidget(l,1,0,AlignLeft); @@ -502,49 +503,49 @@ void ImageViewer::show() QMainWindow::show(); } void ImageViewer::show(const QString& fileref) { // qDebug("Show "+fileref); bFromDocView = TRUE; closeFileSelector(); DocLnk link(fileref); if ( link.isValid() ) { openFile(link); } else { filename = fileref; updateCaption( fileref ); loadImage( fileref ); } } void ImageViewer::openFile() { MimeTypes types; QStringList image; image << "image/*"; types.insert("Images", image); - QString str = Opie::OFileDialog::getOpenFileName( 1,QPEApplication::documentDir(),"", types, 0 ); + QString str = OFileDialog::getOpenFileName( 1,QPEApplication::documentDir(),"", types, 0 ); DocLnk link(str); // if ( link.isValid() ) openFile(link); } void ImageViewer::openFile( const DocLnk &link ) { closeFileSelector(); // DocLnk link(file); qDebug("open "+link.name()); updateCaption( link.name() ); loadImage( link.file() ); if (slideTimer->isActive()) { slideTimer->start(slideDelay * 1000, FALSE); } } void ImageViewer::open() { switchToFileSelector(); } |