[Libreoffice-commits] online.git: loleaflet/src
Tor Lillqvist (via logerrit)
logerrit at kemper.freedesktop.org
Tue Mar 31 17:36:09 UTC 2020
loleaflet/src/control/Control.Toolbar.js | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
New commits:
commit b0c09e14daa89e7da35dd7b140632305fbb93f3c
Author: Tor Lillqvist <tml at collabora.com>
AuthorDate: Tue Mar 31 20:14:23 2020 +0300
Commit: Tor Lillqvist <tml at collabora.com>
CommitDate: Tue Mar 31 19:35:51 2020 +0200
Add a (commented-out) way to see the initial visualViewport scale and size
Ideally it should update as the device is rotated or the document
window is resized by Split View. We should have some field somehwere
where all kinds of debugging information, including this
visualViewport information, would be displayed by simply un-commenting
a single line.
Change-Id: I7d3960440272c03040e0f4ad5dd65f49d5a98780
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/91437
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Tor Lillqvist <tml at collabora.com>
diff --git a/loleaflet/src/control/Control.Toolbar.js b/loleaflet/src/control/Control.Toolbar.js
index 059dc28e5..f6606bdd5 100644
--- a/loleaflet/src/control/Control.Toolbar.js
+++ b/loleaflet/src/control/Control.Toolbar.js
@@ -1735,7 +1735,11 @@ function onDocLayerInit() {
$('#document-name-input').focus(function() { $(this).blur(); });
// Call decodecodeURIComponent twice: Reverse both our encoding and the encoding of
// the name in the file system.
- $('#document-name-input').val(decodeURIComponent(decodeURIComponent(map.options.doc.replace(/.*\//, ''))));
+ $('#document-name-input').val(decodeURIComponent(decodeURIComponent(map.options.doc.replace(/.*\//, '')))
+ // To conveniently see the initial visualViewport scale and size, un-comment the following line.
+ // + ' (' + window.visualViewport.scale + '*' + window.visualViewport.width + 'x' + window.visualViewport.height + ')'
+ // TODO: Yes, it would be better to see it change as you rotate the device or invoke Split View.
+ );
}
if (!window.ThisIsTheiOSApp && window.mode.isTablet()) {
More information about the Libreoffice-commits
mailing list