diff --git a/apps/common/forms/lib/view/modals.js b/apps/common/forms/lib/view/modals.js index a759044154..9c34a0d098 100644 --- a/apps/common/forms/lib/view/modals.js +++ b/apps/common/forms/lib/view/modals.js @@ -44,13 +44,13 @@ define([ width: 300, header: true, style: 'min-width: 300px;', - cls: 'modal-dlg', - buttons: null + cls: 'modal-dlg' }, initialize : function(options) { _.extend(this.options, { - title: this.textTitle + title: this.textTitle, + buttons: [{value: 'ok', caption: this.txtCopy}] }, options || {}); this.template = [ @@ -73,10 +73,7 @@ define([ '', '', '', - '
', - '' + '
' ].join(''); this.options.tpl = _.template(this.template)(this.options); @@ -160,13 +157,13 @@ define([ width: 300, header: true, style: 'min-width: 300px;', - cls: 'modal-dlg', - buttons: null + cls: 'modal-dlg' }, initialize : function(options) { _.extend(this.options, { - title: this.textTitle + title: this.textTitle, + buttons: [{value: 'ok', caption: this.txtCopy}] }, options || {}); this.template = [ @@ -189,10 +186,7 @@ define([ '', '', '', - '
', - '' + '
' ].join(''); this.options.tpl = _.template(this.template)(this.options); diff --git a/apps/common/main/lib/component/Window.js b/apps/common/main/lib/component/Window.js index 017e3f15ad..b1fb40d255 100644 --- a/apps/common/main/lib/component/Window.js +++ b/apps/common/main/lib/component/Window.js @@ -179,7 +179,7 @@ define([ '<% if (typeof (buttons) !== "undefined" && _.size(buttons) > 0) { %>' + '' + '<% } %>' + @@ -629,12 +629,12 @@ define([ var newBtns = {}; _.each(options.buttons, function(b){ if (typeof(b) == 'object') { - if (b.value !== undefined) - newBtns[b.value] = {text: b.caption, cls: 'custom' + ((b.primary || options.primary==b.value) ? ' primary' : '')}; + if (b.value !== undefined) { + newBtns[b.value] = {text: b.caption, cls: 'auto' + ((b.primary || options.primary==b.value) ? ' primary' : '')}; + b.id && (newBtns[b.value].id = b.id); + } } else if (b!==undefined) { - newBtns[b] = {text: (b=='custom') ? options.customButtonText : arrBtns[b], cls: (options.primary==b || _.indexOf(options.primary, b)>-1) ? 'primary' : ''}; - if (b=='custom') - newBtns[b].cls += ' custom'; + newBtns[b] = {text: arrBtns[b], cls: (options.primary==b || _.indexOf(options.primary, b)>-1) ? 'primary' : ''}; } }); diff --git a/apps/common/main/lib/template/ExtendedColorDialog.template b/apps/common/main/lib/template/ExtendedColorDialog.template index f0bfb0c049..29796da59e 100644 --- a/apps/common/main/lib/template/ExtendedColorDialog.template +++ b/apps/common/main/lib/template/ExtendedColorDialog.template @@ -1,4 +1,4 @@ -
+
diff --git a/apps/common/main/lib/view/AdvancedSettingsWindow.js b/apps/common/main/lib/view/AdvancedSettingsWindow.js index 32e60c7f3d..3264046cc7 100644 --- a/apps/common/main/lib/view/AdvancedSettingsWindow.js +++ b/apps/common/main/lib/view/AdvancedSettingsWindow.js @@ -45,26 +45,32 @@ define([ initialize : function(options) { var _options = {}; _.extend(_options, { - height: 200, + height: 'auto', header: true, cls: 'advanced-settings-dlg', toggleGroup: 'advanced-settings-group', - contentTemplate: '', + contentTemplate: '', // use instead 'template' for internal layout + contentStyle: '', items: [], - buttons: ['ok', 'cancel'] + buttons: ['ok', 'cancel'], + separator: true }, options); this.template = options.template || [ - '
', + '
', + '<% if (items.length>0) { %>', '', '
', - '
' + _options.contentTemplate + '
', + '<% } %>', + '
' + _options.contentTemplate + '
', '
', - '
' + '<% if (separator) { %>', + '
', + '<% } %>' ].join(''); _options.tpl = _.template(this.template)(_options); @@ -105,6 +111,15 @@ define([ cnt_panel.width(this.contentWidth); $window.width(((menu_panel.length>0) ? menu_panel.width() : 0) + cnt_panel.outerWidth() + 2); + if (this.options.contentHeight) { + $window.find('.body > .box').css('height', this.options.contentHeight); + } else if (typeof this.options.height === 'number') { + var bodyEl = $window.find('.body'), + hfHeight = parseInt($window.find('.header').css('height')) + parseInt($window.find('.footer').css('height')) + parseInt(bodyEl.css('padding-top')) + parseInt(bodyEl.css('padding-bottom')) + + parseInt($window.css('border-bottom-width')) + parseInt($window.css('border-top-width')); + $window.find('.body > .box').css('height', this.options.height - hfHeight); + } + this.content_panels = $window.find('.settings-panel'); if (this.btnsCategory.length>0) this.btnsCategory[0].toggle(true, true); @@ -113,10 +128,20 @@ define([ setHeight: function(height) { Common.UI.Window.prototype.setHeight.call(this, height); - var $window = this.getChild(); - var boxEl = $window.find('.body > .box'); + var $window = this.getChild(), + bodyEl = $window.find('.body'), + footerHeight = parseInt($window.find('.footer').css('height')) + parseInt(bodyEl.css('padding-top')) + parseInt(bodyEl.css('padding-bottom')); + $window.find('.body > .box').css('height', parseInt(bodyEl.css('height')) - footerHeight); + }, - boxEl.css('height', height - 85); + setInnerHeight: function(height) { // height of box element + var $window = this.getChild(), + bodyEl = $window.find('.body'), + hfHeight = parseInt($window.find('.header').css('height')) + parseInt($window.find('.footer').css('height')) + parseInt(bodyEl.css('padding-top')) + parseInt(bodyEl.css('padding-bottom')) + + parseInt($window.css('border-bottom-width')) + parseInt($window.css('border-top-width')); + + Common.UI.Window.prototype.setHeight.call(this, height + hfHeight); + $window.find('.body > .box').css('height', height); }, onDlgBtnClick: function(event) { diff --git a/apps/common/main/lib/view/AutoCorrectDialog.js b/apps/common/main/lib/view/AutoCorrectDialog.js index eef39add96..de3ab651c6 100644 --- a/apps/common/main/lib/view/AutoCorrectDialog.js +++ b/apps/common/main/lib/view/AutoCorrectDialog.js @@ -52,8 +52,8 @@ define([ 'text!common/main/lib/template/AutoCorrectDialog.template', Common.Views.AutoCorrectDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 375, - height: 430, - buttons: null, + contentHeight: 345, + buttons: ['close'], toggleGroup: 'autocorrect-dialog-group' }, @@ -77,21 +77,7 @@ define([ 'text!common/main/lib/template/AutoCorrectDialog.template', title: this.textTitle, storageName: this.appPrefix + 'autocorrect-dialog-category', items: items, - template: [ - '
', - '', - '
', - '
' + _.template(contentTemplate)({scope: this}) + '
', - '
', - '
', - '' - ].join('') + contentTemplate: _.template(contentTemplate)({scope: this}) }, options || {}); this.api = this.options.api; diff --git a/apps/common/main/lib/view/CopyWarningDialog.js b/apps/common/main/lib/view/CopyWarningDialog.js index 747cbac4d0..7b6c8389ac 100644 --- a/apps/common/main/lib/view/CopyWarningDialog.js +++ b/apps/common/main/lib/view/CopyWarningDialog.js @@ -48,7 +48,6 @@ define([ Common.Views.CopyWarningDialog = Common.UI.Window.extend(_.extend({ options: { width : 500, - height : 325, cls : 'modal-dlg copy-warning', buttons: ['ok'] }, @@ -76,7 +75,7 @@ define([ '

' + this.textToPaste + '

', '
', '
', - '
', + '
', '
', '
' ].join(''); @@ -95,17 +94,6 @@ define([ }); this.getChild().find('.dlg-btn').on('click', _.bind(this.onBtnClick, this)); - this.autoSize(); - }, - - autoSize: function() { - var text_cnt = this.getChild('.box'), - footer = this.getChild('.footer'), - header = this.getChild('.header'), - body = this.getChild('.body'); - - body.height(parseInt(text_cnt.height()) + parseInt(footer.css('height'))); - this.setHeight(parseInt(body.css('height')) + parseInt(header.css('height'))); }, onBtnClick: function(event) { diff --git a/apps/common/main/lib/view/DocumentAccessDialog.js b/apps/common/main/lib/view/DocumentAccessDialog.js index 2a172447c8..35f568271c 100644 --- a/apps/common/main/lib/view/DocumentAccessDialog.js +++ b/apps/common/main/lib/view/DocumentAccessDialog.js @@ -48,7 +48,6 @@ define([ _.extend(_options, { title: this.textTitle, width: 600, - height: 536, header: true }, options); diff --git a/apps/common/main/lib/view/ExtendedColorDialog.js b/apps/common/main/lib/view/ExtendedColorDialog.js index f7e11d1110..c80c5cce19 100644 --- a/apps/common/main/lib/view/ExtendedColorDialog.js +++ b/apps/common/main/lib/view/ExtendedColorDialog.js @@ -48,7 +48,7 @@ define([ initialize : function(options) { Common.UI.Window.prototype.initialize.call(this, { - cls: 'extended-color-dlg', + cls: 'extended-color-dlg modal-dlg', tpl: this.tpl({ txtNew: this.textNew, txtCurrent: this.textCurrent, @@ -56,8 +56,7 @@ define([ txtCancel: this.cancelButtonText }), header: false, - width: 340, - height: 272 + width: 340 }); this.hexRe = /\s*#?([0-9a-fA-F][0-9a-fA-F]?)([0-9a-fA-F][0-9a-fA-F]?)([0-9a-fA-F][0-9a-fA-F]?)\s*/; diff --git a/apps/common/main/lib/view/ExternalEditor.js b/apps/common/main/lib/view/ExternalEditor.js index 4ab81feaa1..e28bb3e705 100644 --- a/apps/common/main/lib/view/ExternalEditor.js +++ b/apps/common/main/lib/view/ExternalEditor.js @@ -55,26 +55,24 @@ define([ value = Common.localStorage.getItem(this.storageName + '-height'); value && (height = parseInt(value)); - var _inner_height = Common.Utils.innerHeight() - Common.Utils.InternalSettings.get('window-inactive-area-top'); _.extend(_options, { width: width, - height: (_inner_height - height)<0 ? _inner_height : height, cls: 'advanced-settings-dlg', header: true, toolclose: 'hide', toolcallback: _.bind(this.onToolClose, this), resizable: true }, options); - - this._headerFooterHeight = 85; + // (!_options.buttons || _.size(_options.buttons)<1) && (_options.cls += ' no-footer'); + _options.contentHeight = height; this.template = [ - '
', + '
', '
', '
', '
', '' ].join(''); @@ -90,6 +88,16 @@ define([ render: function() { Common.UI.Window.prototype.render.call(this); this.boxEl = this.$window.find('.body > .box'); + var bodyEl = this.$window.find('> .body'); + this._headerFooterHeight = this.initConfig.header ? parseInt(this.$window.find('.header').css('height')) : 0; + this._headerFooterHeight += parseInt(this.$window.find('.footer').css('height')) + parseInt(bodyEl.css('padding-top')) + parseInt(bodyEl.css('padding-bottom')); + this._headerFooterHeight += ((parseInt(this.$window.css('border-top-width')) + parseInt(this.$window.css('border-bottom-width')))); + + var _inner_height = Common.Utils.innerHeight() - Common.Utils.InternalSettings.get('window-inactive-area-top'); + if (_inner_height < this.initConfig.contentHeight + this._headerFooterHeight) { + this.initConfig.contentHeight = _inner_height - this._headerFooterHeight; + this.boxEl.css('height', this.initConfig.contentHeight); + } this.btnSave = new Common.UI.Button({ el: this.$window.find('#id-btn-editor-apply'), diff --git a/apps/common/main/lib/view/InsertTableDialog.js b/apps/common/main/lib/view/InsertTableDialog.js index e6a667e50e..4a14f1ef8e 100644 --- a/apps/common/main/lib/view/InsertTableDialog.js +++ b/apps/common/main/lib/view/InsertTableDialog.js @@ -47,7 +47,6 @@ define([ Common.Views.InsertTableDialog = Common.UI.Window.extend(_.extend({ options: { width: 230, - height: 157, style: 'min-width: 230px;', cls: 'modal-dlg', id: 'window-insert-table', diff --git a/apps/common/main/lib/view/OpenDialog.js b/apps/common/main/lib/view/OpenDialog.js index a9379de77b..fdca2c612b 100644 --- a/apps/common/main/lib/view/OpenDialog.js +++ b/apps/common/main/lib/view/OpenDialog.js @@ -52,38 +52,15 @@ define([ var t = this, _options = {}; - var width, height; - - if (options.preview) { - width = 414; - height = (options.type==Common.Utils.importTextType.Data) ? 385 : 277; - } else { - width = (options.type !== Common.Utils.importTextType.DRM) ? 340 : (options.warning ? 420 : 280); - switch (options.type) { - case Common.Utils.importTextType.CSV: - case Common.Utils.importTextType.Paste: - case Common.Utils.importTextType.Columns: - height = 190; - break; - case Common.Utils.importTextType.Data: - height = 245; - break; - default: - height = options.warning ? 187 : 147; - break; - } - } - _.extend(_options, { closable : false, // true if save settings preview : options.preview, warning : options.warning, codepages : options.codepages, warningMsg : options.warningMsg, - width : width, - height : height, + width : options.preview ? 414 : (options.type !== Common.Utils.importTextType.DRM) ? 340 : (options.warning ? 420 : 280), header : true, - cls : 'open-dlg', + cls : 'modal-dlg open-dlg', contentTemplate : '', toolcallback : _.bind(t.onToolClose, t), closeFile : false @@ -93,13 +70,13 @@ define([ this.txtOpenFile = options.txtOpenFile || this.txtOpenFile; this.template = options.template || [ - '
', + '
', '
', '<% if (type == Common.Utils.importTextType.DRM) { %>', '<% if (warning) { %>', '
', '
', - '
' + (typeof _options.warningMsg=='string' ? _options.warningMsg : t.txtProtected) + '
', + '
' + (typeof _options.warningMsg=='string' ? _options.warningMsg : t.txtProtected) + '
', '', '
', '
', @@ -111,7 +88,7 @@ define([ '<% } %>', '<% } else { %>', '<% if (codepages && codepages.length>0) { %>', - '
class="margin-right-10" style="width: 230px;display: inline-block;margin-bottom:15px;" <% } else { %> style="width: 100%;margin-bottom:15px;"<% } %> >', + '
class="margin-right-10" style="width: 230px;display: inline-block;" <% } else { %> style="width: 100%;"<% } %> >', '', '
', '
', @@ -119,7 +96,7 @@ define([ '
', '<% } %>', '<% if (type == Common.Utils.importTextType.CSV) { %>', - '
', + '
', '', '
', '
', @@ -128,7 +105,7 @@ define([ '
', '<% } %>', '<% if (type == Common.Utils.importTextType.Paste || type == Common.Utils.importTextType.Columns || type == Common.Utils.importTextType.Data) { %>', - '
', + '
', '', '
', '
', @@ -138,7 +115,7 @@ define([ '
', '<% } %>', '<% if (!!preview) { %>', - '
', + '
', '', '
', '
', @@ -161,10 +138,10 @@ define([ '' ].join(''); diff --git a/apps/common/main/lib/view/PasswordDialog.js b/apps/common/main/lib/view/PasswordDialog.js index e8091f9fb1..3cfde5a6ab 100644 --- a/apps/common/main/lib/view/PasswordDialog.js +++ b/apps/common/main/lib/view/PasswordDialog.js @@ -54,7 +54,6 @@ define([ _.extend(_options, { width : 395, - height : 270, header : true, cls : 'modal-dlg', contentTemplate : '', diff --git a/apps/common/main/lib/view/PluginDlg.js b/apps/common/main/lib/view/PluginDlg.js index 7340b06781..851257c881 100644 --- a/apps/common/main/lib/view/PluginDlg.js +++ b/apps/common/main/lib/view/PluginDlg.js @@ -57,16 +57,15 @@ define([ automove: false }, options); - var header_footer = (_options.buttons && _.size(_options.buttons)>0) ? 85 : 34; - if (!_options.header) header_footer -= 34; this.bordersOffset = 40; _options.width = (Common.Utils.innerWidth()-this.bordersOffset*2-_options.width)<0 ? Common.Utils.innerWidth()-this.bordersOffset*2: _options.width; - _options.height += header_footer; - _options.height = (Common.Utils.innerHeight()-this.bordersOffset*2-_options.height)<0 ? Common.Utils.innerHeight()-this.bordersOffset*2: _options.height; _options.cls += ' advanced-settings-dlg invisible-borders'; + (!_options.buttons || _.size(_options.buttons)<1) && (_options.cls += ' no-footer'); + _options.contentHeight = _options.height; + _options.height = 'auto'; this.template = [ - '
', + '
', '
', '
', '<% if ((typeof buttons !== "undefined") && _.size(buttons) > 0) { %>', @@ -84,13 +83,21 @@ define([ render: function() { Common.UI.Window.prototype.render.call(this); - this.$window.find('> .body').css({height: 'auto', overflow: 'hidden'}); + var bodyEl = this.$window.find('> .body'); + bodyEl.css({height: 'auto', overflow: 'hidden'}); this.boxEl = this.$window.find('.body > .box'); - this._headerFooterHeight = (this.options.buttons && _.size(this.options.buttons)>0) ? 85 : 34; - if (!this.options.header) this._headerFooterHeight -= 34; + + this._headerFooterHeight = this.options.header ? parseInt(this.$window.find('.header').css('height')) : 0; + if (this.options.buttons && _.size(this.options.buttons)>0) + this._headerFooterHeight += parseInt(this.$window.find('.footer').css('height')) + parseInt(bodyEl.css('padding-top')) + parseInt(bodyEl.css('padding-bottom')); this._headerFooterHeight += ((parseInt(this.$window.css('border-top-width')) + parseInt(this.$window.css('border-bottom-width')))); + if (Common.Utils.innerHeight()-this.bordersOffset*2 < this.options.contentHeight + this._headerFooterHeight) { + this.options.contentHeight = Common.Utils.innerHeight()-this.bordersOffset*2 - this._headerFooterHeight; + this.boxEl.css('height', this.options.contentHeight); + } + this.$window.find('.header').prepend($('')); var iframe = document.createElement("iframe"); diff --git a/apps/common/main/lib/view/ReviewChanges.js b/apps/common/main/lib/view/ReviewChanges.js index 9878c39df7..e6ef05cdf2 100644 --- a/apps/common/main/lib/view/ReviewChanges.js +++ b/apps/common/main/lib/view/ReviewChanges.js @@ -987,7 +987,6 @@ define([ Common.Views.ReviewChangesDialog = Common.UI.Window.extend(_.extend({ options: { width : 330, - height : 90, title : 'Review Changes', modal : false, cls : 'review-changes modal-dlg', diff --git a/apps/common/main/lib/view/SaveAsDlg.js b/apps/common/main/lib/view/SaveAsDlg.js index d8f5976b0c..52d7f9ef9e 100644 --- a/apps/common/main/lib/view/SaveAsDlg.js +++ b/apps/common/main/lib/view/SaveAsDlg.js @@ -45,7 +45,6 @@ define([ _.extend(_options, { title: this.textTitle, width: 420, - height: 681, header: true }, options); diff --git a/apps/common/main/lib/view/SelectFileDlg.js b/apps/common/main/lib/view/SelectFileDlg.js index 81004365d0..101bbebe73 100644 --- a/apps/common/main/lib/view/SelectFileDlg.js +++ b/apps/common/main/lib/view/SelectFileDlg.js @@ -45,7 +45,6 @@ define([ _.extend(_options, { title: this.textTitle, width: 1024, - height: 621, header: true }, options); diff --git a/apps/common/main/resources/less/advanced-settings-window.less b/apps/common/main/resources/less/advanced-settings-window.less index 73c6ae6621..771458aa04 100644 --- a/apps/common/main/resources/less/advanced-settings-window.less +++ b/apps/common/main/resources/less/advanced-settings-window.less @@ -44,6 +44,13 @@ padding-right: 10px; } } + + padding-bottom: 15px; + } + &.no-footer { + .body { + padding-bottom: 0; + } } .footer { diff --git a/apps/common/main/resources/less/asc-mixins.less b/apps/common/main/resources/less/asc-mixins.less index 7d940f0759..1ae61b6c08 100644 --- a/apps/common/main/resources/less/asc-mixins.less +++ b/apps/common/main/resources/less/asc-mixins.less @@ -815,6 +815,12 @@ .padding-right(40px); } +.vertical-align-baseline { + vertical-align: baseline; + .ie & { + vertical-align: middle; + } +} //.adaptive-solid-border(@width, @color, @borderside: all) { // @lb-border: if((@borderside = all), border, e('border-@{borderside}')); // @lb-border-width: if((@borderside = all), border-width, e('border-@{borderside}-width')); diff --git a/apps/common/main/resources/less/buttons.less b/apps/common/main/resources/less/buttons.less index 8a5258bc80..995c461a76 100644 --- a/apps/common/main/resources/less/buttons.less +++ b/apps/common/main/resources/less/buttons.less @@ -1344,7 +1344,7 @@ opacity: @component-disabled-opacity; } - &.custom { + &.auto { width: auto; min-width: 86px; } diff --git a/apps/common/main/resources/less/extended-color-picker.less b/apps/common/main/resources/less/extended-color-picker.less index 6c0d5cc767..aad5044b3d 100644 --- a/apps/common/main/resources/less/extended-color-picker.less +++ b/apps/common/main/resources/less/extended-color-picker.less @@ -1,7 +1,5 @@ .extended-color-dlg { - .color-box { - padding: 16px 16px 5px 16px; - + .box { & > div { display: inline-block; } @@ -64,18 +62,4 @@ } } } - - - .footer { - height: 37px; - width: 100%; - bottom: 0; - text-align: center; - padding: 7px 0 0 0; - - button { - width: 75px; - height: 22px; - } - } } \ No newline at end of file diff --git a/apps/common/main/resources/less/opendialog.less b/apps/common/main/resources/less/opendialog.less index 54522bf9a4..a9acfa523a 100644 --- a/apps/common/main/resources/less/opendialog.less +++ b/apps/common/main/resources/less/opendialog.less @@ -1,9 +1,6 @@ .open-dlg { .body { - height: auto; - top: 34px; - & > div { width: 100%; } @@ -15,14 +12,9 @@ .content-panel { vertical-align: top; - padding: 15px 15px 0; + padding-bottom: 10px; width: 100%; - .inner-content { - padding-left: 10px; - padding-right: 10px; - } - label { .font-size-normal(); font-weight: normal; @@ -89,16 +81,4 @@ } } } - .footer { - padding-top: 15px; - - &.center { - text-align: center; - } - - &.justify { - padding-left: 30px; - padding-right: 30px; - } - } } \ No newline at end of file diff --git a/apps/common/main/resources/less/window.less b/apps/common/main/resources/less/window.less index f2b82fa11a..8614ce115e 100644 --- a/apps/common/main/resources/less/window.less +++ b/apps/common/main/resources/less/window.less @@ -363,7 +363,7 @@ .modal-dlg { .body { height: auto; - padding: 15px; + padding: 15px 0; .input-row { height: @input-height-base; @@ -379,10 +379,15 @@ label { .font-size-normal(); } + + .box { + padding-right: 15px; + padding-left: 15px; + } } .footer { - padding-top: 15px; + padding: 15px 15px 0; &.center { text-align: center; @@ -392,22 +397,22 @@ .text-align-right(); } } + + .separator.horizontal { + width: 100%; + } } // CopyWarningDialog .copy-warning { .body { - padding: 15px 0; - & > div { width: 100%; - padding: 0 20px; } .box { text-align: center; - padding-bottom: 15px; } .message{ text-align: justify; @@ -435,9 +440,5 @@ text-align: center; } } - - .footer { - padding: 20px; - } } } \ No newline at end of file diff --git a/apps/documenteditor/main/app/controller/Main.js b/apps/documenteditor/main/app/controller/Main.js index 6e6dc61ebf..8d6439d126 100644 --- a/apps/documenteditor/main/app/controller/Main.js +++ b/apps/documenteditor/main/app/controller/Main.js @@ -2652,9 +2652,8 @@ define([ width: 500, msg: this.appOptions.canChangeCoAuthoring ? this.textTryUndoRedo : this.textTryUndoRedoWarn, iconCls: 'info', - buttons: this.appOptions.canChangeCoAuthoring ? ['custom', 'cancel'] : ['ok'], + buttons: this.appOptions.canChangeCoAuthoring ? [{value: 'custom', caption: this.textStrict}, 'cancel'] : ['ok'], primary: this.appOptions.canChangeCoAuthoring ? 'custom' : 'ok', - customButtonText: this.textStrict, dontshow: true, callback: _.bind(function(btn, dontshow){ if (dontshow) Common.localStorage.setItem("de-hide-try-undoredo", 1); diff --git a/apps/documenteditor/main/app/template/ImageSettingsAdvanced.template b/apps/documenteditor/main/app/template/ImageSettingsAdvanced.template index 5d5b7d386f..fe350ac5c1 100644 --- a/apps/documenteditor/main/app/template/ImageSettingsAdvanced.template +++ b/apps/documenteditor/main/app/template/ImageSettingsAdvanced.template @@ -93,8 +93,8 @@
- -
+ +
diff --git a/apps/documenteditor/main/app/template/ParagraphSettingsAdvanced.template b/apps/documenteditor/main/app/template/ParagraphSettingsAdvanced.template index 4106b1a45b..8790e981e1 100644 --- a/apps/documenteditor/main/app/template/ParagraphSettingsAdvanced.template +++ b/apps/documenteditor/main/app/template/ParagraphSettingsAdvanced.template @@ -165,8 +165,8 @@
- -
+ +
diff --git a/apps/documenteditor/main/app/template/WatermarkSettings.template b/apps/documenteditor/main/app/template/WatermarkSettings.template index 69c66d3cf0..e6ef3eed66 100644 --- a/apps/documenteditor/main/app/template/WatermarkSettings.template +++ b/apps/documenteditor/main/app/template/WatermarkSettings.template @@ -1,4 +1,6 @@ - +
+
+
@@ -65,3 +67,5 @@
+
+
\ No newline at end of file diff --git a/apps/documenteditor/main/app/view/BookmarksDialog.js b/apps/documenteditor/main/app/view/BookmarksDialog.js index b7b9befd6a..61365292b1 100644 --- a/apps/documenteditor/main/app/view/BookmarksDialog.js +++ b/apps/documenteditor/main/app/view/BookmarksDialog.js @@ -50,8 +50,8 @@ define([ DE.Views.BookmarksDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 320, - height: 366, - buttons: null, + buttons: ['close'], + separator: false, id: 'window-bookmarks' }, @@ -60,10 +60,10 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0 5px;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '
', @@ -107,13 +107,8 @@ define([ '
', - '
', - '
', - '
', - '' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.api = options.api; diff --git a/apps/documenteditor/main/app/view/CaptionDialog.js b/apps/documenteditor/main/app/view/CaptionDialog.js index b7b45793c1..ac0074546b 100644 --- a/apps/documenteditor/main/app/view/CaptionDialog.js +++ b/apps/documenteditor/main/app/view/CaptionDialog.js @@ -48,7 +48,7 @@ define([ DE.Views.CaptionDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 351, - height: 350, + separator: false, id: 'window-caption' }, @@ -57,10 +57,10 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0 5px;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '
', @@ -121,9 +121,8 @@ define([ '
', '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.objectType = options.objectType; diff --git a/apps/documenteditor/main/app/view/ControlSettingsDialog.js b/apps/documenteditor/main/app/view/ControlSettingsDialog.js index 93eb2df562..79e997a6f0 100644 --- a/apps/documenteditor/main/app/view/ControlSettingsDialog.js +++ b/apps/documenteditor/main/app/view/ControlSettingsDialog.js @@ -50,7 +50,7 @@ define([ 'text!documenteditor/main/app/template/ControlSettingsDialog.template', DE.Views.ControlSettingsDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 310, - height: 405, + contentHeight: 320, toggleGroup: 'control-adv-settings-group', storageName: 'de-control-settings-adv-category' }, diff --git a/apps/documenteditor/main/app/view/CrossReferenceDialog.js b/apps/documenteditor/main/app/view/CrossReferenceDialog.js index 15c00c805b..58bf3d315c 100644 --- a/apps/documenteditor/main/app/view/CrossReferenceDialog.js +++ b/apps/documenteditor/main/app/view/CrossReferenceDialog.js @@ -45,7 +45,6 @@ define([ DE.Views.CrossReferenceDialog = Common.UI.Window.extend(_.extend({ options: { width: 400, - height: 410, style: 'min-width: 240px;', cls: 'modal-dlg', modal: false, diff --git a/apps/documenteditor/main/app/view/CustomColumnsDialog.js b/apps/documenteditor/main/app/view/CustomColumnsDialog.js index 76c2f859a6..b25c2c03ab 100644 --- a/apps/documenteditor/main/app/view/CustomColumnsDialog.js +++ b/apps/documenteditor/main/app/view/CustomColumnsDialog.js @@ -59,7 +59,7 @@ define([ }, options || {}); this.template = [ - '
', + '
', '
', '
', '
', diff --git a/apps/documenteditor/main/app/view/DateTimeDialog.js b/apps/documenteditor/main/app/view/DateTimeDialog.js index b6fd389d61..61697969b5 100644 --- a/apps/documenteditor/main/app/view/DateTimeDialog.js +++ b/apps/documenteditor/main/app/view/DateTimeDialog.js @@ -54,15 +54,12 @@ define([ }, initialize : function (options) { - var t = this, - _options = {}; - _.extend(this.options, { title: this.txtTitle }, options || {}); this.template = [ - '
', + '
', '
', '', '
', @@ -71,7 +68,7 @@ define([ '', '
', '
', - '
', + '
', '
', '', '
', diff --git a/apps/documenteditor/main/app/view/DropcapSettingsAdvanced.js b/apps/documenteditor/main/app/view/DropcapSettingsAdvanced.js index e17331d691..fb6c01deee 100644 --- a/apps/documenteditor/main/app/view/DropcapSettingsAdvanced.js +++ b/apps/documenteditor/main/app/view/DropcapSettingsAdvanced.js @@ -59,7 +59,7 @@ define([ DE.Views.DropcapSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 320, - height : 380, + contentHeight: 295, toggleGroup : 'dropcap-adv-settings-group', storageName: 'de-dropcap-settings-adv-category' }, @@ -702,7 +702,7 @@ define([ }, this); if (this.isFrame) - this.setHeight(500); + this.setInnerHeight(415); this.btnsCategory[(this.isFrame) ? 1 : 0].setVisible(false); if (this.storageName) { diff --git a/apps/documenteditor/main/app/view/FileMenuPanels.js b/apps/documenteditor/main/app/view/FileMenuPanels.js index d78d37ccb4..80a7e5b0fd 100644 --- a/apps/documenteditor/main/app/view/FileMenuPanels.js +++ b/apps/documenteditor/main/app/view/FileMenuPanels.js @@ -1960,7 +1960,7 @@ define([ '
', '', '', - '', + '', '', '' ].join('')); diff --git a/apps/documenteditor/main/app/view/HyphenationDialog.js b/apps/documenteditor/main/app/view/HyphenationDialog.js index 28168e0b39..c251be8aa4 100644 --- a/apps/documenteditor/main/app/view/HyphenationDialog.js +++ b/apps/documenteditor/main/app/view/HyphenationDialog.js @@ -46,7 +46,6 @@ define([ DE.Views.HyphenationDialog = Common.UI.Window.extend(_.extend({ options: { width: 290, - height: 'auto', header: true, style: 'min-width: 290px;', cls: 'modal-dlg', @@ -60,7 +59,7 @@ define([ }, options || {}); this.template = [ - '
', + '
', '', '', '', '<% if (type == 2) { %>', '', '', '', - '', + '', '', '
', diff --git a/apps/documenteditor/main/app/view/ImageSettingsAdvanced.js b/apps/documenteditor/main/app/view/ImageSettingsAdvanced.js index 343f8c4131..b7342951f2 100644 --- a/apps/documenteditor/main/app/view/ImageSettingsAdvanced.js +++ b/apps/documenteditor/main/app/view/ImageSettingsAdvanced.js @@ -50,7 +50,7 @@ define([ 'text!documenteditor/main/app/template/ImageSettingsAdvanced.templat DE.Views.ImageSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 340, - height: 485, + contentHeight: 400, toggleGroup: 'image-adv-settings-group', sizeOriginal: {width: 0, height: 0}, sizeMax: {width: 55.88, height: 55.88}, diff --git a/apps/documenteditor/main/app/view/LineNumbersDialog.js b/apps/documenteditor/main/app/view/LineNumbersDialog.js index 912718a623..d93cef4942 100644 --- a/apps/documenteditor/main/app/view/LineNumbersDialog.js +++ b/apps/documenteditor/main/app/view/LineNumbersDialog.js @@ -46,7 +46,6 @@ define([ DE.Views.LineNumbersDialog = Common.UI.Window.extend(_.extend({ options: { width: 290, - height: 332, header: true, style: 'min-width: 290px;', cls: 'modal-dlg', @@ -60,7 +59,7 @@ define([ }, options || {}); this.template = [ - '
', + '
', '
', '
', '
', diff --git a/apps/documenteditor/main/app/view/ListSettingsDialog.js b/apps/documenteditor/main/app/view/ListSettingsDialog.js index 89597d9e8e..d1e330738b 100644 --- a/apps/documenteditor/main/app/view/ListSettingsDialog.js +++ b/apps/documenteditor/main/app/view/ListSettingsDialog.js @@ -196,7 +196,7 @@ define([ '
', - '
', + '
', '', '', ' diff --git a/apps/spreadsheeteditor/main/app/template/FormatRulesManagerDlg.template b/apps/spreadsheeteditor/main/app/template/FormatRulesManagerDlg.template index b542fb59f7..f1ed78c871 100644 --- a/apps/spreadsheeteditor/main/app/template/FormatRulesManagerDlg.template +++ b/apps/spreadsheeteditor/main/app/template/FormatRulesManagerDlg.template @@ -19,7 +19,7 @@ - - diff --git a/apps/spreadsheeteditor/main/app/template/PrintSettings.template b/apps/spreadsheeteditor/main/app/template/PrintSettings.template index 4c46aab466..26358ff2aa 100644 --- a/apps/spreadsheeteditor/main/app/template/PrintSettings.template +++ b/apps/spreadsheeteditor/main/app/template/PrintSettings.template @@ -3,10 +3,10 @@
- -
- -
+ +
+ +
diff --git a/apps/spreadsheeteditor/main/app/template/ProtectRangesDlg.template b/apps/spreadsheeteditor/main/app/template/ProtectRangesDlg.template index 0c69b43de8..4c07c123b8 100644 --- a/apps/spreadsheeteditor/main/app/template/ProtectRangesDlg.template +++ b/apps/spreadsheeteditor/main/app/template/ProtectRangesDlg.template @@ -19,7 +19,7 @@
- diff --git a/apps/spreadsheeteditor/main/app/template/ProtectedRangesManagerDlg.template b/apps/spreadsheeteditor/main/app/template/ProtectedRangesManagerDlg.template index 1ca643e112..130eca48b4 100644 --- a/apps/spreadsheeteditor/main/app/template/ProtectedRangesManagerDlg.template +++ b/apps/spreadsheeteditor/main/app/template/ProtectedRangesManagerDlg.template @@ -21,7 +21,7 @@ - diff --git a/apps/spreadsheeteditor/main/app/template/SortDialog.template b/apps/spreadsheeteditor/main/app/template/SortDialog.template index e41022c64a..53ec59030e 100644 --- a/apps/spreadsheeteditor/main/app/template/SortDialog.template +++ b/apps/spreadsheeteditor/main/app/template/SortDialog.template @@ -19,7 +19,7 @@ - diff --git a/apps/spreadsheeteditor/main/app/template/WatchDialog.template b/apps/spreadsheeteditor/main/app/template/WatchDialog.template index 0c555cef6c..0e226bd8b4 100644 --- a/apps/spreadsheeteditor/main/app/template/WatchDialog.template +++ b/apps/spreadsheeteditor/main/app/template/WatchDialog.template @@ -8,7 +8,7 @@ - diff --git a/apps/spreadsheeteditor/main/app/view/AutoFilterDialog.js b/apps/spreadsheeteditor/main/app/view/AutoFilterDialog.js index fc8b6948b8..c76a90349b 100644 --- a/apps/spreadsheeteditor/main/app/view/AutoFilterDialog.js +++ b/apps/spreadsheeteditor/main/app/view/AutoFilterDialog.js @@ -55,17 +55,17 @@ define([ _.extend(_options, { width : options.type === 'date' ? 528 : 501, - height : 230, contentWidth : 180, header : true, - cls : 'filter-dlg' + (options.type === 'date' ? ' date-filter' : ''), + cls : 'filter-dlg modal-dlg' + (options.type === 'date' ? ' date-filter' : ''), contentTemplate : '', title : t.txtTitle, - items : [] + items : [], + buttons: ['ok', 'cancel'] }, options); this.template = options.template || [ - '
', + '
', '
', '', '
', @@ -87,11 +87,6 @@ define([ '<% } %>', '
', '
', - '
', - '
', - '' ].join(''); @@ -375,10 +370,9 @@ define([ _.extend(_options, { width : (this.type=='value') ? 450 : 318, - height : 160, contentWidth : 180, header : true, - cls : 'filter-dlg', + cls : 'filter-dlg modal-dlg', contentTemplate : '', title : t.txtTitle, items : [], @@ -386,7 +380,7 @@ define([ }, options); this.template = options.template || [ - '
', + '
', '
', '', '
', @@ -397,8 +391,7 @@ define([ '
', '
', '
', - '
', - '
' + '
' ].join(''); this.api = options.api; @@ -581,13 +574,13 @@ define([ _.extend(_options, { width : 501, - height : 210, contentWidth : 180, header : true, - cls : 'filter-dlg', + cls : 'filter-dlg modal-dlg', contentTemplate : '', title : (options.type=='label') ? t.txtTitleLabel : t.txtTitleValue, - items : [] + items : [], + buttons: ['ok', 'cancel'] }, options); this.api = options.api; @@ -595,7 +588,7 @@ define([ this.type = options.type || 'value'; this.template = options.template || [ - '
', + '
', '
', '', '
', @@ -610,11 +603,6 @@ define([ '', '
', '
', - '
', - '
', - '' ].join(''); @@ -860,10 +848,9 @@ define([ _.extend(_options, { width : 250, - height : 215, contentWidth : 180, header : true, - cls : 'filter-dlg', + cls : 'filter-dlg modal-dlg', contentTemplate : '', title : t.txtTitle, items : [], @@ -871,15 +858,14 @@ define([ }, options); this.template = options.template || [ - '
', + '
', '
', '
', '
', '
', '
', '
', - '
', - '
' + '
' ].join(''); this.api = options.api; @@ -1062,7 +1048,7 @@ define([ height : height || 277, contentWidth : (width - 50) || 400, header : false, - cls : 'filter-dlg autofilter invisible-borders', + cls : 'filter-dlg modal-dlg autofilter invisible-borders', contentTemplate : '', title : t.txtTitle, modal : false, diff --git a/apps/spreadsheeteditor/main/app/view/ChartDataDialog.js b/apps/spreadsheeteditor/main/app/view/ChartDataDialog.js index e2e723aaa0..ee5dcd1599 100644 --- a/apps/spreadsheeteditor/main/app/view/ChartDataDialog.js +++ b/apps/spreadsheeteditor/main/app/view/ChartDataDialog.js @@ -49,7 +49,6 @@ define([ SSE.Views.ChartDataDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 370, - height: 490, id: 'window-chart-data' }, @@ -58,10 +57,10 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0 10px;', + contentTemplate: _.template([ + '
', + '
', '
', diff --git a/apps/documenteditor/main/app/view/MailMergeEmailDlg.js b/apps/documenteditor/main/app/view/MailMergeEmailDlg.js index 6ca003f8b4..c108af2480 100644 --- a/apps/documenteditor/main/app/view/MailMergeEmailDlg.js +++ b/apps/documenteditor/main/app/view/MailMergeEmailDlg.js @@ -45,19 +45,14 @@ define([ 'text!documenteditor/main/app/template/MailMergeEmailDlg.template', DE.Views.MailMergeEmailDlg = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { alias: 'MailMergeEmail', - contentWidth: 500, - height: 435 + contentWidth: 500 }, initialize : function(options) { _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
' + _.template(contentTemplate)({scope: this}) + '
', - '
', - '
' - ].join('') + contentStyle: 'padding: 0;', + contentTemplate: _.template(contentTemplate)({scope: this}) }, options); Common.Views.AdvancedSettingsWindow.prototype.initialize.call(this, this.options); }, diff --git a/apps/documenteditor/main/app/view/MailMergeSettings.js b/apps/documenteditor/main/app/view/MailMergeSettings.js index 11a08c8222..e3b1471fba 100644 --- a/apps/documenteditor/main/app/view/MailMergeSettings.js +++ b/apps/documenteditor/main/app/view/MailMergeSettings.js @@ -639,9 +639,8 @@ define([ title: this.notcriticalErrorTitle, msg: opts.data.error, iconCls: 'warn', - buttons: _.isEmpty(opts.data.createEmailAccountUrl) ? ['ok'] : ['custom', 'cancel'], + buttons: _.isEmpty(opts.data.createEmailAccountUrl) ? ['ok'] : [{value: 'custom', caption: this.textGoToMail}, 'cancel'], primary: _.isEmpty(opts.data.createEmailAccountUrl) ? ['ok'] : 'custom', - customButtonText: this.textGoToMail, callback: _.bind(function(btn){ if (btn == 'custom') { window.open(opts.data.createEmailAccountUrl, "_blank"); diff --git a/apps/documenteditor/main/app/view/NoteSettingsDialog.js b/apps/documenteditor/main/app/view/NoteSettingsDialog.js index f6353694d0..49116dea26 100644 --- a/apps/documenteditor/main/app/view/NoteSettingsDialog.js +++ b/apps/documenteditor/main/app/view/NoteSettingsDialog.js @@ -47,10 +47,9 @@ define([ DE.Views.NoteSettingsDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { - contentWidth: 300, - height: 395, + contentWidth: 310, id: 'window-note-settings', - buttons: null + separator: false }, initialize : function(options) { @@ -58,10 +57,16 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', + buttons: [ + {value: 'insert', caption: this.textInsert}, + {value: 'apply', caption: this.textApply, id: 'note-settings-btn-apply'}, + 'cancel' + ], + primary: 'insert', + contentStyle: 'padding: 0 5px;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '
', @@ -115,15 +120,8 @@ define([ '
', - '
', - '
', - '
', - '' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.api = options.api; diff --git a/apps/documenteditor/main/app/view/NotesRemoveDialog.js b/apps/documenteditor/main/app/view/NotesRemoveDialog.js index 0ccd45a29c..4b2fe15b96 100644 --- a/apps/documenteditor/main/app/view/NotesRemoveDialog.js +++ b/apps/documenteditor/main/app/view/NotesRemoveDialog.js @@ -44,7 +44,6 @@ define([ DE.Views.NotesRemoveDialog = Common.UI.Window.extend(_.extend({ options: { width: 214, - height: 139, header: true, style: 'min-width: 214px;', cls: 'modal-dlg', diff --git a/apps/documenteditor/main/app/view/PageSizeDialog.js b/apps/documenteditor/main/app/view/PageSizeDialog.js index 932f1fa664..2bca7e0d09 100644 --- a/apps/documenteditor/main/app/view/PageSizeDialog.js +++ b/apps/documenteditor/main/app/view/PageSizeDialog.js @@ -58,7 +58,7 @@ define([ }, options || {}); this.template = [ - '
', + '
', '', '', '', '', '
', @@ -77,8 +77,7 @@ define([ '
', - '
', - '
' + '
' ].join(''); this.options.tpl = _.template(this.template)(this.options); diff --git a/apps/documenteditor/main/app/view/ParagraphSettingsAdvanced.js b/apps/documenteditor/main/app/view/ParagraphSettingsAdvanced.js index 96b71373f2..29af57e314 100644 --- a/apps/documenteditor/main/app/view/ParagraphSettingsAdvanced.js +++ b/apps/documenteditor/main/app/view/ParagraphSettingsAdvanced.js @@ -51,7 +51,7 @@ define([ 'text!documenteditor/main/app/template/ParagraphSettingsAdvanced.tem DE.Views.ParagraphSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 370, - height: 415, + contentHeight: 330, toggleGroup: 'paragraph-adv-settings-group', storageName: 'de-para-settings-adv-category' }, diff --git a/apps/documenteditor/main/app/view/RolesManagerDlg.js b/apps/documenteditor/main/app/view/RolesManagerDlg.js index 7e6c593297..a0e0acbebc 100644 --- a/apps/documenteditor/main/app/view/RolesManagerDlg.js +++ b/apps/documenteditor/main/app/view/RolesManagerDlg.js @@ -52,23 +52,15 @@ define([ 'text!documenteditor/main/app/template/RolesManagerDlg.template', options: { alias: 'RolesManagerDlg', contentWidth: 500, - height: 353, - buttons: null + buttons: ['close'] }, initialize: function (options) { var me = this; _.extend(this.options, { title: this.txtTitle, - template: [ - '
', - '
' + _.template(contentTemplate)({scope: this}) + '
', - '
', - '
', - '' - ].join('') + contentStyle: 'padding: 0;', + contentTemplate: _.template(contentTemplate)({scope: this}) }, options); this.api = options.api; diff --git a/apps/documenteditor/main/app/view/SaveFormDlg.js b/apps/documenteditor/main/app/view/SaveFormDlg.js index 06fbb4f93a..c43f004686 100644 --- a/apps/documenteditor/main/app/view/SaveFormDlg.js +++ b/apps/documenteditor/main/app/view/SaveFormDlg.js @@ -51,17 +51,19 @@ define([ 'common/main/lib/view/AdvancedSettingsWindow', options: { alias: 'SaveFormDlg', contentWidth: 320, - height: 280, - buttons: null + separator: false }, initialize: function (options) { var me = this; _.extend(this.options, { title: this.txtTitle, - template: [ - '
', - '
', + buttons: [ + {value: 'ok', caption: this.saveButtonText}, + 'cancel' + ], + contentStyle: 'padding: 0;', + contentTemplate: _.template([ '
', '
', '', @@ -82,14 +84,8 @@ define([ 'common/main/lib/view/AdvancedSettingsWindow', '', '
', '
', - '
', - '
', - '
', - '' - ].join('') + '' + ].join(''))({scope: this}) }, options); this.handler = options.handler; diff --git a/apps/documenteditor/main/app/view/StyleTitleDialog.js b/apps/documenteditor/main/app/view/StyleTitleDialog.js index 5ed0ebfeb5..038f2a95bb 100644 --- a/apps/documenteditor/main/app/view/StyleTitleDialog.js +++ b/apps/documenteditor/main/app/view/StyleTitleDialog.js @@ -44,7 +44,6 @@ define([ DE.Views.StyleTitleDialog = Common.UI.Window.extend(_.extend({ options: { width: 350, - height: 196, style: 'min-width: 230px;', cls: 'modal-dlg', buttons: ['ok', 'cancel'] diff --git a/apps/documenteditor/main/app/view/TableFormulaDialog.js b/apps/documenteditor/main/app/view/TableFormulaDialog.js index ab0d779de8..9981a2231a 100644 --- a/apps/documenteditor/main/app/view/TableFormulaDialog.js +++ b/apps/documenteditor/main/app/view/TableFormulaDialog.js @@ -56,7 +56,7 @@ define([ }, options || {}); this.template = [ - '
', + '
', '
', '', '
', @@ -65,7 +65,7 @@ define([ '', '
', '
', - '
', + '
', '
', '
', '
', diff --git a/apps/documenteditor/main/app/view/TableOfContentsSettings.js b/apps/documenteditor/main/app/view/TableOfContentsSettings.js index 6d7ab8f9aa..4daa2ad97c 100644 --- a/apps/documenteditor/main/app/view/TableOfContentsSettings.js +++ b/apps/documenteditor/main/app/view/TableOfContentsSettings.js @@ -48,21 +48,21 @@ define([ DE.Views.TableOfContentsSettings = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 500, - height: 460, + contentHeight: 375, id: 'window-table-contents' }, initialize : function(options) { var me = this; - var height = options.type ? 385 : 460; + var height = options.type ? 300 : 375; _.extend(this.options, { title: options.type ? this.textTitleTOF : this.textTitle, - height: height, - template: [ - '
', - '
', - '
', + contentHeight: height, + contentStyle: 'padding: 15px 10px;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '', '', '', @@ -92,7 +92,7 @@ define([ '', '', '', '', '', '', '', - '', + '', '', '
', @@ -81,8 +81,8 @@ define([ '
', - '', - '
', + '', + '
', '
', - '<% if (type == 1) { %>', + '<% if (scope.type == 1) { %>', '', '
', '
', @@ -105,7 +105,7 @@ define([ '
', - '<% if (type == 1) { %>', + '<% if (scope.type == 1) { %>', '
', '
', '
', @@ -115,8 +115,8 @@ define([ '
', '<% } else { %>', '
', - '', - '
', + '', + '
', '
', '', - '', - '', - '
' - ].join('') + '' + ].join(''))({scope: this}) }, options); this.api = options.api; diff --git a/apps/documenteditor/main/app/view/TableSettingsAdvanced.js b/apps/documenteditor/main/app/view/TableSettingsAdvanced.js index 8109cfc071..1cf6ad89cf 100644 --- a/apps/documenteditor/main/app/view/TableSettingsAdvanced.js +++ b/apps/documenteditor/main/app/view/TableSettingsAdvanced.js @@ -53,7 +53,7 @@ define([ 'text!documenteditor/main/app/template/TableSettingsAdvanced.templat DE.Views.TableSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 340, - height: 436, + contentHeight: 351, toggleGroup: 'table-adv-settings-group', storageName: 'de-table-settings-adv-category' }, diff --git a/apps/documenteditor/main/app/view/TableToTextDialog.js b/apps/documenteditor/main/app/view/TableToTextDialog.js index c77cee43d9..3d2edf2f7e 100644 --- a/apps/documenteditor/main/app/view/TableToTextDialog.js +++ b/apps/documenteditor/main/app/view/TableToTextDialog.js @@ -46,7 +46,6 @@ define([ DE.Views.TableToTextDialog = Common.UI.Window.extend(_.extend({ options: { width: 300, - height: 254, header: true, style: 'min-width: 240px;', cls: 'modal-dlg', diff --git a/apps/documenteditor/main/app/view/TextToTableDialog.js b/apps/documenteditor/main/app/view/TextToTableDialog.js index d0b61b8fa2..3108456c78 100644 --- a/apps/documenteditor/main/app/view/TextToTableDialog.js +++ b/apps/documenteditor/main/app/view/TextToTableDialog.js @@ -46,8 +46,7 @@ define([ DE.Views.TextToTableDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 300, - height: 405, - buttons: ['ok', 'cancel'] + separator: false }, initialize : function(options) { @@ -55,10 +54,10 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0 5px;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '
', @@ -131,10 +130,8 @@ define([ '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.handler = options.handler; diff --git a/apps/documenteditor/main/app/view/WatermarkSettingsDialog.js b/apps/documenteditor/main/app/view/WatermarkSettingsDialog.js index d2f91e21c6..76a2a9d0bc 100644 --- a/apps/documenteditor/main/app/view/WatermarkSettingsDialog.js +++ b/apps/documenteditor/main/app/view/WatermarkSettingsDialog.js @@ -76,7 +76,7 @@ define(['text!documenteditor/main/app/template/WatermarkSettings.template', DE.Views.WatermarkSettingsDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 400, - height: 442, + separator: false, id: 'window-watermark' }, @@ -85,19 +85,8 @@ define(['text!documenteditor/main/app/template/WatermarkSettings.template', _.extend(this.options, { title: this.textTitle, - template: _.template( - [ - '
', - '
', - '
', - template, - '
', - '
', - '
' - ].join('') - )({ - scope: this - }) + contentStyle: 'padding: 10px 5px;', + contentTemplate: _.template(template)({scope: this}) }, options); this.handler = options.handler; diff --git a/apps/documenteditor/main/resources/less/advanced-settings.less b/apps/documenteditor/main/resources/less/advanced-settings.less index 61ca58eeb1..77cdc1b459 100644 --- a/apps/documenteditor/main/resources/less/advanced-settings.less +++ b/apps/documenteditor/main/resources/less/advanced-settings.less @@ -41,6 +41,7 @@ } .canvas-box { + border: @scaled-one-px-value-ie solid @border-regular-control-ie; border: @scaled-one-px-value solid @border-regular-control; background-color: #fff; } diff --git a/apps/pdfeditor/main/app/controller/Main.js b/apps/pdfeditor/main/app/controller/Main.js index d418732953..66add9c806 100644 --- a/apps/pdfeditor/main/app/controller/Main.js +++ b/apps/pdfeditor/main/app/controller/Main.js @@ -2053,9 +2053,8 @@ define([ width: 500, msg: this.appOptions.canChangeCoAuthoring ? this.textTryUndoRedo : this.textTryUndoRedoWarn, iconCls: 'info', - buttons: this.appOptions.canChangeCoAuthoring ? ['custom', 'cancel'] : ['ok'], + buttons: this.appOptions.canChangeCoAuthoring ? [{value: 'custom', caption: this.textStrict}, 'cancel'] : ['ok'], primary: this.appOptions.canChangeCoAuthoring ? 'custom' : 'ok', - customButtonText: this.textStrict, dontshow: true, callback: _.bind(function(btn, dontshow){ if (dontshow) Common.localStorage.setItem("pdfe-hide-try-undoredo", 1); diff --git a/apps/pdfeditor/main/app/view/FileMenuPanels.js b/apps/pdfeditor/main/app/view/FileMenuPanels.js index 9dd4bcc173..c2fef93873 100644 --- a/apps/pdfeditor/main/app/view/FileMenuPanels.js +++ b/apps/pdfeditor/main/app/view/FileMenuPanels.js @@ -1656,7 +1656,7 @@ define([ '
' ].join('')); diff --git a/apps/presentationeditor/main/app/controller/Main.js b/apps/presentationeditor/main/app/controller/Main.js index 0d289441ec..c6adb852d8 100644 --- a/apps/presentationeditor/main/app/controller/Main.js +++ b/apps/presentationeditor/main/app/controller/Main.js @@ -2206,9 +2206,8 @@ define([ width: 500, msg: this.appOptions.canChangeCoAuthoring ? this.textTryUndoRedo : this.textTryUndoRedoWarn, iconCls: 'info', - buttons: this.appOptions.canChangeCoAuthoring ? ['custom', 'cancel'] : ['ok'], + buttons: this.appOptions.canChangeCoAuthoring ? [{value: 'custom', caption: this.textStrict}, 'cancel'] : ['ok'], primary: this.appOptions.canChangeCoAuthoring ? 'custom' : 'ok', - customButtonText: this.textStrict, dontshow: true, callback: _.bind(function(btn, dontshow){ if (dontshow) window.localStorage.setItem("pe-hide-try-undoredo", 1); diff --git a/apps/presentationeditor/main/app/template/HeaderFooterDialog.template b/apps/presentationeditor/main/app/template/HeaderFooterDialog.template index a1012d5858..cb73e1355f 100644 --- a/apps/presentationeditor/main/app/template/HeaderFooterDialog.template +++ b/apps/presentationeditor/main/app/template/HeaderFooterDialog.template @@ -1,4 +1,4 @@ - +
', '', '', - '', + '', '', '
diff --git a/apps/presentationeditor/main/app/template/ImageSettingsAdvanced.template b/apps/presentationeditor/main/app/template/ImageSettingsAdvanced.template index dd1779a0cd..ca967b0c18 100644 --- a/apps/presentationeditor/main/app/template/ImageSettingsAdvanced.template +++ b/apps/presentationeditor/main/app/template/ImageSettingsAdvanced.template @@ -69,8 +69,8 @@
- -
+ +
diff --git a/apps/presentationeditor/main/app/view/AnimationDialog.js b/apps/presentationeditor/main/app/view/AnimationDialog.js index 52d59b4d09..3ccc6a9d9e 100644 --- a/apps/presentationeditor/main/app/view/AnimationDialog.js +++ b/apps/presentationeditor/main/app/view/AnimationDialog.js @@ -43,9 +43,8 @@ define([ PE.Views.AnimationDialog = Common.UI.Window.extend(_.extend({ options: { width: 350, - height: 396, header: true, - cls: 'animation-dlg', + cls: 'modal-dlg', buttons: ['ok', 'cancel'] }, initialize : function(options) { @@ -53,11 +52,11 @@ define([ title: this.textTitle }, options || {}); this.template = [ - '
', + '
', '
', - '
', - '
', - // '
', + '
', + '
', + // '
', '
' ].join(''); this.allEffects = Common.define.effectData.getEffectFullData(); @@ -90,14 +89,11 @@ define([ var $window = this.getChild(); - var footer = $window.find('.footer'); - footer.css({"text-align": "center"}); - this.cmbGroup = new Common.UI.ComboBox({ el : $('#animation-group'), cls: 'input-group-nr', editable: false, - style : 'margin-top: 16px; width: 100%;', + style : 'width: 100%;', menuStyle: 'min-width: 100%;', takeFocusOnClose: true, data : this.EffectGroupData, @@ -110,7 +106,7 @@ define([ cls: 'input-group-nr', editable: false, valueField: 'id', - style : 'margin-top: 16px; width: 100%;', + style : 'width: 100%;', menuStyle: 'min-width: 100%;', takeFocusOnClose: true }); diff --git a/apps/presentationeditor/main/app/view/ChartSettingsAdvanced.js b/apps/presentationeditor/main/app/view/ChartSettingsAdvanced.js index 75b746b140..933525b016 100644 --- a/apps/presentationeditor/main/app/view/ChartSettingsAdvanced.js +++ b/apps/presentationeditor/main/app/view/ChartSettingsAdvanced.js @@ -46,7 +46,7 @@ define([ 'text!presentationeditor/main/app/template/ChartSettingsAdvanced.tem PE.Views.ChartSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 300, - height: 342, + contentHeight: 257, toggleGroup: 'chart-adv-settings-group', properties: null, storageName: 'pe-chart-settings-adv-category', diff --git a/apps/presentationeditor/main/app/view/DateTimeDialog.js b/apps/presentationeditor/main/app/view/DateTimeDialog.js index 2e828497d4..ac708d16ff 100644 --- a/apps/presentationeditor/main/app/view/DateTimeDialog.js +++ b/apps/presentationeditor/main/app/view/DateTimeDialog.js @@ -62,7 +62,7 @@ define([ }, options || {}); this.template = [ - '
', + '
', '
', '', '
', @@ -71,7 +71,7 @@ define([ '', '
', '
', - '
', + '
', '
', '', '
', diff --git a/apps/presentationeditor/main/app/view/FileMenuPanels.js b/apps/presentationeditor/main/app/view/FileMenuPanels.js index d0718bef23..3d63718226 100644 --- a/apps/presentationeditor/main/app/view/FileMenuPanels.js +++ b/apps/presentationeditor/main/app/view/FileMenuPanels.js @@ -1443,7 +1443,7 @@ define([ '
' ].join('')); diff --git a/apps/presentationeditor/main/app/view/GridSettings.js b/apps/presentationeditor/main/app/view/GridSettings.js index 085a4b24e3..e24fe917a2 100644 --- a/apps/presentationeditor/main/app/view/GridSettings.js +++ b/apps/presentationeditor/main/app/view/GridSettings.js @@ -59,14 +59,13 @@ define([ }, options || {}); this.template = [ - '
', + '
', '
', '', '
', - '
', - '
', - '
', - '
' + '
', + '
', + '
' ].join(''); this.options.tpl = _.template(this.template)(this.options); diff --git a/apps/presentationeditor/main/app/view/HeaderFooterDialog.js b/apps/presentationeditor/main/app/view/HeaderFooterDialog.js index fb76585706..a90c630aaf 100644 --- a/apps/presentationeditor/main/app/view/HeaderFooterDialog.js +++ b/apps/presentationeditor/main/app/view/HeaderFooterDialog.js @@ -47,8 +47,7 @@ define(['text!presentationeditor/main/app/template/HeaderFooterDialog.template', PE.Views.HeaderFooterDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 360, - height: 415, - buttons: null, + contentHeight: 330, id: 'window-header-footer' }, @@ -57,11 +56,17 @@ define(['text!presentationeditor/main/app/template/HeaderFooterDialog.template', _.extend(this.options, { title: this.textHFTitle, + buttons: [ + {value: 'all', caption: this.applyAllText}, + {value: 'ok', caption: this.applyText, id: 'hf-dlg-btn-apply'}, + 'cancel' + ], + primary: 'all', template: _.template( [ - '
', - '
', - '
', + '
', + '
', + '
', template, '
', '
', @@ -76,12 +81,7 @@ define(['text!presentationeditor/main/app/template/HeaderFooterDialog.template', '
', '
', '
', - '
', - '' + '
' ].join('') )({ scope: this diff --git a/apps/presentationeditor/main/app/view/ImageSettingsAdvanced.js b/apps/presentationeditor/main/app/view/ImageSettingsAdvanced.js index 4d1df4b759..98416cc8fe 100644 --- a/apps/presentationeditor/main/app/view/ImageSettingsAdvanced.js +++ b/apps/presentationeditor/main/app/view/ImageSettingsAdvanced.js @@ -48,7 +48,7 @@ define([ 'text!presentationeditor/main/app/template/ImageSettingsAdvanced.tem options: { alias: 'ImageSettingsAdvanced', contentWidth: 340, - height: 342, + contentHeight: 257, sizeOriginal: {width: 0, height: 0}, sizeMax: {width: 55.88, height: 55.88}, storageName: 'pe-img-settings-adv-category' diff --git a/apps/presentationeditor/main/app/view/ParagraphSettingsAdvanced.js b/apps/presentationeditor/main/app/view/ParagraphSettingsAdvanced.js index 136e62b3b7..dd406b1c18 100644 --- a/apps/presentationeditor/main/app/view/ParagraphSettingsAdvanced.js +++ b/apps/presentationeditor/main/app/view/ParagraphSettingsAdvanced.js @@ -49,7 +49,7 @@ define([ 'text!presentationeditor/main/app/template/ParagraphSettingsAdvanced PE.Views.ParagraphSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 370, - height: 394, + contentHeight: 309, toggleGroup: 'paragraph-adv-settings-group', storageName: 'pe-para-settings-adv-category' }, diff --git a/apps/presentationeditor/main/app/view/ShapeSettingsAdvanced.js b/apps/presentationeditor/main/app/view/ShapeSettingsAdvanced.js index 0f97910f26..aaf8c647b2 100644 --- a/apps/presentationeditor/main/app/view/ShapeSettingsAdvanced.js +++ b/apps/presentationeditor/main/app/view/ShapeSettingsAdvanced.js @@ -49,7 +49,7 @@ define([ 'text!presentationeditor/main/app/template/ShapeSettingsAdvanced.tem PE.Views.ShapeSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 300, - height: 342, + contentHeight: 257, toggleGroup: 'shape-adv-settings-group', sizeOriginal: {width: 0, height: 0}, sizeMax: {width: 55.88, height: 55.88}, diff --git a/apps/presentationeditor/main/app/view/SlideSizeSettings.js b/apps/presentationeditor/main/app/view/SlideSizeSettings.js index 0dddbccc49..7259cd5d83 100644 --- a/apps/presentationeditor/main/app/view/SlideSizeSettings.js +++ b/apps/presentationeditor/main/app/view/SlideSizeSettings.js @@ -58,7 +58,7 @@ define([ }, options || {}); this.template = [ - '
', + '
', '
', '', '
', @@ -82,9 +82,8 @@ define([ '
', '', '
', - '
', - '
', - '
' + '
', + '
' ].join(''); this.options.tpl = _.template(this.template)(this.options); diff --git a/apps/presentationeditor/main/app/view/SlideshowSettings.js b/apps/presentationeditor/main/app/view/SlideshowSettings.js index 976517390d..4c02d757ed 100644 --- a/apps/presentationeditor/main/app/view/SlideshowSettings.js +++ b/apps/presentationeditor/main/app/view/SlideshowSettings.js @@ -58,10 +58,9 @@ define([ }, options || {}); this.template = [ - '
', - '
', - '
', - '
' + '
', + '
', + '
' ].join(''); this.options.tpl = _.template(this.template)(this.options); diff --git a/apps/presentationeditor/main/app/view/TableSettingsAdvanced.js b/apps/presentationeditor/main/app/view/TableSettingsAdvanced.js index cbc4b0a4aa..3138c4a6fe 100644 --- a/apps/presentationeditor/main/app/view/TableSettingsAdvanced.js +++ b/apps/presentationeditor/main/app/view/TableSettingsAdvanced.js @@ -47,7 +47,7 @@ define([ 'text!presentationeditor/main/app/template/TableSettingsAdvanced.tem options: { alias: 'TableSettingsAdvanced', contentWidth: 280, - height: 385, + contentHeight: 300, storageName: 'pe-table-settings-adv-category', sizeMax: {width: 55.88, height: 55.88}, }, diff --git a/apps/presentationeditor/main/resources/less/rightmenu.less b/apps/presentationeditor/main/resources/less/rightmenu.less index fd60a2476d..050b94e989 100644 --- a/apps/presentationeditor/main/resources/less/rightmenu.less +++ b/apps/presentationeditor/main/resources/less/rightmenu.less @@ -1,7 +1,4 @@ -.settings-panel { -} - .right-panel .settings-panel { label.input-label{ vertical-align: baseline; diff --git a/apps/spreadsheeteditor/main/app/controller/Main.js b/apps/spreadsheeteditor/main/app/controller/Main.js index 03a64ae769..526cc5d4c9 100644 --- a/apps/spreadsheeteditor/main/app/controller/Main.js +++ b/apps/spreadsheeteditor/main/app/controller/Main.js @@ -2941,9 +2941,8 @@ define([ width: 500, msg: this.appOptions.canChangeCoAuthoring ? this.textTryUndoRedo : this.textTryUndoRedoWarn, iconCls: 'info', - buttons: this.appOptions.canChangeCoAuthoring ? ['custom', 'cancel'] : ['ok'], + buttons: this.appOptions.canChangeCoAuthoring ? [{value: 'custom', caption: this.textStrict}, 'cancel'] : ['ok'], primary: this.appOptions.canChangeCoAuthoring ? 'custom' : 'ok', - customButtonText: this.textStrict, dontshow: true, callback: _.bind(function(btn, dontshow){ if (dontshow) window.localStorage.setItem("sse-hide-try-undoredo", 1); diff --git a/apps/spreadsheeteditor/main/app/template/ChartVertAxis.template b/apps/spreadsheeteditor/main/app/template/ChartVertAxis.template index a9192b7e07..d62f4138e2 100644 --- a/apps/spreadsheeteditor/main/app/template/ChartVertAxis.template +++ b/apps/spreadsheeteditor/main/app/template/ChartVertAxis.template @@ -75,8 +75,8 @@
- -
+ +
+
diff --git a/apps/spreadsheeteditor/main/app/template/ImageSettingsAdvanced.template b/apps/spreadsheeteditor/main/app/template/ImageSettingsAdvanced.template index 027d607b09..efdba0c69b 100644 --- a/apps/spreadsheeteditor/main/app/template/ImageSettingsAdvanced.template +++ b/apps/spreadsheeteditor/main/app/template/ImageSettingsAdvanced.template @@ -1,8 +1,8 @@
- -
+ +
diff --git a/apps/spreadsheeteditor/main/app/template/NameManagerDlg.template b/apps/spreadsheeteditor/main/app/template/NameManagerDlg.template index fd60993267..d1b550e736 100644 --- a/apps/spreadsheeteditor/main/app/template/NameManagerDlg.template +++ b/apps/spreadsheeteditor/main/app/template/NameManagerDlg.template @@ -13,7 +13,7 @@
+
+
+
+
+
', '', '', '', '', - '', '', '
', @@ -102,16 +101,13 @@ define([ '
', + '', '', '
', - '
', - '', - '', - '
' - ].join('') + '' + ].join(''))({scope: this}) }, options); this.handler = options.handler; diff --git a/apps/spreadsheeteditor/main/app/view/ChartSettingsDlg.js b/apps/spreadsheeteditor/main/app/view/ChartSettingsDlg.js index 2776377c3d..a62556c23d 100644 --- a/apps/spreadsheeteditor/main/app/view/ChartSettingsDlg.js +++ b/apps/spreadsheeteditor/main/app/view/ChartSettingsDlg.js @@ -52,7 +52,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ChartSettingsDlg.template' SSE.Views.ChartSettingsDlg = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 327, - height: 535, + contentHeight: 450, toggleGroup: 'chart-settings-dlg-group', storageName: 'sse-chart-settings-adv-category' }, diff --git a/apps/spreadsheeteditor/main/app/view/ChartTypeDialog.js b/apps/spreadsheeteditor/main/app/view/ChartTypeDialog.js index 724df9f466..02359e91e1 100644 --- a/apps/spreadsheeteditor/main/app/view/ChartTypeDialog.js +++ b/apps/spreadsheeteditor/main/app/view/ChartTypeDialog.js @@ -69,7 +69,8 @@ define([ SSE.Views.ChartTypeDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 370, - height: 385 + contentHeight: 300, + separator: false }, initialize : function(options) { @@ -77,10 +78,10 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0 10px;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '
', @@ -100,10 +101,8 @@ define([ '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.handler = options.handler; diff --git a/apps/spreadsheeteditor/main/app/view/CreatePivotDialog.js b/apps/spreadsheeteditor/main/app/view/CreatePivotDialog.js index f1e97c4844..77b1623c25 100644 --- a/apps/spreadsheeteditor/main/app/view/CreatePivotDialog.js +++ b/apps/spreadsheeteditor/main/app/view/CreatePivotDialog.js @@ -47,7 +47,7 @@ define([ SSE.Views.CreatePivotDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 310, - height: 250, + separator: false, id: 'window-create-pivot' }, @@ -56,10 +56,10 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0 10px;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '', - '', '', '
', @@ -87,15 +87,13 @@ define([ '
', + '', '
', '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.api = options.api; diff --git a/apps/spreadsheeteditor/main/app/view/CreateSparklineDialog.js b/apps/spreadsheeteditor/main/app/view/CreateSparklineDialog.js index 3c9fcdacdf..0e8c2e50be 100644 --- a/apps/spreadsheeteditor/main/app/view/CreateSparklineDialog.js +++ b/apps/spreadsheeteditor/main/app/view/CreateSparklineDialog.js @@ -46,7 +46,7 @@ define([ SSE.Views.CreateSparklineDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 310, - height: 195 + separator: false }, initialize : function(options) { @@ -54,10 +54,10 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0 10px;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '', - '', '', '
', @@ -75,15 +75,13 @@ define([ '
', + '', '
', '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.api = options.api; diff --git a/apps/spreadsheeteditor/main/app/view/DataValidationDialog.js b/apps/spreadsheeteditor/main/app/view/DataValidationDialog.js index ccbbb60745..a5175e1a4a 100644 --- a/apps/spreadsheeteditor/main/app/view/DataValidationDialog.js +++ b/apps/spreadsheeteditor/main/app/view/DataValidationDialog.js @@ -50,7 +50,7 @@ define([ 'text!spreadsheeteditor/main/app/template/DataValidationDialog.templ SSE.Views.DataValidationDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 320, - height: 330, + contentHeight: 245, toggleGroup: 'data-validation-group', storageName: 'sse-data-validation-category' }, diff --git a/apps/spreadsheeteditor/main/app/view/ExternalLinksDlg.js b/apps/spreadsheeteditor/main/app/view/ExternalLinksDlg.js index f6fb3a2fcc..ce64bfafa4 100644 --- a/apps/spreadsheeteditor/main/app/view/ExternalLinksDlg.js +++ b/apps/spreadsheeteditor/main/app/view/ExternalLinksDlg.js @@ -51,18 +51,18 @@ define([ options: { alias: 'ExternalLinksDlg', contentWidth: 510, - height: 294, - buttons: null + separator: false, + buttons: ['close'] }, initialize: function (options) { var me = this; _.extend(this.options, { title: this.txtTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '', - '', '', '
', @@ -73,18 +73,13 @@ define([ '
', + '', '', '
', - '
', - '
', - '
', - '' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.api = options.api; @@ -98,7 +93,6 @@ define([ this.wrapEvents = { onUpdateExternalReferenceList: _.bind(this.refreshList, this) }; - Common.Views.AdvancedSettingsWindow.prototype.initialize.call(this, this.options); }, render: function () { diff --git a/apps/spreadsheeteditor/main/app/view/FieldSettingsDialog.js b/apps/spreadsheeteditor/main/app/view/FieldSettingsDialog.js index 679b277e0e..ecfaa93e28 100644 --- a/apps/spreadsheeteditor/main/app/view/FieldSettingsDialog.js +++ b/apps/spreadsheeteditor/main/app/view/FieldSettingsDialog.js @@ -50,7 +50,7 @@ define([ 'text!spreadsheeteditor/main/app/template/FieldSettingsDialog.templa SSE.Views.FieldSettingsDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 284, - height: 450, + contentHeight: 365, toggleGroup: 'pivot-field-settings-group', storageName: 'sse-pivot-field-settings-category' }, diff --git a/apps/spreadsheeteditor/main/app/view/FileMenuPanels.js b/apps/spreadsheeteditor/main/app/view/FileMenuPanels.js index df24cfe1a9..e0a9f8cb02 100644 --- a/apps/spreadsheeteditor/main/app/view/FileMenuPanels.js +++ b/apps/spreadsheeteditor/main/app/view/FileMenuPanels.js @@ -1835,7 +1835,7 @@ define([ '
' ].join('')); diff --git a/apps/spreadsheeteditor/main/app/view/FormatRulesEditDlg.js b/apps/spreadsheeteditor/main/app/view/FormatRulesEditDlg.js index 57dd206b57..2b3752f404 100644 --- a/apps/spreadsheeteditor/main/app/view/FormatRulesEditDlg.js +++ b/apps/spreadsheeteditor/main/app/view/FormatRulesEditDlg.js @@ -51,7 +51,6 @@ define([ 'text!spreadsheeteditor/main/app/template/FormatRulesEditDlg.template', options: { alias: 'FormatRulesEditDlg', contentWidth: 491, - height: 445, id: 'window-format-rules' }, @@ -60,12 +59,8 @@ define([ 'text!spreadsheeteditor/main/app/template/FormatRulesEditDlg.template', _.extend(this.options, { title: this.txtTitleNew, - template: [ - '
', - '
' + _.template(contentTemplate)({scope: this}) + '
', - '
', - '
' - ].join('') + contentStyle: 'padding: 0;', + contentTemplate: _.template(contentTemplate)({scope: this}) }, options); this.api = options.api; @@ -1500,7 +1495,7 @@ define([ 'text!spreadsheeteditor/main/app/template/FormatRulesEditDlg.template', (cmbData.length>0) && this.cmbRule.setValue((ruleType!==undefined) ? ruleType : cmbData[0].value); } this.setControls(index, this.cmbRule.getValue()); - this.setHeight(index==9 ? 445 : 355); + this.setInnerHeight(index==9 ? 360 : 270); if (rec) { var type = rec.get('type'); diff --git a/apps/spreadsheeteditor/main/app/view/FormatRulesManagerDlg.js b/apps/spreadsheeteditor/main/app/view/FormatRulesManagerDlg.js index 06e673eb90..cf3b7af90e 100644 --- a/apps/spreadsheeteditor/main/app/view/FormatRulesManagerDlg.js +++ b/apps/spreadsheeteditor/main/app/view/FormatRulesManagerDlg.js @@ -90,20 +90,16 @@ define([ 'text!spreadsheeteditor/main/app/template/FormatRulesManagerDlg.templa SSE.Views.FormatRulesManagerDlg = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { alias: 'FormatRulesManagerDlg', - contentWidth: 560, - height: 340, - buttons: ['ok', 'cancel'] + separator: false, + contentWidth: 560 }, initialize: function (options) { var me = this; _.extend(this.options, { title: this.txtTitle, - template: [ - '
', - '
' + _.template(contentTemplate)({scope: this}) + '
', - '
', - ].join('') + contentStyle: 'padding: 0;', + contentTemplate: _.template(contentTemplate)({scope: this}) }, options); this.api = options.api; diff --git a/apps/spreadsheeteditor/main/app/view/FormatSettingsDialog.js b/apps/spreadsheeteditor/main/app/view/FormatSettingsDialog.js index a075b52712..225cc61189 100644 --- a/apps/spreadsheeteditor/main/app/view/FormatSettingsDialog.js +++ b/apps/spreadsheeteditor/main/app/view/FormatSettingsDialog.js @@ -48,7 +48,7 @@ define([ SSE.Views.FormatSettingsDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 284, - height: 340 + contentHeight: 255 }, initialize : function(options) { @@ -88,14 +88,14 @@ define([ this.props = options.props; this.linked = options.linked || false; - var height = this.linked ? 360 : 340; + var height = this.linked ? 275 : 255; _.extend(this.options, { title: this.textTitle, - height: height, - template: [ - '
', - '
', + contentHeight: height, + contentStyle: 'padding: 0 10px;', + contentTemplate: _.template([ '
', + '
', '', '', '', '', '
', @@ -155,11 +155,8 @@ define([ '
', - '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); Common.Views.AdvancedSettingsWindow.prototype.initialize.call(this, this.options); diff --git a/apps/spreadsheeteditor/main/app/view/FormulaDialog.js b/apps/spreadsheeteditor/main/app/view/FormulaDialog.js index 56e208d7a9..9650b924a4 100644 --- a/apps/spreadsheeteditor/main/app/view/FormulaDialog.js +++ b/apps/spreadsheeteditor/main/app/view/FormulaDialog.js @@ -56,17 +56,19 @@ define([ _.extend(_options, { width : 375, - height : 490, header : true, - cls : 'formula-dlg', + cls : 'modal-dlg formula-dlg', contentTemplate : '', title : t.txtTitle, items : [], - buttons: null + buttons: [ + {value: 'ok', caption: this.okButtonText, primary: true, id: 'formula-dlg-btn-ok'}, + 'cancel' + ], }, options); this.template = options.template || [ - '
', + '
', '
', '', '', @@ -77,11 +79,7 @@ define([ '', '
', '
', - '
', - '' + '
' ].join(''); this.api = options.api; diff --git a/apps/spreadsheeteditor/main/app/view/FormulaWizard.js b/apps/spreadsheeteditor/main/app/view/FormulaWizard.js index db9eb40631..71e5b6eb3b 100644 --- a/apps/spreadsheeteditor/main/app/view/FormulaWizard.js +++ b/apps/spreadsheeteditor/main/app/view/FormulaWizard.js @@ -45,18 +45,18 @@ define([ SSE.Views.FormulaWizard = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 580, - height: 397 + contentHeight: 312 }, initialize : function(options) { var me = this; _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', - '', + contentStyle: 'padding: 0;', + contentTemplate: _.template([ + '
', + '
', + '
', '', '
', '', '
', @@ -81,11 +81,8 @@ define([ '
', '
', - '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.props = this.options.props; @@ -122,6 +119,8 @@ define([ this.lblFormulaResult = $window.find('#formula-wizard-value'); this.lblFunctionResult = $window.find('#formula-wizard-lbl-val-func'); + this.innerPanel.find('> table').css('height', this.options.contentHeight - 7); + this._preventCloseCellEditor = false; this.afterRender(); diff --git a/apps/spreadsheeteditor/main/app/view/HeaderFooterDialog.js b/apps/spreadsheeteditor/main/app/view/HeaderFooterDialog.js index 6ec3a7a134..0fb48dd688 100644 --- a/apps/spreadsheeteditor/main/app/view/HeaderFooterDialog.js +++ b/apps/spreadsheeteditor/main/app/view/HeaderFooterDialog.js @@ -81,7 +81,7 @@ define([ }; this.template = [ - '
', + '
', '', '', '
', diff --git a/apps/spreadsheeteditor/main/app/view/ImageSettingsAdvanced.js b/apps/spreadsheeteditor/main/app/view/ImageSettingsAdvanced.js index ff221b7d83..1ff628ba13 100644 --- a/apps/spreadsheeteditor/main/app/view/ImageSettingsAdvanced.js +++ b/apps/spreadsheeteditor/main/app/view/ImageSettingsAdvanced.js @@ -48,7 +48,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ImageSettingsAdvanced.temp SSE.Views.ImageSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 300, - height: 342, + contentHeight: 257, toggleGroup: 'image-adv-settings-group', properties: null, storageName: 'sse-image-settings-adv-category' diff --git a/apps/spreadsheeteditor/main/app/view/ImportFromXmlDialog.js b/apps/spreadsheeteditor/main/app/view/ImportFromXmlDialog.js index fd09c73fa0..38dbca1c84 100644 --- a/apps/spreadsheeteditor/main/app/view/ImportFromXmlDialog.js +++ b/apps/spreadsheeteditor/main/app/view/ImportFromXmlDialog.js @@ -47,7 +47,7 @@ define([ SSE.Views.ImportFromXmlDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 310, - height: 200 + separator: false }, initialize : function(options) { @@ -55,10 +55,10 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0 10px;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '', - '', '', '
', @@ -76,15 +76,13 @@ define([ '
', + '', '
', '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.api = options.api; diff --git a/apps/spreadsheeteditor/main/app/view/MacroDialog.js b/apps/spreadsheeteditor/main/app/view/MacroDialog.js index 9f36ca3799..792be168b3 100644 --- a/apps/spreadsheeteditor/main/app/view/MacroDialog.js +++ b/apps/spreadsheeteditor/main/app/view/MacroDialog.js @@ -48,7 +48,7 @@ define([ SSE.Views.MacroDialog = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 250, - height: 312 + separator: false }, initialize : function(options) { @@ -56,10 +56,10 @@ define([ _.extend(this.options, { title: this.textTitle, - template: [ - '
', - '
', + contentStyle: 'padding: 0 5px;', + contentTemplate: _.template([ '
', + '
', '', '', '', '', '
', @@ -77,10 +77,8 @@ define([ '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.handler = options.handler; diff --git a/apps/spreadsheeteditor/main/app/view/NameManagerDlg.js b/apps/spreadsheeteditor/main/app/view/NameManagerDlg.js index 75411cfeea..62c5dc0a10 100644 --- a/apps/spreadsheeteditor/main/app/view/NameManagerDlg.js +++ b/apps/spreadsheeteditor/main/app/view/NameManagerDlg.js @@ -52,8 +52,8 @@ define([ 'text!spreadsheeteditor/main/app/template/NameManagerDlg.template', options: { alias: 'NameManagerDlg', contentWidth: 540, - height: 330, - buttons: null, + buttons: ['close'], + separator: false, id: 'window-name-manager' }, @@ -61,14 +61,8 @@ define([ 'text!spreadsheeteditor/main/app/template/NameManagerDlg.template', var me = this; _.extend(this.options, { title: this.txtTitle, - template: [ - '
', - '
' + _.template(contentTemplate)({scope: this}) + '
', - '
', - '' - ].join('') + contentStyle: 'padding: 0;', + contentTemplate: _.template(contentTemplate)({scope: this}) }, options); this.api = options.api; diff --git a/apps/spreadsheeteditor/main/app/view/NamedRangeEditDlg.js b/apps/spreadsheeteditor/main/app/view/NamedRangeEditDlg.js index c6c32984d0..01599d64a6 100644 --- a/apps/spreadsheeteditor/main/app/view/NamedRangeEditDlg.js +++ b/apps/spreadsheeteditor/main/app/view/NamedRangeEditDlg.js @@ -50,8 +50,7 @@ define([ SSE.Views.NamedRangeEditDlg = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { alias: 'NamedRangeEditDlg', - contentWidth: 380, - height: 250 + contentWidth: 380 }, initialize: function (options) { @@ -59,10 +58,10 @@ define([ _.extend(this.options, { title: this.txtTitleNew, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0;', + contentTemplate: _.template([ + '
', + '
', '', '', '', '', '', - '', '', + '', + '', + '', '
', @@ -81,16 +80,17 @@ define([ '
', + '', '
', '
', + '
', - '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.api = options.api; diff --git a/apps/spreadsheeteditor/main/app/view/NamedRangePasteDlg.js b/apps/spreadsheeteditor/main/app/view/NamedRangePasteDlg.js index 42c3912d28..7133754aca 100644 --- a/apps/spreadsheeteditor/main/app/view/NamedRangePasteDlg.js +++ b/apps/spreadsheeteditor/main/app/view/NamedRangePasteDlg.js @@ -49,8 +49,8 @@ define([ SSE.Views.NamedRangePasteDlg = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { alias: 'NamedRangePasteDlg', - contentWidth: 250, - height: 282 + separator: false, + contentWidth: 250 }, initialize: function (options) { @@ -58,22 +58,20 @@ define([ _.extend(this.options, { title: this.txtTitle, - template: [ - '
', - '
', - '
', + contentStyle: 'padding: 0;', + contentTemplate: _.template([ + '
', + '
', '', '', - '', '', '
', + '', '', '
', '
', - '
', - '
', - '
' - ].join('') + '
' + ].join(''))({scope: this}) }, options); this.handler = options.handler; diff --git a/apps/spreadsheeteditor/main/app/view/PageMarginsDialog.js b/apps/spreadsheeteditor/main/app/view/PageMarginsDialog.js index 6aeaf00483..fde32a8560 100644 --- a/apps/spreadsheeteditor/main/app/view/PageMarginsDialog.js +++ b/apps/spreadsheeteditor/main/app/view/PageMarginsDialog.js @@ -60,7 +60,7 @@ define([ this.template = [ '
', - '', + '
', '', '', '', '
', '', @@ -97,8 +97,7 @@ define([ '
', - '
', - '
' + '' ].join(''); this.options.tpl = _.template(this.template)(this.options); diff --git a/apps/spreadsheeteditor/main/app/view/ParagraphSettingsAdvanced.js b/apps/spreadsheeteditor/main/app/view/ParagraphSettingsAdvanced.js index 5871a29401..0d4d765373 100644 --- a/apps/spreadsheeteditor/main/app/view/ParagraphSettingsAdvanced.js +++ b/apps/spreadsheeteditor/main/app/view/ParagraphSettingsAdvanced.js @@ -49,7 +49,7 @@ define([ 'text!spreadsheeteditor/main/app/template/ParagraphSettingsAdvanced. SSE.Views.ParagraphSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 370, - height: 394, + contentHeight: 309, toggleGroup: 'paragraph-adv-settings-group', storageName: 'sse-para-settings-adv-category' }, diff --git a/apps/spreadsheeteditor/main/app/view/PivotGroupDialog.js b/apps/spreadsheeteditor/main/app/view/PivotGroupDialog.js index b7947bb111..f4ab7fce6a 100644 --- a/apps/spreadsheeteditor/main/app/view/PivotGroupDialog.js +++ b/apps/spreadsheeteditor/main/app/view/PivotGroupDialog.js @@ -52,14 +52,14 @@ define([ initialize : function (options) { var t = this, - height = options.date ? 335 : 195; + height = options.date ? 250 : 110; _.extend(this.options, { title: this.txtTitle }, options || {}); this.template = options.template || [ - '
', + '
', '', '', '
', diff --git a/apps/spreadsheeteditor/main/app/view/PivotSettingsAdvanced.js b/apps/spreadsheeteditor/main/app/view/PivotSettingsAdvanced.js index 5b5910ee58..8ad63a3a98 100644 --- a/apps/spreadsheeteditor/main/app/view/PivotSettingsAdvanced.js +++ b/apps/spreadsheeteditor/main/app/view/PivotSettingsAdvanced.js @@ -50,7 +50,7 @@ define([ 'text!spreadsheeteditor/main/app/template/PivotSettingsAdvanced.temp SSE.Views.PivotSettingsAdvanced = Common.Views.AdvancedSettingsWindow.extend(_.extend({ options: { contentWidth: 310, - height: 440, + contentHeight: 355, toggleGroup: 'pivot-adv-settings-group', storageName: 'sse-pivot-adv-settings-category' }, diff --git a/apps/spreadsheeteditor/main/app/view/PrintSettings.js b/apps/spreadsheeteditor/main/app/view/PrintSettings.js index 39f8985a69..3f1ce431e9 100644 --- a/apps/spreadsheeteditor/main/app/view/PrintSettings.js +++ b/apps/spreadsheeteditor/main/app/view/PrintSettings.js @@ -50,7 +50,7 @@ define([ 'text!spreadsheeteditor/main/app/template/PrintSettings.template', options: { alias: 'PrintSettings', contentWidth: 280, - height: 513, + contentHeight: 468, buttons: null }, @@ -61,7 +61,7 @@ define([ 'text!spreadsheeteditor/main/app/template/PrintSettings.template', _.extend(this.options, { title: (this.type == 'print') ? this.textTitle : this.textTitlePDF, template: [ - '
', + '
', '