Merge lp:~seb128/address-book-app/translations-gettext-domain into lp:address-book-app

Proposed by Sebastien Bacher on 2015-05-22
Status: Merged
Approved by: Bill Filler on 2015-05-28
Approved revision: 432
Merged at revision: 432
Proposed branch: lp:~seb128/address-book-app/translations-gettext-domain
Merge into: lp:address-book-app
Diff against target: 227 lines (+26/-26)
8 files modified
src/imports/Ubuntu/Contacts/ContactDetailEmailsView.qml (+2/-2)
src/imports/Ubuntu/Contacts/ContactDetailGroupWithTypeBase.qml (+3/-3)
src/imports/Ubuntu/Contacts/ContactDetailOnlineAccountsView.qml (+2/-2)
src/imports/Ubuntu/Contacts/ContactDetailOrganizationsView.qml (+1/-1)
src/imports/Ubuntu/Contacts/ContactDetailPhoneNumbersView.qml (+1/-1)
src/imports/Ubuntu/Contacts/ContactListView.qml (+4/-4)
src/imports/Ubuntu/Contacts/PageWithBottomEdge.qml (+2/-2)
src/imports/Ubuntu/Contacts/SIMCardImportPage.qml (+11/-11)
To merge this branch: bzr merge lp:~seb128/address-book-app/translations-gettext-domain
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Needs Fixing on 2015-05-28
Ubuntu Phablet Team 2015-05-22 Pending
Review via email: mp+259926@code.launchpad.net

Commit Message

Specify the gettext domain to use, the contact widgets are imported by
other components (like the dialer) and trying to load the translations from
the current domain is not working then.

Description of the Change

Specify the gettext domain to use, the contact widgets are imported by
other components (like the dialer) and trying to load the translations from
the current domain is not working then.

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/imports/Ubuntu/Contacts/ContactDetailEmailsView.qml'
2--- src/imports/Ubuntu/Contacts/ContactDetailEmailsView.qml 2014-08-13 20:52:57 +0000
3+++ src/imports/Ubuntu/Contacts/ContactDetailEmailsView.qml 2015-05-22 13:38:16 +0000
4@@ -20,10 +20,10 @@
5
6 ContactDetailGroupWithTypeView {
7 detailType: QtContacts.ContactDetail.Email
8- title: i18n.tr("Email")
9+ title: i18n.dtr("address-book-app", "Email")
10 fields: [ 0 ]
11 defaultAction: Action {
12- text: i18n.tr("Email")
13+ text: i18n.dtr("address-book-app", "Email")
14 iconName: "email"
15 }
16 }
17
18=== modified file 'src/imports/Ubuntu/Contacts/ContactDetailGroupWithTypeBase.qml'
19--- src/imports/Ubuntu/Contacts/ContactDetailGroupWithTypeBase.qml 2014-08-13 20:52:57 +0000
20+++ src/imports/Ubuntu/Contacts/ContactDetailGroupWithTypeBase.qml 2015-05-22 13:38:16 +0000
21@@ -112,9 +112,9 @@
22 }
23
24 Component.onCompleted: {
25- append({"value": QtContacts.ContactDetail.ContextHome, "label": i18n.tr("Home"), "icon": null})
26- append({"value": QtContacts.ContactDetail.ContextWork, "label": i18n.tr("Work"), "icon": null})
27- append({"value": QtContacts.ContactDetail.ContextOther, "label": i18n.tr("Other"), "icon": null})
28+ append({"value": QtContacts.ContactDetail.ContextHome, "label": i18n.dtr("address-book-app", "Home"), "icon": null})
29+ append({"value": QtContacts.ContactDetail.ContextWork, "label": i18n.dtr("address-book-app", "Work"), "icon": null})
30+ append({"value": QtContacts.ContactDetail.ContextOther, "label": i18n.dtr("address-book-app", "Other"), "icon": null})
31 loaded()
32 }
33 }
34
35=== modified file 'src/imports/Ubuntu/Contacts/ContactDetailOnlineAccountsView.qml'
36--- src/imports/Ubuntu/Contacts/ContactDetailOnlineAccountsView.qml 2014-08-13 20:52:57 +0000
37+++ src/imports/Ubuntu/Contacts/ContactDetailOnlineAccountsView.qml 2015-05-22 13:38:16 +0000
38@@ -21,9 +21,9 @@
39 ContactDetailGroupWithTypeView {
40 detailType: QtContacts.ContactDetail.OnlineAccount
41 fields: [ QtContacts.OnlineAccount.AccountUri ]
42- title: i18n.tr("Social")
43+ title: i18n.dtr("address-book-app", "Social")
44 typeModel: ContactDetailOnlineAccountTypeModel { }
45 defaultAction: Action {
46- text: i18n.tr("Touch")
47+ text: i18n.dtr("address-book-app", "Touch")
48 }
49 }
50
51=== modified file 'src/imports/Ubuntu/Contacts/ContactDetailOrganizationsView.qml'
52--- src/imports/Ubuntu/Contacts/ContactDetailOrganizationsView.qml 2014-08-14 20:20:42 +0000
53+++ src/imports/Ubuntu/Contacts/ContactDetailOrganizationsView.qml 2015-05-22 13:38:16 +0000
54@@ -21,7 +21,7 @@
55 ContactDetailGroupWithTypeView {
56 id: root
57
58- title: i18n.tr("Professional Details")
59+ title: i18n.dtr("address-book-app", "Professional Details")
60 defaultIcon: "image://theme/location"
61 detailType: QtContacts.ContactDetail.Organization
62 typeModel: null
63
64=== modified file 'src/imports/Ubuntu/Contacts/ContactDetailPhoneNumbersView.qml'
65--- src/imports/Ubuntu/Contacts/ContactDetailPhoneNumbersView.qml 2014-08-13 20:52:57 +0000
66+++ src/imports/Ubuntu/Contacts/ContactDetailPhoneNumbersView.qml 2015-05-22 13:38:16 +0000
67@@ -23,7 +23,7 @@
68 detailType: QtContacts.ContactDetail.PhoneNumber
69 fields: [ QtContacts.PhoneNumber.Number ]
70
71- title: i18n.tr("Phone")
72+ title: i18n.dtr("address-book-app", "Phone")
73 typeModel: ContactDetailPhoneNumberTypeModel { }
74 detailDelegate: ContactDetailPhoneNumberView {
75 property variant detailType: detail && root.contact && root.typeModelReady ? root.getType(detail) : null
76
77=== modified file 'src/imports/Ubuntu/Contacts/ContactListView.qml'
78--- src/imports/Ubuntu/Contacts/ContactListView.qml 2015-03-17 17:14:09 +0000
79+++ src/imports/Ubuntu/Contacts/ContactListView.qml 2015-05-22 13:38:16 +0000
80@@ -421,7 +421,7 @@
81
82 iconSource: "image://theme/add"
83 // TRANSLATORS: this refers to a new contact
84- labelText: i18n.tr("+ Create New")
85+ labelText: i18n.dtr("address-book-app", "+ Create New")
86 onClicked: root.addNewContactClicked()
87 visible: root.showAddNewButton
88 }
89@@ -465,7 +465,7 @@
90 visible: (onlineAccountHelper.status === Loader.Ready)
91 expandIcon: true
92 iconSource: "image://theme/google"
93- labelText: i18n.tr("Import contacts from Google")
94+ labelText: i18n.dtr("address-book-app", "Import contacts from Google")
95 onClicked: onlineAccountHelper.item.setupExec()
96 }
97
98@@ -476,7 +476,7 @@
99
100 expandIcon: true
101 iconSource: "image://theme/save-to"
102- labelText: i18n.tr("Import contacts from SIM card")
103+ labelText: i18n.dtr("address-book-app", "Import contacts from SIM card")
104 // Does not show the button if the list is not in a pageStack
105 visible: (typeof(pageStack) !== "undefined") &&
106 ((simList.sims.length > 0) && (simList.present.length > 0))
107@@ -544,7 +544,7 @@
108 }
109 Label {
110 anchors.horizontalCenter: activity.horizontalCenter
111- text: root.syncing ? i18n.tr("Syncing...") : i18n.tr("Loading...")
112+ text: root.syncing ? i18n.dtr("address-book-app", "Syncing...") : i18n.dtr("address-book-app", "Loading...")
113 }
114 }
115
116
117=== modified file 'src/imports/Ubuntu/Contacts/PageWithBottomEdge.qml'
118--- src/imports/Ubuntu/Contacts/PageWithBottomEdge.qml 2014-09-30 14:10:32 +0000
119+++ src/imports/Ubuntu/Contacts/PageWithBottomEdge.qml 2015-05-22 13:38:16 +0000
120@@ -30,7 +30,7 @@
121
122 PageWithBottomEdge {
123 id: mainPage
124- title: i18n.tr("Main Page")
125+ title: i18n.dtr("address-book-app", "Main Page")
126
127 Rectangle {
128 anchors.fill: parent
129@@ -50,7 +50,7 @@
130 }
131 }
132 }
133- bottomEdgeTitle: i18n.tr("Bottom edge action")
134+ bottomEdgeTitle: i18n.dtr("address-book-app", "Bottom edge action")
135 }
136 }
137
138
139=== modified file 'src/imports/Ubuntu/Contacts/SIMCardImportPage.qml'
140--- src/imports/Ubuntu/Contacts/SIMCardImportPage.qml 2015-03-18 21:49:03 +0000
141+++ src/imports/Ubuntu/Contacts/SIMCardImportPage.qml 2015-05-22 13:38:16 +0000
142@@ -31,7 +31,7 @@
143 property var targetModel: null
144 property var sims: []
145
146- title: i18n.tr("SIM contacts")
147+ title: i18n.dtr("address-book-app", "SIM contacts")
148
149 function lockedSIMCount()
150 {
151@@ -74,9 +74,9 @@
152 else
153 simUnlocking.start()
154 }
155- text: i18n.tr("%1 is locked").arg(sims[index].title)
156+ text: i18n.dtr("address-book-app", "%1 is locked").arg(sims[index].title)
157 control: Button {
158- text: i18n.tr("Unlock")
159+ text: i18n.dtr("address-book-app", "Unlock")
160 onClicked: simCardContacts.unlockModem(sims[index].path)
161 }
162 }
163@@ -107,7 +107,7 @@
164 id: statusMessage
165
166 anchors.centerIn: parent
167- text: i18n.tr("No contacts found")
168+ text: i18n.dtr("address-book-app", "No contacts found")
169 visible: ((contactList.count === 0) &&
170 (root.state === "") &&
171 !contactList.busy &&
172@@ -174,8 +174,8 @@
173 head.actions: [
174 Action {
175 text: (contactList.selectedItems.count === contactList.count) ?
176- i18n.tr("Unselect All") :
177- i18n.tr("Select All")
178+ i18n.dtr("address-book-app", "Unselect All") :
179+ i18n.dtr("address-book-app", "Select All")
180 iconName: "select"
181 onTriggered: {
182 if (contactList.selectedItems.count === contactList.count) {
183@@ -187,7 +187,7 @@
184 visible: (contactList.count > 0)
185 },
186 Action {
187- text: i18n.tr("Import")
188+ text: i18n.dtr("address-book-app", "Import")
189 objectName: "confirmImport"
190
191 iconName: "tick"
192@@ -215,7 +215,7 @@
193 (sims.length > root.lockedSIMCount())
194 PropertyChanges {
195 target: indicator
196- title: i18n.tr("Loading...")
197+ title: i18n.dtr("address-book-app", "Loading...")
198 visible: true
199 }
200 },
201@@ -224,7 +224,7 @@
202 when: !simCardContacts.busy && (contactList.count == 0) && (simUnlocking.running)
203 PropertyChanges {
204 target: indicator
205- title: i18n.tr("Unlocking...")
206+ title: i18n.dtr("address-book-app", "Unlocking...")
207 visible: true
208 }
209 },
210@@ -232,7 +232,7 @@
211 name: "importing"
212 PropertyChanges {
213 target: indicator
214- title: i18n.tr("Importing...")
215+ title: i18n.dtr("address-book-app", "Importing...")
216 visible: true
217 }
218 },
219@@ -240,7 +240,7 @@
220 name: "error"
221 PropertyChanges {
222 target: statusMessage
223- text: i18n.tr("Fail to read SIM card")
224+ text: i18n.dtr("address-book-app", "Fail to read SIM card")
225 visible: true
226 }
227 }

Subscribers

People subscribed via source and target branches