on xenial help sign in
Added checkbox for toggling between echo-modes of password-entryfields in ext. snap-decisions.
196f12eMirco Müller
Notifications/NotificationMenuItemFactory.qml+20−1
@@ -54,7 +54,8 @@ Loader {
54
54
55 Component.onCompleted: {
55 Component.onCompleted: {
56 menuModel.loadExtendedAttributes(menuIndex, {"x-echo-mode-password": "bool"});
56 menuModel.loadExtendedAttributes(menuIndex, {"x-echo-mode-password": "bool"});
57− textfield.echoMode = menuData.ext.xEchoModePassword ? TextInput.Password : TextInput.Normal
57+ checkBox.checked = menuData.ext.xEchoModePassword ? false : true
58+ checkBoxRow.visible = menuData.ext.xEchoModePassword
58 }
59 }
59
60
60 Label {
61 Label {
@@ -65,11 +66,29 @@ Loader {
65 id: textfield
66 id: textfield
66
67
67 anchors.left: parent.left; anchors.right: parent.right
68 anchors.left: parent.left; anchors.right: parent.right
69+ echoMode: checkBox.checked ? TextInput.Normal : TextInput.Password
68 height: units.gu(5)
70 height: units.gu(5)
69 onTextChanged: {
71 onTextChanged: {
70 menuModel.changeState(menuIndex, text);
72 menuModel.changeState(menuIndex, text);
71 }
73 }
72 }
74 }
75+
76+ Row {
77+ id: checkBoxRow
78+
79+ spacing: units.gu(.5)
80+
81+ CheckBox {
82+ id: checkBox
83+
84+ checked: false
85+ }
86+
87+ Label {
88+ anchors.verticalCenter: checkBox.verticalCenter
89+ text: i18n.tr("Show password")
90+ }
91+ }
73 }
92 }
74 }
93 }
75
94
po/unity8.pot+6−2
@@ -8,7 +8,7 @@ msgid ""
8msgstr ""
8msgstr ""
9"Project-Id-Version: unity8\n"
9"Project-Id-Version: unity8\n"
10"Report-Msgid-Bugs-To: \n"
10"Report-Msgid-Bugs-To: \n"
11−"POT-Creation-Date: 2013-10-11 12:12+0200\n"
11+"POT-Creation-Date: 2013-11-05 17:53+0100\n"
12"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
12"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
13"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14"Language-Team: LANGUAGE <LL@li.org>\n"
14"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -205,11 +205,15 @@ msgstr ""
205msgid "Speaking..."
205msgid "Speaking..."
206msgstr ""
206msgstr ""
207
207
208+#: Notifications/NotificationMenuItemFactory.qml:89
209+msgid "Show password"
210+msgstr ""
211+
208#: Panel/SearchIndicator.qml:27
212#: Panel/SearchIndicator.qml:27
209msgid "Search"
213msgid "Search"
210msgstr ""
214msgstr ""
211
215
212−#: plugins/Unity/scope.cpp:398
216+#: plugins/Unity/scope.cpp:408
213msgid "Sorry, there is nothing that matches your search."
217msgid "Sorry, there is nothing that matches your search."
214msgstr ""
218msgstr ""
215
219