[Libreoffice-commits] online.git: loleaflet/src
Faruk Uzun
farukuzun at collabora.com
Sun Jan 17 11:21:40 PST 2016
loleaflet/src/control/Control.Presentation.js | 9 +++++++++
1 file changed, 9 insertions(+)
New commits:
commit 3fa796f26a8d864630f70d0e9999c40d8f97ed25
Author: Faruk Uzun <farukuzun at collabora.com>
Date: Thu Jan 14 06:34:44 2016 +0200
loleaflet: Add dialog to confirm slide deletion
ccu#1423 related.
Change-Id: Ibf6ce88de2742b0277b2df63225f1a3f374de45d
Reviewed-on: https://gerrit.libreoffice.org/21461
Reviewed-by: Andras Timar <andras.timar at collabora.com>
Tested-by: Andras Timar <andras.timar at collabora.com>
diff --git a/loleaflet/src/control/Control.Presentation.js b/loleaflet/src/control/Control.Presentation.js
index edefa2f..188f252 100644
--- a/loleaflet/src/control/Control.Presentation.js
+++ b/loleaflet/src/control/Control.Presentation.js
@@ -70,6 +70,15 @@ L.Control.Presentation = L.Control.extend({
this._map.duplicatePage();
}
else if (id === 'deletepage') {
+ vex.dialog.confirm({
+ message: 'Are you sure you want to delete this page?',
+ callback: L.bind(this._onDelete, this)
+ });
+ }
+ },
+
+ _onDelete: function (e) {
+ if (e !== false) {
this._map.deletePage();
}
}
More information about the Libreoffice-commits
mailing list