Merge lp:~vthompson/music-app/fix-1410639-edit-playlist-placeholder into lp:music-app/remix

Proposed by Victor Thompson
Status: Merged
Approved by: Andrew Hayzen
Approved revision: 786
Merged at revision: 788
Proposed branch: lp:~vthompson/music-app/fix-1410639-edit-playlist-placeholder
Merge into: lp:music-app/remix
Diff against target: 258 lines (+51/-61)
4 files modified
Style.qml (+2/-1)
common/SongsPage.qml (+12/-14)
music-app.qml (+2/-3)
po/com.ubuntu.music.pot (+35/-43)
To merge this branch: bzr merge lp:~vthompson/music-app/fix-1410639-edit-playlist-placeholder
Reviewer Review Type Date Requested Status
Andrew Hayzen Approve
Ubuntu Phone Apps Jenkins Bot continuous-integration Approve
Review via email: mp+246388@code.launchpad.net

Commit message

Use the same placeholder text that is used in creating a playlist when editing the name

Description of the change

Use the same placeholder text that is used in creating a playlist when editing the name. Currently the app incorrectly displays the existing name as the placeholder text. It does so because it abuses the placeholder text as a property to compare the new name against.

This also adds changes to the text as per design direction.

To post a comment you must log in.
Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
784. By Victor Thompson

update dialog text and button colors

785. By Victor Thompson

update pot file

Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
786. By Victor Thompson

Use blank text field when changing playlist name

Revision history for this message
Ubuntu Phone Apps Jenkins Bot (ubuntu-phone-apps-jenkins-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Andrew Hayzen (ahayzen) wrote :

LGTM :)

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'Style.qml'
2--- Style.qml 2014-10-22 16:03:45 +0000
3+++ Style.qml 2015-01-17 06:18:22 +0000
4@@ -46,7 +46,8 @@
5 }
6
7 property QtObject dialog: QtObject {
8- property color confirmButtonColor: UbuntuColors.orange;
9+ property color confirmButtonColor: UbuntuColors.green;
10+ property color confirmRemoveButtonColor: UbuntuColors.red;
11 property color cancelButtonColor: UbuntuColors.coolGrey;
12 property color normalTextFieldColor: common.white
13 }
14
15=== modified file 'common/SongsPage.qml'
16--- common/SongsPage.qml 2015-01-11 17:04:55 +0000
17+++ common/SongsPage.qml 2015-01-17 06:18:22 +0000
18@@ -495,16 +495,14 @@
19 Dialog {
20 id: dialogEditPlaylist
21 // TRANSLATORS: this is a title of a dialog with a prompt to rename a playlist
22- title: i18n.tr("Change name")
23- text: i18n.tr("Enter the new name of the playlist.")
24+ title: i18n.tr("Rename playlist")
25
26- property alias oldPlaylistName: playlistName.placeholderText
27+ property string oldPlaylistName: ""
28
29 TextField {
30 id: playlistName
31 inputMethodHints: Qt.ImhNoPredictiveText
32-
33- onPlaceholderTextChanged: text = placeholderText
34+ placeholderText: i18n.tr("Enter playlist name")
35 }
36 Label {
37 id: editplaylistoutput
38@@ -519,12 +517,12 @@
39 editplaylistoutput.visible = true
40
41 if (playlistName.text.length > 0) { // make sure something is acually inputed
42- console.debug("Debug: User changed name from "+playlistName.placeholderText+" to "+playlistName.text)
43-
44- if (Playlists.renamePlaylist(playlistName.placeholderText, playlistName.text) === true) {
45-
46- if (Library.recentContainsPlaylist(playlistName.placeholderText)) {
47- Library.recentRenamePlaylist(playlistName.placeholderText, playlistName.text)
48+ console.debug("Debug: User changed name from "+oldPlaylistName+" to "+playlistName.text)
49+
50+ if (Playlists.renamePlaylist(oldPlaylistName, playlistName.text) === true) {
51+
52+ if (Library.recentContainsPlaylist(oldPlaylistName)) {
53+ Library.recentRenamePlaylist(oldPlaylistName, playlistName.text)
54 }
55
56 line2 = playlistName.text
57@@ -556,14 +554,14 @@
58 Dialog {
59 id: dialogRemovePlaylist
60 // TRANSLATORS: this is a title of a dialog with a prompt to delete a playlist
61- title: i18n.tr("Are you sure?")
62- text: i18n.tr("This will delete your playlist.")
63+ title: i18n.tr("Permanently delete playlist?")
64+ text: "("+i18n.tr("This cannot be undone")+")"
65
66 property string oldPlaylistName
67
68 Button {
69 text: i18n.tr("Remove")
70- color: styleMusic.dialog.confirmButtonColor
71+ color: styleMusic.dialog.confirmRemoveButtonColor
72 onClicked: {
73 // removing playlist
74 Playlists.removePlaylist(dialogRemovePlaylist.oldPlaylistName)
75
76=== modified file 'music-app.qml'
77--- music-app.qml 2015-01-12 18:50:35 +0000
78+++ music-app.qml 2015-01-17 06:18:22 +0000
79@@ -836,12 +836,11 @@
80 Dialog {
81 id: dialogNewPlaylist
82 objectName: "dialogNewPlaylist"
83- title: i18n.tr("New Playlist")
84- text: i18n.tr("Name your playlist.")
85+ title: i18n.tr("New playlist")
86 TextField {
87 id: playlistName
88 objectName: "playlistNameTextField"
89- placeholderText: i18n.tr("Name")
90+ placeholderText: i18n.tr("Enter playlist name")
91 inputMethodHints: Qt.ImhNoPredictiveText
92 }
93 Label {
94
95=== modified file 'po/com.ubuntu.music.pot'
96--- po/com.ubuntu.music.pot 2015-01-11 20:22:15 +0000
97+++ po/com.ubuntu.music.pot 2015-01-17 06:18:22 +0000
98@@ -8,7 +8,7 @@
99 msgstr ""
100 "Project-Id-Version: music-app\n"
101 "Report-Msgid-Bugs-To: \n"
102-"POT-Creation-Date: 2015-01-11 20:21+0000\n"
103+"POT-Creation-Date: 2015-01-16 16:52-0600\n"
104 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
105 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
106 "Language-Team: LANGUAGE <LL@li.org>\n"
107@@ -57,13 +57,13 @@
108 msgstr ""
109
110 #: ../MusicNowPlaying.qml:35 ../music-app.qml:656 ../music-app.qml:688
111-#: ../music-app.qml:1048 ../music-app.qml:1060 ../music-app.qml:1088
112-#: ../music-app.qml:1089
113+#: ../music-app.qml:1047 ../music-app.qml:1059 ../music-app.qml:1087
114+#: ../music-app.qml:1088
115 msgid "Queue"
116 msgstr ""
117
118-#: ../MusicNowPlaying.qml:35 ../music-app.qml:656 ../music-app.qml:890
119-#: ../music-app.qml:1047 ../music-app.qml:1088 ../music-app.qml:1089
120+#: ../MusicNowPlaying.qml:35 ../music-app.qml:656 ../music-app.qml:889
121+#: ../music-app.qml:1046 ../music-app.qml:1087 ../music-app.qml:1088
122 msgid "Now playing"
123 msgstr ""
124
125@@ -131,7 +131,7 @@
126 msgid "Add to queue"
127 msgstr ""
128
129-#: ../MusicaddtoPlaylist.qml:42 ../music-app.qml:1144
130+#: ../MusicaddtoPlaylist.qml:42 ../music-app.qml:1143
131 msgid "Select playlist"
132 msgstr ""
133
134@@ -158,7 +158,7 @@
135 msgid "Add to Queue"
136 msgstr ""
137
138-#: ../common/ListItemActions/Remove.qml:27 ../common/SongsPage.qml:565
139+#: ../common/ListItemActions/Remove.qml:27 ../common/SongsPage.qml:564
140 msgid "Remove"
141 msgstr ""
142
143@@ -176,37 +176,37 @@
144
145 #. TRANSLATORS: this is a title of a dialog with a prompt to rename a playlist
146 #: ../common/SongsPage.qml:498
147-msgid "Change name"
148-msgstr ""
149-
150-#: ../common/SongsPage.qml:499
151-msgid "Enter the new name of the playlist."
152-msgstr ""
153-
154-#: ../common/SongsPage.qml:516
155+msgid "Rename playlist"
156+msgstr ""
157+
158+#: ../common/SongsPage.qml:505 ../music-app.qml:843
159+msgid "Enter playlist name"
160+msgstr ""
161+
162+#: ../common/SongsPage.qml:515
163 msgid "Change"
164 msgstr ""
165
166-#: ../common/SongsPage.qml:537 ../music-app.qml:870
167+#: ../common/SongsPage.qml:536 ../music-app.qml:869
168 msgid "Playlist already exists"
169 msgstr ""
170
171-#: ../common/SongsPage.qml:541 ../music-app.qml:875
172+#: ../common/SongsPage.qml:540 ../music-app.qml:874
173 msgid "Please type in a name."
174 msgstr ""
175
176-#: ../common/SongsPage.qml:546 ../common/SongsPage.qml:584
177-#: ../music-app.qml:481 ../music-app.qml:881
178+#: ../common/SongsPage.qml:545 ../common/SongsPage.qml:583
179+#: ../music-app.qml:481 ../music-app.qml:880
180 msgid "Cancel"
181 msgstr ""
182
183 #. TRANSLATORS: this is a title of a dialog with a prompt to delete a playlist
184+#: ../common/SongsPage.qml:558
185+msgid "Permanently delete playlist?"
186+msgstr ""
187+
188 #: ../common/SongsPage.qml:559
189-msgid "Are you sure?"
190-msgstr ""
191-
192-#: ../common/SongsPage.qml:560
193-msgid "This will delete your playlist."
194+msgid "This cannot be undone"
195 msgstr ""
196
197 #: ../music-app.qml:145
198@@ -297,7 +297,7 @@
199 msgid "No songs played today"
200 msgstr ""
201
202-#: ../music-app.qml:579 ../music-app.qml:1084
203+#: ../music-app.qml:579 ../music-app.qml:1083
204 #: com.ubuntu.music_music.desktop.in.in.h:1
205 msgid "Music"
206 msgstr ""
207@@ -307,42 +307,34 @@
208 msgstr ""
209
210 #: ../music-app.qml:839
211-msgid "New Playlist"
212-msgstr ""
213-
214-#: ../music-app.qml:840
215-msgid "Name your playlist."
216-msgstr ""
217-
218-#: ../music-app.qml:844
219-msgid "Name"
220-msgstr ""
221-
222-#: ../music-app.qml:854
223+msgid "New playlist"
224+msgstr ""
225+
226+#: ../music-app.qml:853
227 msgid "Create"
228 msgstr ""
229
230-#: ../music-app.qml:1118
231+#: ../music-app.qml:1117
232 msgid "No music found"
233 msgstr ""
234
235-#: ../music-app.qml:1129
236+#: ../music-app.qml:1128
237 msgid "Please import music"
238 msgstr ""
239
240-#: ../music-app.qml:1158
241+#: ../music-app.qml:1157
242 msgid "No playlists found"
243 msgstr ""
244
245-#: ../music-app.qml:1169
246+#: ../music-app.qml:1168
247 msgid "Click the + to create a playlist"
248 msgstr ""
249
250-#: ../music-app.qml:1198
251+#: ../music-app.qml:1197
252 msgid "No recent albums or playlists found"
253 msgstr ""
254
255-#: ../music-app.qml:1209
256+#: ../music-app.qml:1208
257 msgid "Play some music to see your favorites"
258 msgstr ""
259

Subscribers

People subscribed via source and target branches