diff --git a/apps/common/main/lib/view/Header.js b/apps/common/main/lib/view/Header.js index be5bc6b591..641a334a3d 100644 --- a/apps/common/main/lib/view/Header.js +++ b/apps/common/main/lib/view/Header.js @@ -771,9 +771,9 @@ define([ $html.find('#slot-btn-share').hide(); } - if (isPDFEditor && config.isEdit && !config.isOffline && config.canSwitchMode) { + if (isPDFEditor && config.isEdit && config.canSwitchMode) { me.btnPDFMode = new Common.UI.Button({ - cls: 'btn-header btn-header-pdf-mode no-caret', + cls: 'btn-header btn-header-pdf-mode', iconCls: 'toolbar__icon icon--inverse btn-sheet-view', caption: me.textView, menu: true, @@ -785,7 +785,7 @@ define([ changePDFMode.call(me, config); } else if (isDocEditor && config.isEdit && config.canSwitchMode) { me.btnDocMode = new Common.UI.Button({ - cls: 'btn-header btn-header-pdf-mode no-caret', + cls: 'btn-header btn-header-pdf-mode ', iconCls: 'toolbar__icon icon--inverse ' + (config.isReviewOnly ? 'btn-ic-review' : 'btn-edit'), caption: config.isReviewOnly ? me.textReview : me.textEdit, menu: true, diff --git a/apps/common/main/resources/less/header.less b/apps/common/main/resources/less/header.less index 078a0f7035..98c53b7471 100644 --- a/apps/common/main/resources/less/header.less +++ b/apps/common/main/resources/less/header.less @@ -229,6 +229,19 @@ opacity: @header-component-hover-icon-opacity; } } + + .caret { + border-color: @icon-toolbar-header-ie; + border-color: @icon-toolbar-header; + } + + &:active:not(.disabled), + &.active:not(.disabled){ + .caret { + border-color: @icon-toolbar-header-ie; + border-color: @icon-toolbar-header; + } + } } svg.icon { @@ -349,7 +362,7 @@ width: auto; .caption { - margin: 2px 0 0 2px; + margin: 2px 4px 0 2px; color: @text-toolbar-header-ie; color: @text-toolbar-header; } diff --git a/apps/common/main/resources/less/toolbar.less b/apps/common/main/resources/less/toolbar.less index 70514979a8..0552f4752d 100644 --- a/apps/common/main/resources/less/toolbar.less +++ b/apps/common/main/resources/less/toolbar.less @@ -609,6 +609,11 @@ color: @text-normal; } + .caret { + border-color: @icon-normal-ie; + border-color: @icon-normal; + } + .inner-box-icon { > svg { fill: @text-normal-ie; @@ -649,6 +654,11 @@ color: @highlight-button-pressed-ie; color: @highlight-button-pressed; } + + .caret { + border-color: @icon-normal-pressed-ie; + border-color: @icon-normal-pressed; + } } } } diff --git a/apps/documenteditor/main/app/view/DateTimeDialog.js b/apps/documenteditor/main/app/view/DateTimeDialog.js index d07e9c0afa..39126c54b9 100644 --- a/apps/documenteditor/main/app/view/DateTimeDialog.js +++ b/apps/documenteditor/main/app/view/DateTimeDialog.js @@ -109,12 +109,21 @@ define([ this.updateFormats(record.value); }, this)); + var value = Common.Utils.InternalSettings.get("de-date-auto-update"); + if (value==null || value==undefined) { + value = Common.localStorage.getBool("de-date-auto-update"); + Common.Utils.InternalSettings.set("de-date-auto-update", value); + } + this.chUpdate = new Common.UI.CheckBox({ el: $('#datetime-dlg-update'), - labelText: this.textUpdate + labelText: this.textUpdate, + value: !!value }); this.chUpdate.on('change', _.bind(function(field, newValue, oldValue, eOpts){ this.onSelectFormat(this.listFormats, null, this.listFormats.getSelectedRec()); + Common.localStorage.setBool("de-date-auto-update", newValue==='checked'); + Common.Utils.InternalSettings.set("de-date-auto-update", newValue==='checked'); }, this)); this.listFormats = new Common.UI.ListView({ diff --git a/apps/documenteditor/main/app/view/ShapeSettings.js b/apps/documenteditor/main/app/view/ShapeSettings.js index 6aaab84e82..65bc50bd73 100644 --- a/apps/documenteditor/main/app/view/ShapeSettings.js +++ b/apps/documenteditor/main/app/view/ShapeSettings.js @@ -226,7 +226,18 @@ define([ } break; case Asc.c_oAscFill.FILL_TYPE_BLIP: - this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP; + if (this._state.FillType !== Asc.c_oAscFill.FILL_TYPE_BLIP && !this._noApply && this._texturearray && this._texturearray.length>0) { + this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP + var props = new Asc.asc_CShapeProperty(); + var fill = new Asc.asc_CShapeFill(); + fill.put_type(Asc.c_oAscFill.FILL_TYPE_BLIP); + fill.put_fill( new Asc.asc_CFillBlip()); + fill.get_fill().put_type(Asc.c_oAscFillBlipType.TILE); + fill.get_fill().put_texture_id(this._texturearray[0].type); + props.put_fill(fill); + this.imgprops.put_ShapeProperties(props); + this.api.ImgApply(this.imgprops); + } break; case Asc.c_oAscFill.FILL_TYPE_PATT: this._state.FillType = Asc.c_oAscFill.FILL_TYPE_PATT; diff --git a/apps/pdfeditor/main/app/view/ShapeSettings.js b/apps/pdfeditor/main/app/view/ShapeSettings.js index e75738db08..8e493d93aa 100644 --- a/apps/pdfeditor/main/app/view/ShapeSettings.js +++ b/apps/pdfeditor/main/app/view/ShapeSettings.js @@ -214,7 +214,17 @@ define([ } break; case Asc.c_oAscFill.FILL_TYPE_BLIP: - this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP; + if (this._state.FillType !== Asc.c_oAscFill.FILL_TYPE_BLIP && !this._noApply && this._texturearray && this._texturearray.length>0) { + this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP + var props = new Asc.asc_CShapeProperty(); + var fill = new Asc.asc_CShapeFill(); + fill.put_type(Asc.c_oAscFill.FILL_TYPE_BLIP); + fill.put_fill( new Asc.asc_CFillBlip()); + fill.get_fill().put_type(Asc.c_oAscFillBlipType.TILE); + fill.get_fill().put_texture_id(this._texturearray[0].type); + props.put_fill(fill); + this.api.ShapeApply(props); + } break; case Asc.c_oAscFill.FILL_TYPE_PATT: this._state.FillType = Asc.c_oAscFill.FILL_TYPE_PATT; diff --git a/apps/pdfeditor/main/app/view/TextArtSettings.js b/apps/pdfeditor/main/app/view/TextArtSettings.js index f49a361620..40d84cdb82 100644 --- a/apps/pdfeditor/main/app/view/TextArtSettings.js +++ b/apps/pdfeditor/main/app/view/TextArtSettings.js @@ -202,7 +202,18 @@ define([ } break; case Asc.c_oAscFill.FILL_TYPE_BLIP: - this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP; + if (this._state.FillType !== Asc.c_oAscFill.FILL_TYPE_BLIP && !this._noApply && this._texturearray && this._texturearray.length>0) { + this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP + var props = new Asc.asc_TextArtProperties(); + var fill = new Asc.asc_CShapeFill(); + fill.put_type(Asc.c_oAscFill.FILL_TYPE_BLIP); + fill.put_fill( new Asc.asc_CFillBlip()); + fill.get_fill().put_type(Asc.c_oAscFillBlipType.TILE); + fill.get_fill().put_texture_id(this._texturearray[0].type); + props.asc_putFill(fill); + this.shapeprops.put_TextArtProperties(props); + this.api.ShapeApply(this.shapeprops); + } break; case Asc.c_oAscFill.FILL_TYPE_PATT: this._state.FillType = Asc.c_oAscFill.FILL_TYPE_PATT; diff --git a/apps/presentationeditor/main/app/view/ShapeSettings.js b/apps/presentationeditor/main/app/view/ShapeSettings.js index 60eb0c5fbb..5302a10bbe 100644 --- a/apps/presentationeditor/main/app/view/ShapeSettings.js +++ b/apps/presentationeditor/main/app/view/ShapeSettings.js @@ -214,7 +214,17 @@ define([ } break; case Asc.c_oAscFill.FILL_TYPE_BLIP: - this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP; + if (this._state.FillType !== Asc.c_oAscFill.FILL_TYPE_BLIP && !this._noApply && this._texturearray && this._texturearray.length>0) { + this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP + var props = new Asc.asc_CShapeProperty(); + var fill = new Asc.asc_CShapeFill(); + fill.put_type(Asc.c_oAscFill.FILL_TYPE_BLIP); + fill.put_fill( new Asc.asc_CFillBlip()); + fill.get_fill().put_type(Asc.c_oAscFillBlipType.TILE); + fill.get_fill().put_texture_id(this._texturearray[0].type); + props.put_fill(fill); + this.api.ShapeApply(props); + } break; case Asc.c_oAscFill.FILL_TYPE_PATT: this._state.FillType = Asc.c_oAscFill.FILL_TYPE_PATT; diff --git a/apps/presentationeditor/main/app/view/SlideSettings.js b/apps/presentationeditor/main/app/view/SlideSettings.js index af640fa383..73fc431c4b 100644 --- a/apps/presentationeditor/main/app/view/SlideSettings.js +++ b/apps/presentationeditor/main/app/view/SlideSettings.js @@ -313,7 +313,17 @@ define([ } break; case Asc.c_oAscFill.FILL_TYPE_BLIP: - this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP; + if (this._state.FillType !== Asc.c_oAscFill.FILL_TYPE_BLIP && !this._noApply && this._texturearray && this._texturearray.length>0) { + this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP + var props = new Asc.CAscSlideProps(); + var fill = new Asc.asc_CShapeFill(); + fill.put_type(Asc.c_oAscFill.FILL_TYPE_BLIP); + fill.put_fill( new Asc.asc_CFillBlip()); + fill.get_fill().put_type(Asc.c_oAscFillBlipType.TILE); + fill.get_fill().put_texture_id(this._texturearray[0].type); + props.put_background(fill); + this.api.SetSlideProps(props); + } break; case Asc.c_oAscFill.FILL_TYPE_PATT: this._state.FillType = Asc.c_oAscFill.FILL_TYPE_PATT; diff --git a/apps/presentationeditor/main/app/view/TextArtSettings.js b/apps/presentationeditor/main/app/view/TextArtSettings.js index 5ebae663a3..255402a918 100644 --- a/apps/presentationeditor/main/app/view/TextArtSettings.js +++ b/apps/presentationeditor/main/app/view/TextArtSettings.js @@ -202,7 +202,18 @@ define([ } break; case Asc.c_oAscFill.FILL_TYPE_BLIP: - this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP; + if (this._state.FillType !== Asc.c_oAscFill.FILL_TYPE_BLIP && !this._noApply && this._texturearray && this._texturearray.length>0) { + this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP + var props = new Asc.asc_TextArtProperties(); + var fill = new Asc.asc_CShapeFill(); + fill.put_type(Asc.c_oAscFill.FILL_TYPE_BLIP); + fill.put_fill( new Asc.asc_CFillBlip()); + fill.get_fill().put_type(Asc.c_oAscFillBlipType.TILE); + fill.get_fill().put_texture_id(this._texturearray[0].type); + props.asc_putFill(fill); + this.shapeprops.put_TextArtProperties(props); + this.api.ShapeApply(this.shapeprops); + } break; case Asc.c_oAscFill.FILL_TYPE_PATT: this._state.FillType = Asc.c_oAscFill.FILL_TYPE_PATT; diff --git a/apps/spreadsheeteditor/main/app/view/ShapeSettings.js b/apps/spreadsheeteditor/main/app/view/ShapeSettings.js index ac9d1a6692..2ac1536d57 100644 --- a/apps/spreadsheeteditor/main/app/view/ShapeSettings.js +++ b/apps/spreadsheeteditor/main/app/view/ShapeSettings.js @@ -217,7 +217,18 @@ define([ } break; case Asc.c_oAscFill.FILL_TYPE_BLIP: - this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP; + if (this._state.FillType !== Asc.c_oAscFill.FILL_TYPE_BLIP && !this._noApply && this._texturearray && this._texturearray.length>0) { + this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP + var props = new Asc.asc_CShapeProperty(); + var fill = new Asc.asc_CShapeFill(); + fill.asc_putType(Asc.c_oAscFill.FILL_TYPE_BLIP); + fill.asc_putFill( new Asc.asc_CFillBlip()); + fill.asc_getFill().asc_putType(Asc.c_oAscFillBlipType.TILE); + fill.asc_getFill().asc_putTextureId(this._texturearray[0].type); + props.asc_putFill(fill); + this.imgprops.asc_putShapeProperties(props); + this.api.asc_setGraphicObjectProps(this.imgprops); + } break; case Asc.c_oAscFill.FILL_TYPE_PATT: this._state.FillType = Asc.c_oAscFill.FILL_TYPE_PATT; diff --git a/apps/spreadsheeteditor/main/app/view/TextArtSettings.js b/apps/spreadsheeteditor/main/app/view/TextArtSettings.js index 112c2f8b01..ba0aff6844 100644 --- a/apps/spreadsheeteditor/main/app/view/TextArtSettings.js +++ b/apps/spreadsheeteditor/main/app/view/TextArtSettings.js @@ -203,7 +203,18 @@ define([ } break; case Asc.c_oAscFill.FILL_TYPE_BLIP: - this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP; + if (this._state.FillType !== Asc.c_oAscFill.FILL_TYPE_BLIP && !this._noApply && this._texturearray && this._texturearray.length>0) { + this._state.FillType = Asc.c_oAscFill.FILL_TYPE_BLIP + var props = new Asc.asc_TextArtProperties(); + var fill = new Asc.asc_CShapeFill(); + fill.asc_putType(Asc.c_oAscFill.FILL_TYPE_BLIP); + fill.asc_putFill( new Asc.asc_CFillBlip()); + fill.asc_getFill().asc_putType(Asc.c_oAscFillBlipType.TILE); + fill.asc_getFill().asc_putTextureId(this._texturearray[0].type); + props.asc_putFill(fill); + this.shapeprops.put_TextArtProperties(props); + this.api.asc_setGraphicObjectProps(this.imgprops); + } break; case Asc.c_oAscFill.FILL_TYPE_PATT: this._state.FillType = Asc.c_oAscFill.FILL_TYPE_PATT;