mirror of
https://github.com/monero-project/monero-gui.git
synced 2025-01-23 19:15:56 +00:00
wizard: disable password strenght meter on mobiles
This commit is contained in:
parent
bcb7bcffdb
commit
0e6028aacf
2 changed files with 21 additions and 13 deletions
|
@ -83,6 +83,10 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
|
|
||||||
function switchPage(next) {
|
function switchPage(next) {
|
||||||
|
|
||||||
|
// Android focus workaround
|
||||||
|
releaseFocus();
|
||||||
|
|
||||||
// save settings for current page;
|
// save settings for current page;
|
||||||
if (next && typeof pages[currentPage].onPageClosed !== 'undefined') {
|
if (next && typeof pages[currentPage].onPageClosed !== 'undefined') {
|
||||||
if (pages[currentPage].onPageClosed(settings) !== true) {
|
if (pages[currentPage].onPageClosed(settings) !== true) {
|
||||||
|
|
|
@ -42,6 +42,8 @@ ColumnLayout {
|
||||||
|
|
||||||
wizard.nextButton.enabled = passwordItem.password === retypePasswordItem.password
|
wizard.nextButton.enabled = passwordItem.password === retypePasswordItem.password
|
||||||
|
|
||||||
|
// TODO: password strength meter segfaults on Android.
|
||||||
|
if (!isMobile) {
|
||||||
// scorePassword returns value from 0 to... lots
|
// scorePassword returns value from 0 to... lots
|
||||||
var strength = walletManager.getPasswordStrength(passwordItem.password);
|
var strength = walletManager.getPasswordStrength(passwordItem.password);
|
||||||
// consider anything below 10 bits as dire
|
// consider anything below 10 bits as dire
|
||||||
|
@ -56,6 +58,7 @@ ColumnLayout {
|
||||||
// privacyLevel component uses 1..13 scale
|
// privacyLevel component uses 1..13 scale
|
||||||
privacyLevel.fillLevel = Utils.mapScope(1, 100, 1, 13, strength)
|
privacyLevel.fillLevel = Utils.mapScope(1, 100, 1, 13, strength)
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function resetFocus() {
|
function resetFocus() {
|
||||||
passwordItem.focus = true
|
passwordItem.focus = true
|
||||||
|
@ -85,6 +88,7 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
|
|
||||||
PrivacyLevelSmall {
|
PrivacyLevelSmall {
|
||||||
|
visible: !isMobile //TODO: strength meter doesnt work on Android
|
||||||
Layout.topMargin: isMobile ? 20 * scaleRatio : 40 * scaleRatio
|
Layout.topMargin: isMobile ? 20 * scaleRatio : 40 * scaleRatio
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
id: privacyLevel
|
id: privacyLevel
|
||||||
|
|
Loading…
Reference in a new issue