diff options
author | 2021-01-16 08:59:22 -0800 | |
---|---|---|
committer | 2021-01-19 12:42:47 -0800 | |
commit | e1c269f54ccd075dff8abd70b10d27ca46b4365e (patch) | |
tree | 9ae87ae8291008cad4d06746fe4223707bd60406 /mobile-widgets/qml/SsrfTextField.qml | |
parent | f29534e07f82b3e7505cd657e8f9adf4dee44ce8 (diff) | |
download | subsurface-e1c269f54ccd075dff8abd70b10d27ca46b4365e.tar.gz |
mobile/edit: fix broken screen repositioning
In commit 622e5aab69 ("mobile/cleanup: remove more noisy debug output")
I had good intentions, but missed the fact that in order to access the
'verbose' variable from QML I needed to use manager.verboseEnabled. The
resulting syntax error went unnoticed and broke the screen repositioning
when the keyboard opens on mobile devices.
Worse, I called a non existing method to do the logging of debug
information.
And to top it all off, when I fixed the positioning algorithm in commit
765c4f9704 ("mobile/UI: fix the logic to keep input visible"), I forgot
to fix the near identical logic for the TextArea for the notes.
Fail on so many levels.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'mobile-widgets/qml/SsrfTextField.qml')
-rw-r--r-- | mobile-widgets/qml/SsrfTextField.qml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/mobile-widgets/qml/SsrfTextField.qml b/mobile-widgets/qml/SsrfTextField.qml index 083235435..8f07f5ee1 100644 --- a/mobile-widgets/qml/SsrfTextField.qml +++ b/mobile-widgets/qml/SsrfTextField.qml @@ -65,8 +65,8 @@ Controls.TextField { // make sure there's enough space for the input field above the keyboard and action button (and that it's not too far up, either) var positionInFlickable = stf.mapToItem(flickable.contentItem, 0, 0) var stfY = positionInFlickable.y - if (verbose) - manager.appendTextToLogFile("position check: lower edge of view is " + (0 + flickable.contentY + flickable.height) + " and text field is at " + stfY) + if (manager.verboseEnabebled) + manager.appendTextToLog("position check: lower edge of view is " + (0 + flickable.contentY + flickable.height) + " and text field is at " + stfY) if (stfY + stf.height > flickable.contentY + flickable.height - 3 * Kirigami.Units.gridUnit || stfY < flickable.contentY) flickable.contentY = Math.max(0, 3 * Kirigami.Units.gridUnit + stfY + stf.height - flickable.height) } |