From 088141efd90d82819983dabccd5e7d12cc76f09d Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Wed, 5 Sep 2018 17:03:27 +0300 Subject: [PATCH] [PE] Internal hyperlinks: entering the slide number manually --- .../main/app/view/HyperlinkSettingsDialog.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/apps/presentationeditor/main/app/view/HyperlinkSettingsDialog.js b/apps/presentationeditor/main/app/view/HyperlinkSettingsDialog.js index 796a8e1c9..3c222d5f6 100644 --- a/apps/presentationeditor/main/app/view/HyperlinkSettingsDialog.js +++ b/apps/presentationeditor/main/app/view/HyperlinkSettingsDialog.js @@ -197,12 +197,20 @@ define([ cls: 'input-group-nr', style: 'width: 50px;', menuStyle: 'min-width: 50px; max-height: 200px;', - editable: false, data: this.slides }); me.cmbSlides.setValue(0); me.cmbSlides.on('selected', _.bind(function(combo, record) { me.radioSlide.setValue(true); + }, me)) + .on('changed:after', _.bind(function(combo, record) { + me.radioSlide.setValue(true); + if (record.value>me.slides.length) + combo.setValue(me.slides.length-1); + else if (record.value<1) + combo.setValue(0); + else + combo.setValue(record.value-1); }, me)); $window.find('.dlg-btn').on('click', _.bind(this.onBtnClick, this));