|
Qt Components Hildon
0.20
QML components for Maemo5 with Hildon styling.
|
Provides a 'Now playing' playlist. More...
Public Slots | |
| void | clearItems () |
| Clears all items from the playlist. | |
| void | loadItems () |
| Loads items from the MAFW playlist into the model. | |
| void | next () |
| Moves to the next item in the playlist. | |
| void | previous () |
| Moves to the previous item in the playlist. | |
Signals | |
| void | ready () |
| This signal is emitted when MAFW playlist has been loaded and is ready to be accessed. | |
Public Member Functions | |
| void | appendItem (string id) |
| Adds the source with the specifed id to the playlist. | |
| void | appendSource (string uri) |
| Adds the source with the specifed uri to the playlist. | |
| void | insertItem (int row, string id) |
| Inserts the with the specified id before index. | |
| void | insertSource (int row, string uri) |
| Inserts the with the specified uri before index. | |
| void | moveItem (int from, int to) |
| Moves the item at from to to. | |
| variant | property (int row, string name) |
| Returns the value of the property with name name of the item at row. | |
| void | removeItem (int row) |
| Removes the item at row from the playlist. | |
Properties | |
| int | count |
| The number of items in the playlist. | |
| MediaType::Type | mediaType |
| The type of media used for the playlist. | |
| int | position |
| The current position in the playlist. | |
| bool | repeat |
| Whether the playlist will be repeated. | |
| bool | shuffle |
| Whether the playlist will be shuffled. | |
Provides a 'Now playing' playlist.
The NowPlayingModel component can be used with the Audio component to provide a 'Now playing' playlist. Items added to the playlist are used for playback by the MAFW multimedia backend.
Example:
| void NowPlayingModel::appendItem | ( | string | id | ) |
Adds the source with the specifed id to the playlist.
If id represents a local file, the metadata for the source will be loaded.
| void NowPlayingModel::appendSource | ( | string | uri | ) |
Adds the source with the specifed uri to the playlist.
If uri represents a local file, the metadata for the source will be loaded.
| void NowPlayingModel::insertItem | ( | int | row, |
| string | id | ||
| ) |
Inserts the with the specified id before index.
If id represents a local file, the metadata for the source will be loaded.
| void NowPlayingModel::insertSource | ( | int | row, |
| string | uri | ||
| ) |
Inserts the with the specified uri before index.
If uri represents a local file, the metadata for the source will be loaded.
|
slot |
Moves to the next item in the playlist.
|
slot |
Moves to the previous item in the playlist.
| variant NowPlayingModel::property | ( | int | row, |
| string | name | ||
| ) |
Returns the value of the property with name name of the item at row.
Valid property names are:
| Name |
|---|
| albumArtist |
| albumTitle |
| artist |
| audioBitRate |
| audioCodec |
| comment |
| composer |
| copyright |
| coverArtUrl |
| date |
| description |
| duration |
| genre |
| id |
| keywords |
| lastPlayed |
| lastThumbnailUrl |
| lyrics |
| mimeType |
| playCount |
| resolution |
| resumePosition |
| size |
| thumbnailUrl |
| title |
| trackNumber |
| url |
| videoBitRate |
| videoCodec |
| videoFrameRate |
| year |
|
readwrite |
The type of media used for the playlist.
Possible values are:
| Value | Description |
|---|---|
| MediaType.Audio | Audio files (default). |
| MediaType.Radio | Internet radio streams. |
| MediaType.Video | Video files. |
Changing this property will clear the data in the model, but not the MAFW playlist. Call clearItems() to clear the MAFW playlist.
|
readwrite |
The current position in the playlist.
|
readwrite |
Whether the playlist will be repeated.
The default value is false.
|
readwrite |
Whether the playlist will be shuffled.
The default value is false.
1.8.1.2