on xenial help sign in
fixes
commit258d1175250318702b57d8b0d24e4adcb9536f45 authorLukáš Tinkl <lukas.tinkl@canonical.com> dateThu 27 Aug 2015, 17:23 (11 years ago) parenta7af6aa
11 files changed+53−493
plugins/Wizard/System.cpp+8−7 plugins/Wizard/System.h+1−1 qml/Wizard/Pages.qml+1−2 qml/Wizard/Pages/10-language.qml+24−68 qml/Wizard/Pages/15-country.qml−207 qml/Wizard/Pages/30-wifi.qml+8−16 qml/Wizard/Pages/50-timezone.qml+3−2 qml/Wizard/Pages/60-uaccount-signup.qml−185 tests/mocks/Wizard/MockSystem.cpp+5−2 tests/mocks/Wizard/MockSystem.h+2−2 tests/qmltests/Wizard/tst_Wizard.qml+1−1
plugins/Wizard/System.cpp+8−7
@@ -25,6 +25,7 @@
2525#include <QLocale>
2626#include <QMap>
2727#include <QProcess>
28+#include <QDebug>
2829
2930System::System()
3031 : QObject()
@@ -80,7 +81,7 @@ void System::setSessionVariable(const QString &variable, const QString &value)
8081 QDBusConnection::sessionBus().asyncCall(msg);
8182}
8283
83−void System::updateSessionLanguage(const QString &locale)
84+void System::updateSessionLocale(const QString &locale)
8485{
8586 const QString language = locale.split(".")[0];
8687
@@ -93,10 +94,10 @@ void System::updateSessionLanguage(const QString &locale)
9394 QLocale::setDefault(QLocale(locale));
9495
9596 // Restart bits of the session to pick up new language.
96− QProcess::startDetached("sh -c \"initctl emit indicator-services-end; \
97− initctl stop scope-registry; \
98− initctl stop smart-scopes-proxy; \
99− initctl emit --no-wait indicator-services-start; \
100− initctl restart --no-wait maliit-server; \
101− initctl restart --no-wait unity8-dash\"");
97+// QProcess::startDetached("sh -c \"initctl emit indicator-services-end; \
98+// initctl stop scope-registry; \
99+// initctl stop smart-scopes-proxy; \
100+// initctl emit --no-wait indicator-services-start; \
101+// initctl restart --no-wait maliit-server; \
102+// initctl restart --no-wait unity8-dash\"");
102103}
plugins/Wizard/System.h+1−1
@@ -33,7 +33,7 @@ public:
3333 void setWizardEnabled(bool enabled);
3434
3535public Q_SLOTS:
36− void updateSessionLanguage(const QString &locale);
36+ void updateSessionLocale(const QString &locale);
3737
3838Q_SIGNALS:
3939 void wizardEnabledChanged();
qml/Wizard/Pages.qml+1−2
@@ -31,8 +31,7 @@ Item {
3131 // the user exits the wizard.
3232 property int passwordMethod: UbuntuSecurityPrivacyPanel.Passphrase
3333 property string password: ""
34− property string language: "" // language code
35− property string country: "" // country code, uppercase
34+ property string countryCode: "US"
3635
3736 UbuntuSecurityPrivacyPanel {
3837 id: securityPrivacy
qml/Wizard/Pages/10-language.qml+24−68
@@ -34,7 +34,7 @@ LocalComponents.Page {
3434
3535 Component.onCompleted: {
3636 if (!modemManager.available) { // don't wait for the modem if it's not there
37− init()
37+ init();
3838 }
3939 }
4040
@@ -50,63 +50,17 @@ LocalComponents.Page {
5050 {
5151 var detectedLangs = []
5252 if (simManager0.present && simManager0.preferredLanguages.length > 0) {
53− detectedLangs = simManager0.preferredLanguages
54− print("SIM 0 detected langs:", detectedLangs)
53+ detectedLangs = simManager0.preferredLanguages;
54+ print("SIM 0 detected langs:", detectedLangs);
5555 } else if (simManager1.present && simManager1.preferredLanguages.length > 0) {
56− detectedLangs = simManager1.preferredLanguages
57− print("SIM 1 detected langs:", detectedLangs)
56+ detectedLangs = simManager1.preferredLanguages;
57+ print("SIM 1 detected langs:", detectedLangs);
5858 } else {
59− print("No lang detected, falling back to default:", defaultLanguage)
60− detectedLangs = [defaultLanguage] // fallback to default lang
59+ print("No lang detected, falling back to default:", defaultLanguage);
60+ detectedLangs = [defaultLanguage]; // fallback to default lang
6161 }
6262
63− populateModel(false, detectedLangs)
64− }
65−
66− function populateModel(onlyDetected, detectedLangs)
67− {
68− model.clear()
69− var index = 0;
70− var selectedIndex = -1;
71− var langs = LocalePlugin.languages();
72− Object.keys(langs).map(function(code) { // prepare the object
73− //console.log("Got language:" + code);
74−
75− if (onlyDetected) {
76− if (!!detectedLangs && detectedLangs.indexOf(code) !== -1) {
77− return { "code": code, "language": langs[code] || code }
78− }
79− } else {
80− return { "code": code, "language": langs[code] || code }
81− }
82− return
83− })
84− .sort(function(a, b) { // sort by language name
85− return a.language.toLocaleLowerCase().localeCompare(b.language.toLocaleLowerCase()); // sort languages case insensitively
86− })
87− .forEach(function(lang) { // build the model
88− if (lang.code === "C") {
89− return;
90− }
91− model.append(lang);
92− if (!onlyDetected && detectedLangs.length > 0 && lang.code === detectedLangs[0]) { // preselect the first of detected languages
93− selectedIndex = index;
94− selectLanguage(lang.code, selectedIndex)
95− }
96− index++;
97− });
98−
99− if (selectedIndex !== -1) {
100− languagesListView.positionViewAtIndex(selectedIndex, ListView.Center)
101− }
102− }
103−
104− function selectLanguage(code, index)
105− {
106− root.language = code
107− languagesListView.currentIndex = index
108− print("Selected language: " + root.language)
109− print("Current index: " + languagesListView.currentIndex)
63+ //populateModel(false, detectedLangs)
11064 }
11165
11266 Column {
@@ -114,11 +68,10 @@ LocalComponents.Page {
11468 anchors.fill: content
11569
11670 ListView {
117− id: languagesListView;
118−
119− boundsBehavior: Flickable.StopAtBounds;
120− clip: true;
121− currentIndex: -1
71+ id: languagesListView
72+ boundsBehavior: Flickable.StopAtBounds
73+ clip: true
74+ currentIndex: plugin.currentLanguage
12275 snapMode: ListView.SnapToItem
12376
12477 anchors {
@@ -128,9 +81,7 @@ LocalComponents.Page {
12881
12982 height: column.height - column.spacing
13083
131− model: ListModel {
132− id: model;
133− }
84+ model: plugin.languageNames
13485
13586 delegate: ListItem {
13687 id: itemDelegate;
@@ -139,7 +90,7 @@ LocalComponents.Page {
13990
14091 Label {
14192 id: langLabel
142− text: language;
93+ text: modelData
14394
14495 anchors {
14596 left: parent.left;
@@ -164,7 +115,8 @@ LocalComponents.Page {
164115 }
165116
166117 onClicked: {
167− selectLanguage(code, index)
118+ languagesListView.currentIndex = index;
119+ i18n.language = plugin.languageCodes[index];
168120 }
169121 }
170122 }
@@ -174,12 +126,16 @@ LocalComponents.Page {
174126 id: forwardButton
175127 LocalComponents.StackButton {
176128 text: i18n.tr("Next")
177− enabled: root.language !== ""
129+ enabled: languagesListView.currentIndex
178130 onClicked: {
179− if (root.language !== plugin.languageCodes[plugin.currentLanguage]) {
180− i18n.language = i18n.language // re-notify of change after above call (for qlocale change)
131+ if (plugin.currentLanguage !== languagesListView.currentIndex) {
132+ plugin.currentLanguage = languagesListView.currentIndex;
133+ print("Updating session locale:", plugin.languageCodes[plugin.currentLanguage])
134+ System.updateSessionLocale(plugin.languageCodes[plugin.currentLanguage]);
181135 }
182− pageStack.next()
136+ i18n.language = plugin.languageCodes[plugin.currentLanguage]; // re-notify of change after above call (for qlocale change)
137+ root.countryCode = plugin.languageCodes[plugin.currentLanguage].split('_')[1].split('.')[0] // extract the country code, save it for the timezone page
138+ pageStack.next();
183139 }
184140 }
185141 }
qml/Wizard/Pages/15-country.qmldeleted−207
@@ -1,207 +0,0 @@
1−/*
2− * Copyright (C) 2013-2015 Canonical, Ltd.
3− *
4− * This program is free software; you can redistribute it and/or modify
5− * it under the terms of the GNU General Public License as published by
6− * the Free Software Foundation; version 3.
7− *
8− * This program is distributed in the hope that it will be useful,
9− * but WITHOUT ANY WARRANTY; without even the implied warranty of
10− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11− * GNU General Public License for more details.
12− *
13− * You should have received a copy of the GNU General Public License
14− * along with this program. If not, see <http://www.gnu.org/licenses/>.
15− */
16−
17−import QtQuick 2.3
18−import Ubuntu.Components 1.2
19−import Ubuntu.SystemSettings.LanguagePlugin 1.0
20−import Wizard 0.1
21−import ".." as LocalComponents
22−
23−LocalComponents.Page {
24− objectName: "countryPage"
25−
26− title: i18n.tr("Region")
27− forwardButtonSourceComponent: forwardButton
28−
29− Component.onCompleted: {
30− if (!modemManager.available) { // don't wait for the modem if it's not there
31− init()
32− }
33− }
34−
35− Connections {
36− target: modemManager
37− onModemsChanged: {
38− print("Modems changed")
39− init()
40− }
41− }
42−
43− function init()
44− {
45− var detectedCountry
46− if (simManager0.present && simManager0.mobileCountryCode) {
47− detectedCountry = LocalePlugin.mccToCountryCode(simManager0.mobileCountryCode)
48− print("SIM 0 detected country:", detectedCountry)
49− } else if (simManager1.present && simManager1.mobileCountryCode) {
50− detectedCountry = LocalePlugin.mccToCountryCode(simManager1.mobileCountryCode)
51− print("SIM 1 detected country:", detectedCountry)
52− } else if (!detectedCountry) {
53− detectedCountry = preferedCountry() // fallback to prefered country
54− print("No SIM country detected, falling back to prefered country:", detectedCountry)
55− }
56−
57− populateModel(detectedCountry)
58− }
59−
60− // return a prefered country for a language, but only if there's exactly one
61− function preferedCountry()
62− {
63− var countries = Object.keys(LocalePlugin.countriesForLanguage(root.language))
64− if (countries.length === 1) {
65− return countries[0]
66− }
67− // TODO should we ultimately fallback to "US" here?
68− }
69−
70− function populateModel(preferedCountry)
71− {
72− var countries = LocalePlugin.countries();
73− var index = 0
74− var selectedIndex = -1
75− //console.log("All countries:" + countries);
76− print("Prefered country", preferedCountry)
77− Object.keys(countries).map(function(code) { // prepare the object
78− //console.log("Got country:" + code);
79− return { "code": code, "country": countries[code] || code };
80− })
81− .sort(function(a, b) { // sort by country name
82− return a.country.localeCompare(b.country);
83− })
84− .forEach(function(country) { // build the model
85− //console.debug("Adding country:" + country.code);
86− if (country.code === "C") {
87− return;
88− }
89− model.append(country);
90− if (preferedCountry && country.code === preferedCountry) { // preselect the prefered country, if any
91− selectedIndex = index;
92− selectCountry(country.code, selectedIndex)
93− }
94− index++;
95− });
96− busyIndicator.running = false;
97− busyIndicator.visible = false;
98−
99− if (selectedIndex !== -1) {
100− regionsListView.positionViewAtIndex(selectedIndex, ListView.Center)
101− }
102− }
103−
104− function selectCountry(code, index)
105− {
106− root.country = code
107− regionsListView.currentIndex = index
108− print("Selected country: " + root.country)
109− print("Current index: " + regionsListView.currentIndex)
110− }
111−
112− UbuntuLanguagePlugin {
113− id: plugin
114− }
115−
116− ActivityIndicator {
117− id: busyIndicator;
118−
119− anchors.centerIn: column;
120− running: true;
121− }
122−
123− Column {
124− id: column
125− anchors.fill: content
126−
127− ListView {
128− id: regionsListView;
129−
130− boundsBehavior: Flickable.StopAtBounds;
131− clip: true;
132− currentIndex: -1
133− snapMode: ListView.SnapToItem
134−
135− anchors {
136− left: parent.left;
137− right: parent.right;
138− }
139−
140− height: column.height
141−
142− section {
143− property: "dept";
144− criteria: ViewSection.FullString;
145− labelPositioning: ViewSection.InlineLabels | ViewSection.CurrentLabelAtStart
146− delegate: Label {
147− fontSize: "x-large"
148− }
149− }
150−
151− model: ListModel {
152− id: model;
153− }
154−
155− delegate: ListItem {
156− id: itemDelegate;
157−
158− readonly property bool isCurrent: index === ListView.view.currentIndex
159−
160− Label {
161− id: countryLabel
162− text: country;
163−
164− anchors {
165− left: parent.left;
166− verticalCenter: parent.verticalCenter;
167− }
168−
169− fontSize: "medium"
170− font.weight: itemDelegate.isCurrent ? Font.Normal : Font.Light
171− color: "#525252"
172− }
173−
174− Image {
175− anchors {
176− right: parent.right;
177− verticalCenter: parent.verticalCenter;
178− }
179− fillMode: Image.PreserveAspectFit
180− height: countryLabel.paintedHeight
181−
182− source: "image://theme/tick"
183− visible: itemDelegate.isCurrent
184− }
185−
186− onClicked: {
187− selectCountry(code, index)
188− }
189− }
190− }
191− }
192−
193− Component {
194− id: forwardButton
195− LocalComponents.StackButton {
196− text: i18n.tr("Next")
197− enabled: root.country !== ""
198− onClicked: {
199− if (root.language !== plugin.languageCodes[plugin.currentLanguage]) {
200− plugin.currentLanguage = plugin.languageCodes.indexOf(root.language)
201− System.updateSessionLanguage(root.language + "_" + root.country); // also updates the locale
202− }
203− pageStack.next()
204− }
205− }
206− }
207−}
qml/Wizard/Pages/30-wifi.qml+8−16
@@ -87,6 +87,7 @@ LocalComponents.Page {
8787 property bool checked: menuData && menuData.isToggled || false
8888 property bool secure: getExtendedProperty(extendedData, "xCanonicalWifiApIsSecure", false)
8989 property bool adHoc: getExtendedProperty(extendedData, "xCanonicalWifiApIsAdhoc", false)
90+ property bool enterprise: getExtendedProperty(extendedData, "xCanonicalWifiApIsEnterprise", false)
9091 property int signalStrength: strengthAction.valid ? strengthAction.state : 0
9192 property int menuIndex: -1
9293
@@ -94,13 +95,15 @@ LocalComponents.Page {
9495 if (!unityMenuModel || menuIndex == -1) return;
9596 unityMenuModel.loadExtendedAttributes(menuIndex, {'x-canonical-wifi-ap-is-adhoc': 'bool',
9697 'x-canonical-wifi-ap-is-secure': 'bool',
98+ 'x-canonical-wifi-ap-is-enterprise': 'bool',
9799 'x-canonical-wifi-ap-strength-action': 'string'});
98100 }
99101
100− signal activate()
101−
102102 text: menuData && menuData.label || ""
103103 enabled: menuData && menuData.sensitive || false
104+ visible: !enterprise
105+ __foregroundColor: "#525252"
106+ showDivider: true
104107 iconName: {
105108 var imageName = "nm-signal-100";
106109
@@ -122,13 +125,7 @@ LocalComponents.Page {
122125 return imageName;
123126 }
124127 iconFrame: false
125− control: CheckBox {
126− id: checkBoxActive
127−
128− onClicked: {
129− accessPoint.activate();
130− }
131− }
128+ onClicked: unityMenuModel.activate(menuIndex);
132129
133130 Component.onCompleted: {
134131 loadAttributes();
@@ -139,11 +136,6 @@ LocalComponents.Page {
139136 onMenuIndexChanged: {
140137 loadAttributes();
141138 }
142− onCheckedChanged: {
143− // Can't rely on binding. Checked is assigned on click.
144− checkBoxActive.checked = checked;
145− }
146− onActivate: unityMenuModel.activate(menuIndex);
147139 }
148140 }
149141
@@ -159,8 +151,8 @@ LocalComponents.Page {
159151 anchors.right: parent.right
160152 font.weight: Font.Light
161153 color: "#525252"
162− text: mainMenu.count > 0 ? i18n.tr("Available networks")
163− : i18n.tr("No available networks.")
154+ text: mainMenu.count > 0 ? i18n.tr("Available Wi-Fi networks")
155+ : i18n.tr("No available Wi-Fi networks")
164156 }
165157
166158 Flickable {
qml/Wizard/Pages/50-timezone.qml+3−2
@@ -37,10 +37,11 @@ LocalComponents.Page {
3737 id: tzFilterModel
3838 sourceModel: tzModel
3939 filter: searchField.text
40− country: root.country
40+ country: root.countryCode
4141 }
4242
4343 Component.onCompleted: {
44+ print("Current i18n", i18n.language)
4445 theme.palette.normal.backgroundText = "#525252" // "fix" the placeholder text in the search field
4546 }
4647
@@ -81,7 +82,7 @@ LocalComponents.Page {
8182 }
8283
8384 onClicked: {
84− tzModel.selectedZoneId = id
85+ selectedTimeZone = id
8586 print("Selected tz: " + selectedTimeZone)
8687 print("Clicked country", countryCode)
8788 }
qml/Wizard/Pages/60-uaccount-signup.qmldeleted−185
@@ -1,185 +0,0 @@
1−/*
2− * Copyright (C) 2015 Canonical, Ltd.
3− *
4− * This program is free software; you can redistribute it and/or modify
5− * it under the terms of the GNU General Public License as published by
6− * the Free Software Foundation; version 3.
7− *
8− * This program is distributed in the hope that it will be useful,
9− * but WITHOUT ANY WARRANTY; without even the implied warranty of
10− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11− * GNU General Public License for more details.
12− *
13− * You should have received a copy of the GNU General Public License
14− * along with this program. If not, see <http://www.gnu.org/licenses/>.
15− */
16−
17−import QtQuick 2.3
18−import Ubuntu.Components 1.2
19−import ".." as LocalComponents
20−
21−LocalComponents.Page {
22− objectName: "ubuntuAccountSignUpPage"
23−
24− title: i18n.tr("Create Account")
25− customTitle: true
26− backButtonText: i18n.tr("Cancel")
27− forwardButtonSourceComponent: forwardButton
28−
29− Item {
30− id: column
31− anchors.fill: content
32−
33− // email
34− Label {
35− id: emailLabel
36− anchors.left: parent.left
37− anchors.right: parent.right
38− wrapMode: Text.Wrap
39− text: i18n.tr("Email:")
40− color: "#525252"
41− font.weight: Font.Light
42− }
43−
44− TextField {
45− id: emailInput
46− anchors.left: parent.left
47− anchors.right: parent.right
48− anchors.top: emailLabel.bottom
49− anchors.topMargin: units.gu(1)
50− inputMethodHints: Qt.ImhEmailCharactersOnly
51− validator: RegExpValidator {
52− regExp: /^(([^<>()[\]\.,;:\s@\"]+(\.[^<>()[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/i
53− }
54− KeyNavigation.tab: nameInput
55− }
56−
57− // name
58− Label {
59− id: nameLabel
60− anchors.left: parent.left
61− anchors.right: parent.right
62− anchors.top: emailInput.bottom
63− anchors.topMargin: units.gu(3)
64− wrapMode: Text.Wrap
65− text: i18n.tr("Your name:")
66− color: "#525252"
67− font.weight: Font.Light
68− }
69−
70− TextField {
71− id: nameInput
72− anchors.left: parent.left
73− anchors.right: parent.right
74− anchors.top: nameLabel.bottom
75− anchors.topMargin: units.gu(1)
76− KeyNavigation.tab: passInput
77− }
78−
79− // password
80− Label {
81− id: passLabel
82− anchors.left: parent.left
83− anchors.right: parent.right
84− anchors.top: nameInput.bottom
85− anchors.topMargin: units.gu(3)
86− wrapMode: Text.Wrap
87− text: i18n.tr("Password:")
88− color: "#525252"
89− font.weight: Font.Light
90− }
91−
92− TextField {
93− id: passInput
94− anchors.left: parent.left
95− anchors.right: parent.right
96− anchors.top: passLabel.bottom
97− anchors.topMargin: units.gu(1)
98− echoMode: TextInput.Password
99− KeyNavigation.tab: pass2Input
100− }
101−
102− // password meter
103− LocalComponents.PasswordMeter {
104− id: passMeter
105− anchors.left: parent.left
106− anchors.right: parent.right
107− anchors.top: passInput.bottom
108− anchors.topMargin: units.gu(1)
109− password: passInput.text
110− }
111−
112− // repeat password
113− Label {
114− id: pass2Label
115− anchors.left: parent.left
116− anchors.right: parent.right
117− anchors.top: passMeter.bottom
118− anchors.topMargin: passInput.text !== "" ? units.gu(6) : units.gu(3)
119− wrapMode: Text.Wrap
120− text: i18n.tr("Repeat password:")
121− color: "#525252"
122− font.weight: Font.Light
123− }
124−
125− TextField {
126− id: pass2Input
127− anchors.left: parent.left
128− anchors.right: parent.right
129− anchors.top: pass2Label.bottom
130− anchors.topMargin: units.gu(1)
131− echoMode: TextInput.Password
132− KeyNavigation.tab: encryptCheck
133− }
134−
135− LocalComponents.CheckableSetting {
136− id: encryptCheck
137− objectName: "encryptCheck"
138− showDivider: false
139− anchors.left: parent.left
140− anchors.right: parent.right
141− anchors.top: pass2Input.bottom
142− anchors.topMargin: units.gu(3)
143− text: i18n.tr("Encrypt my content")
144− KeyNavigation.tab: optoutCheck
145− }
146−
147− LocalComponents.CheckableSetting {
148− id: optoutCheck
149− objectName: "optoutCheck"
150− showDivider: false
151− anchors.left: parent.left
152− anchors.right: parent.right
153− anchors.top: encryptCheck.bottom
154− anchors.topMargin: units.gu(3)
155− text: i18n.tr("Opt out of cloud account (not recommended)")
156− KeyNavigation.tab: termsCheck
157− visible: false // TODO re-enable in Phase 2
158− }
159−
160− LocalComponents.CheckableSetting {
161− id: termsCheck
162− objectName: "termsCheck"
163− showDivider: false
164− anchors.left: parent.left
165− anchors.right: parent.right
166− anchors.top: optoutCheck.bottom
167− anchors.topMargin: units.gu(1)
168− text: i18n.tr("I have read and accept the Ubuntu account <a href='#'>terms of service</a>")
169− //onLinkActivated: pageStack.load(Qt.resolvedUrl("here-terms.qml")) // TODO show terms
170− KeyNavigation.tab: emailInput
171− visible: false // TODO re-enable in Phase 2
172− }
173− }
174−
175− Component {
176− id: forwardButton
177− LocalComponents.StackButton {
178− enabled: emailInput.acceptableInput && nameInput.text !== "" &&
179− //termsCheck.checked && // TODO re-enable in Phase 2
180− pass2Input.text.length > 5 && passInput.text === pass2Input.text
181− text: i18n.tr("Sign Up")
182− onClicked: pageStack.next() // TODO sign up against U1
183− }
184− }
185−}
tests/mocks/Wizard/MockSystem.cpp+5−2
@@ -14,6 +14,8 @@
1414 * with this program. If not, see <http://www.gnu.org/licenses/>.
1515 */
1616
17+#include <QDebug>
18+
1719#include "MockSystem.h"
1820
1921MockSystem::MockSystem()
@@ -33,7 +35,8 @@ void MockSystem::setWizardEnabled(bool enabled)
3335 Q_EMIT wizardEnabledChanged();
3436}
3537
36−void MockSystem::updateSessionLanguage(const QString &locale)
38+void MockSystem::updateSessionLocale(const QString &locale)
3739{
38− Q_EMIT updateSessionLanguageCalled(locale);
40+ qDebug() << Q_FUNC_INFO << locale;
41+ Q_EMIT updateSessionLocaleCalled(locale);
3942}
tests/mocks/Wizard/MockSystem.h+2−2
@@ -32,11 +32,11 @@ public:
3232 void setWizardEnabled(bool enabled);
3333
3434public Q_SLOTS:
35− void updateSessionLanguage(const QString &locale);
35+ void updateSessionLocale(const QString &locale);
3636
3737Q_SIGNALS:
3838 void wizardEnabledChanged();
39− void updateSessionLanguageCalled(const QString &locale); // only in mock
39+ void updateSessionLocaleCalled(const QString &locale); // only in mock
4040
4141private:
4242 Q_DISABLE_COPY(MockSystem)
tests/qmltests/Wizard/tst_Wizard.qml+1−1
@@ -51,7 +51,7 @@ Item {
5151 SignalSpy {
5252 id: updateSessionLanguageSpy
5353 target: System
54− signalName: "updateSessionLanguageCalled"
54+ signalName: "updateSessionLocaleCalled"
5555 }
5656
5757 SignalSpy {