Changeset View
Changeset View
Standalone View
Standalone View
src/qml/MediaTrackMetadataView.qml
- This file was copied to src/qml/MediaRadioMetadataView.qml.
Show All 23 Lines | |||||
24 | import QtGraphicalEffects 1.0 | 24 | import QtGraphicalEffects 1.0 | ||
25 | import org.kde.elisa 1.0 | 25 | import org.kde.elisa 1.0 | ||
26 | 26 | | |||
27 | Window { | 27 | Window { | ||
28 | id: trackMetadata | 28 | id: trackMetadata | ||
29 | 29 | | |||
30 | property int databaseId: 0 | 30 | property int databaseId: 0 | ||
31 | property string fileName | 31 | property string fileName | ||
32 | 32 | | |||
astippich: call this isRadio/isStream for consistency and make it an alias of realModel.isRadio | |||||
33 | signal rejected() | 33 | signal rejected() | ||
34 | 34 | | |||
35 | LayoutMirroring.enabled: Qt.application.layoutDirection == Qt.RightToLeft | 35 | LayoutMirroring.enabled: Qt.application.layoutDirection == Qt.RightToLeft | ||
36 | LayoutMirroring.childrenInherit: true | 36 | LayoutMirroring.childrenInherit: true | ||
37 | 37 | | |||
38 | title: i18nc("Window title for track metadata", "View Details") | 38 | title: i18nc("Window title for track metadata", "View Details") | ||
39 | 39 | | |||
40 | TrackMetadataModel { | 40 | TrackMetadataModel { | ||
41 | id: realModel | 41 | id: realModel | ||
42 | 42 | | |||
43 | manager: elisa.musicManager | 43 | manager: elisa.musicManager | ||
44 | } | 44 | } | ||
astippich: remove comment :) | |||||
45 | 45 | | |||
46 | modality: Qt.NonModal | 46 | modality: Qt.NonModal | ||
47 | flags: Qt.Dialog | Qt.WindowCloseButtonHint | 47 | flags: Qt.Dialog | Qt.WindowCloseButtonHint | ||
48 | 48 | | |||
49 | color: myPalette.window | 49 | color: myPalette.window | ||
50 | 50 | | |||
51 | minimumHeight: elisaTheme.coverImageSize * 1.8 | 51 | minimumHeight: elisaTheme.coverImageSize * 1.8 | ||
52 | minimumWidth: elisaTheme.coverImageSize * 2.8 | 52 | minimumWidth: elisaTheme.coverImageSize * 2.8 | ||
Show All 22 Lines | 68 | Image { | |||
75 | 75 | | |||
76 | Layout.alignment: Qt.AlignTop | Qt.AlignHCenter | 76 | Layout.alignment: Qt.AlignTop | Qt.AlignHCenter | ||
77 | Layout.preferredHeight: elisaTheme.coverImageSize | 77 | Layout.preferredHeight: elisaTheme.coverImageSize | ||
78 | Layout.preferredWidth: elisaTheme.coverImageSize | 78 | Layout.preferredWidth: elisaTheme.coverImageSize | ||
79 | Layout.minimumHeight: elisaTheme.coverImageSize | 79 | Layout.minimumHeight: elisaTheme.coverImageSize | ||
80 | Layout.minimumWidth: elisaTheme.coverImageSize | 80 | Layout.minimumWidth: elisaTheme.coverImageSize | ||
81 | Layout.maximumHeight: elisaTheme.coverImageSize | 81 | Layout.maximumHeight: elisaTheme.coverImageSize | ||
82 | Layout.maximumWidth: elisaTheme.coverImageSize | 82 | Layout.maximumWidth: elisaTheme.coverImageSize | ||
83 | } | 83 | } | ||
84 | 84 | | |||
mgallien: Web radios cannot have an image ? | |||||
At first, I disabled the feature for radio to focus only on Title, Address and Comment (comment is not yet used I admit). jguidon: At first, I disabled the feature for radio to focus only on Title, Address and Comment (comment… | |||||
mgallien: Yes sure. Let's not delay that for a picture. | |||||
85 | ListView { | 85 | ListView { | ||
86 | id: trackData | 86 | id: trackData | ||
87 | 87 | | |||
88 | Layout.fillWidth: true | 88 | Layout.fillWidth: true | ||
89 | Layout.fillHeight: true | 89 | Layout.fillHeight: true | ||
90 | Layout.leftMargin: 2 * elisaTheme.layoutHorizontalMargin | 90 | Layout.leftMargin: 2 * elisaTheme.layoutHorizontalMargin | ||
91 | 91 | | |||
92 | focus: true | 92 | focus: true | ||
▲ Show 20 Lines • Show All 48 Lines • ▼ Show 20 Line(s) | |||||
141 | DialogButtonBox { | 141 | DialogButtonBox { | ||
142 | id: buttons | 142 | id: buttons | ||
143 | 143 | | |||
144 | Layout.fillWidth: true | 144 | Layout.fillWidth: true | ||
145 | Layout.minimumHeight: implicitHeight | 145 | Layout.minimumHeight: implicitHeight | ||
146 | 146 | | |||
147 | standardButtons: DialogButtonBox.Close | 147 | standardButtons: DialogButtonBox.Close | ||
148 | alignment: Qt.AlignRight | 148 | alignment: Qt.AlignRight | ||
149 | onRejected: trackMetadata.rejected() | 149 | onRejected: trackMetadata.close() | ||
150 | } | 150 | } | ||
151 | } | 151 | } | ||
152 | 152 | | |||
153 | Connections { | 153 | Connections { | ||
154 | target: elisa | 154 | target: elisa | ||
155 | 155 | | |||
156 | onMusicManagerChanged: { | 156 | onMusicManagerChanged: { | ||
157 | if (databaseId !== 0) { | 157 | if (databaseId !== 0) { | ||
Show All 17 Lines |
call this isRadio/isStream for consistency and make it an alias of realModel.isRadio