| 1 |
/** |
| 2 |
\page phonon_MediaObject The MediaObject class |
| 3 |
|
| 4 |
\section phonon_MediaObject_derived Media Data Producing Class |
| 5 |
|
| 6 |
There is the class that produces the media data (often called a source in |
| 7 |
media frameworks). |
| 8 |
|
| 9 |
\section phonon_MediaObject_requiredfunctions Required Functions |
| 10 |
\li qint32 \ref phonon_MediaObject_prefinishMark "prefinishMark()" |
| 11 |
\li void \ref phonon_MediaObject_setPrefinishMark "setPrefinishMark(qint32)" |
| 12 |
|
| 13 |
\section phonon_MediaObject_optionalfunctions Optional Functions |
| 14 |
\li qint64 \ref phonon_MediaObject_remainingTime "remainingTime()" |
| 15 |
|
| 16 |
\section phonon_MediaObject_signals Signals |
| 17 |
\li void \ref phonon_MediaObject_totalTimeChanged "totalTimeChanged(qint64 totalTime)" |
| 18 |
\li void \ref phonon_MediaObject_prefinishMarkReached "prefinishMarkReached(qint32 msec)" |
| 19 |
\li void \ref phonon_MediaObject_finished "finished()" |
| 20 |
|
| 21 |
\section phonon_MediaObject_memberdocs Member Function Documentation |
| 22 |
|
| 23 |
\see \ref phonon_MediaObject_totalTimeChanged |
| 24 |
|
| 25 |
\subsection phonon_MediaObject_prefinishMark qint32 prefinishMark() |
| 26 |
Returns the time in milliseconds the \ref phonon_MediaObject_prefinishMarkReached |
| 27 |
"prefinishMarkReached" signal is emitted before the playback if finished and \ref |
| 28 |
phonon_MediaObject_finished "finished" is emitted. |
| 29 |
|
| 30 |
\subsection phonon_MediaObject_setPrefinishMark void setPrefinishMark(qint32 msec) |
| 31 |
Sets the time in milliseconds the \ref phonon_MediaObject_prefinishMarkReached |
| 32 |
"prefinishMarkReached" signal is emitted before the playback if finished and \ref |
| 33 |
phonon_MediaObject_finished "finished" is emitted. |
| 34 |
|
| 35 |
\param msec The time in milliseconds. If the value is less than or equal to 0 |
| 36 |
the \ref phonon_MediaObject_prefinishMarkReached "prefinishMarkReached" signal is disabled. |
| 37 |
|
| 38 |
\subsection phonon_MediaObject_remainingTime qint64 remainingTime() |
| 39 |
Get the remaining time (in milliseconds) of the file currently being played. If |
| 40 |
the method is not implemented in the backend the frontend will use the |
| 41 |
difference between \link Phonon::MediaObjectInterface::totalTime() MediaObjectInterface::totalTime() \endlink and |
| 42 |
\link Phonon::MediaObjectInterface::currentTime() MediaObjectInterface::currentTime() \endlink. |
| 43 |
|
| 44 |
\section phonon_MediaObject_signaldocs Signals Documentation |
| 45 |
\subsection phonon_MediaObject_prefinishMarkReached void prefinishMarkReached(qint32 msec) |
| 46 |
Emitted when the file has finished playing on its own. |
| 47 |
I.e. it is not emitted if you call stop(), pause() or |
| 48 |
load(), but only on end-of-file or a critical error. |
| 49 |
void finished() |
| 50 |
|
| 51 |
\param msec The remaining time until the playback finishes |
| 52 |
|
| 53 |
\subsection phonon_MediaObject_totalTimeChanged void totalTimeChanged(qint64 totalTime) |
| 54 |
This signal is emitted as soon as the length of the media file is |
| 55 |
known or has changed. For most non-local media data the length of |
| 56 |
the media can only be known after some time. At that time the |
| 57 |
totalTime function can not return useful information. You have |
| 58 |
to wait for this signal to know the real length. |
| 59 |
|
| 60 |
\param totalTimeChanged The total time of the media file in milliseconds. |
| 61 |
|
| 62 |
\see \link Phonon::MediaObjectInterface::totalTime() MediaObjectInterface::totalTime() \endlink |
| 63 |
|
| 64 |
\subsection phonon_MediaObject_finished void finished() |
| 65 |
This signal is emitted when the playback of the media finished (on its own). |
| 66 |
It is not emitted if stop() or pause() are called - only on end-of-file or a |
| 67 |
critical error (for example the media data stream is corrupted and playback of |
| 68 |
the media has to be finished). |
| 69 |
|
| 70 |
\see \ref phonon_MediaObject_prefinishMarkReached |
| 71 |
*/ |