[Libreoffice-commits] online.git: loleaflet/src
Pedro Pinto Silva (via logerrit)
logerrit at kemper.freedesktop.org
Thu Jan 23 14:50:35 UTC 2020
loleaflet/src/control/Control.Toolbar.js | 2 ++
1 file changed, 2 insertions(+)
New commits:
commit 1476d914e49a046021ca62927c58e057e57abb7f
Author: Pedro Pinto Silva <pedro.silva at collabora.com>
AuthorDate: Tue Jan 14 16:36:33 2020 +0100
Commit: Pedro Pinto da Silva <pedro.silva at collabora.com>
CommitDate: Thu Jan 23 15:50:16 2020 +0100
Desktop: id document-name-input: set input field based on its value
Change-Id: I8010b5fd435580a0637d5b9c5d23d5c109674c9c
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/86774
Reviewed-by: Pedro Pinto da Silva <pedro.silva at collabora.com>
Tested-by: Pedro Pinto da Silva <pedro.silva at collabora.com>
diff --git a/loleaflet/src/control/Control.Toolbar.js b/loleaflet/src/control/Control.Toolbar.js
index 24c416e96..5a765c4d8 100644
--- a/loleaflet/src/control/Control.Toolbar.js
+++ b/loleaflet/src/control/Control.Toolbar.js
@@ -1358,6 +1358,7 @@ function documentNameCancel() {
}
function onDocumentNameKeyPress(e) {
+ $('#document-name-input').css('width',(($('#document-name-input').val().length + 1) * 10) + 'px');
if (e.keyCode === 13) { // Enter key
documentNameConfirm();
} else if (e.keyCode === 27) { // Escape key
@@ -1512,6 +1513,7 @@ function onWopiProps(e) {
// set the document name into the name field
$('#document-name-input').val(e.BaseFileName);
}
+
if (e.UserCanNotWriteRelative === false) {
// Save As allowed
$('#document-name-input').prop('disabled', false);
More information about the Libreoffice-commits
mailing list