summaryrefslogtreecommitdiff
path: root/core/multimedia/opieplayer/mediaplayerstate.h
Unidiff
Diffstat (limited to 'core/multimedia/opieplayer/mediaplayerstate.h') (more/less context) (ignore whitespace changes)
-rw-r--r--core/multimedia/opieplayer/mediaplayerstate.h64
1 files changed, 31 insertions, 33 deletions
diff --git a/core/multimedia/opieplayer/mediaplayerstate.h b/core/multimedia/opieplayer/mediaplayerstate.h
index 1a23742..e82c263 100644
--- a/core/multimedia/opieplayer/mediaplayerstate.h
+++ b/core/multimedia/opieplayer/mediaplayerstate.h
@@ -1,6 +1,6 @@
1/********************************************************************** 1/**********************************************************************
2** Copyright (C) 2000 Trolltech AS. All rights reserved. 2** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
3** 3**
4** This file is part of Qtopia Environment. 4** This file is part of the Qtopia Environment.
5** 5**
6** This file may be distributed and/or modified under the terms of the 6** This file may be distributed and/or modified under the terms of the
@@ -21,5 +21,4 @@
21#define MEDIA_PLAYER_STATE_H 21#define MEDIA_PLAYER_STATE_H
22 22
23
24#include <qobject.h> 23#include <qobject.h>
25 24
@@ -35,19 +34,19 @@ public:
35 ~MediaPlayerState(); 34 ~MediaPlayerState();
36 35
37 bool fullscreen() { return isFullscreen; } 36 bool fullscreen() { return isFullscreen; }
38 bool scaled() { return isScaled; } 37 bool scaled() { return isScaled; }
39 bool looping() { return isLooping; } 38 bool looping() { return isLooping; }
40 bool shuffled() { return isShuffled; } 39 bool shuffled() { return isShuffled; }
41 bool playlist() { return usePlaylist; } 40 bool playlist() { return usePlaylist; }
42 bool paused() { return isPaused; } 41 bool paused() { return isPaused; }
43 bool playing() { return isPlaying; } 42 bool playing() { return isPlaying; }
44 long position() { return curPosition; } 43 long position() { return curPosition; }
45 long length() { return curLength; } 44 long length() { return curLength; }
46 char view() { return curView; } 45 char view() { return curView; }
47 46
48 MediaPlayerDecoder *newDecoder( const QString& file ); 47 MediaPlayerDecoder *newDecoder( const QString& file );
49 MediaPlayerDecoder *curDecoder(); 48 MediaPlayerDecoder *curDecoder();
50 MediaPlayerDecoder *libMpeg3Decoder(); // ### Yucky hack needed to use libmpeg3plugin to get the 49 MediaPlayerDecoder *libMpeg3Decoder(); // ### Yucky hack needed to use libmpeg3plugin to get the
51 // number of audio samples if we are using the libmad plugin 50 // number of audio samples if we are using the libmad plugin
52public slots: 51public slots:
53 void setFullscreen( bool b ) { if ( isFullscreen == b ) return; isFullscreen = b; emit fullscreenToggled(b); } 52 void setFullscreen( bool b ) { if ( isFullscreen == b ) return; isFullscreen = b; emit fullscreenToggled(b); }
@@ -56,24 +55,24 @@ public slots:
56 void setShuffled( bool b ) { if ( isShuffled == b ) return; isShuffled = b; emit shuffledToggled(b); } 55 void setShuffled( bool b ) { if ( isShuffled == b ) return; isShuffled = b; emit shuffledToggled(b); }
57 void setPlaylist( bool b ) { if ( usePlaylist == b ) return; usePlaylist = b; emit playlistToggled(b); } 56 void setPlaylist( bool b ) { if ( usePlaylist == b ) return; usePlaylist = b; emit playlistToggled(b); }
58 void setPaused( bool b ) { if ( isPaused == b ) return; isPaused = b; emit pausedToggled(b); } 57 void setPaused( bool b ) { if ( isPaused == b ) return; isPaused = b; emit pausedToggled(b); }
59 void setPlaying( bool b ) { if ( isPlaying == b ) return; isPlaying = b; emit playingToggled(b); } 58 void setPlaying( bool b ) { if ( isPlaying == b ) return; isPlaying = b; emit playingToggled(b); }
60 void setPosition( long p ) { if ( curPosition == p ) return; curPosition = p; emit positionChanged(p); } 59 void setPosition( long p ) { if ( curPosition == p ) return; curPosition = p; emit positionChanged(p); }
61 void updatePosition( long p ){ if ( curPosition == p ) return; curPosition = p; emit positionUpdated(p); } 60 void updatePosition( long p ){ if ( curPosition == p ) return; curPosition = p; emit positionUpdated(p); }
62 void setLength( long l ) { if ( curLength == l ) return; curLength = l; emit lengthChanged(l); } 61 void setLength( long l ) { if ( curLength == l ) return; curLength = l; emit lengthChanged(l); }
63 void setView( char v ) { if ( curView == v ) return; curView = v; emit viewChanged(v); } 62 void setView( char v ) { if ( curView == v ) return; curView = v; emit viewChanged(v); }
64 63
65 void setPrev() { emit prev(); } 64 void setPrev() { emit prev(); }
66 void setNext() { emit next(); } 65 void setNext() { emit next(); }
67 void setList() { setPlaying( FALSE ); setView('l'); } 66 void setList() { setPlaying( FALSE ); setView('l'); }
68 void setVideo() { setView('v'); } 67 void setVideo() { setView('v'); }
69 void setAudio() { setView('a'); } 68 void setAudio() { setView('a'); }
70 69
71 void toggleFullscreen() { setFullscreen( !isFullscreen ); } 70 void toggleFullscreen() { setFullscreen( !isFullscreen ); }
72 void toggleScaled() { setScaled( !isScaled); } 71 void toggleScaled() { setScaled( !isScaled); }
73 void toggleLooping() { setLooping( !isLooping); } 72 void toggleLooping() { setLooping( !isLooping); }
74 void toggleShuffled() { setShuffled( !isShuffled); } 73 void toggleShuffled() { setShuffled( !isShuffled); }
75 void togglePlaylist() { setPlaylist( !usePlaylist); } 74 void togglePlaylist() { setPlaylist( !usePlaylist); }
76 void togglePaused() { setPaused( !isPaused); } 75 void togglePaused() { setPaused( !isPaused); }
77 void togglePlaying() { setPlaying( !isPlaying); } 76 void togglePlaying() { setPlaying( !isPlaying); }
78 77
79signals: 78signals:
@@ -107,5 +106,4 @@ private:
107 MediaPlayerDecoder *decoder; 106 MediaPlayerDecoder *decoder;
108 MediaPlayerDecoder *libmpeg3decoder; 107 MediaPlayerDecoder *libmpeg3decoder;
109// MediaPlayerDecoder *libwavdecoder;
110 108
111 void loadPlugins(); 109 void loadPlugins();