This commit is contained in:
OVSharova 2021-12-23 15:53:38 +03:00
parent 5f81e7311a
commit 8574ce4455
3 changed files with 21 additions and 11 deletions

View file

@ -259,11 +259,9 @@
<div class="separator long"></div> <div class="separator long"></div>
<div class="group small"> <div class="group small">
<div class="elset font-normal"> <div class="elset font-normal">
<div class = "text">
<label id="animation-repeat"></label> <label id="animation-repeat"></label>
<span id="animation-spin-repeat" class="btn-slot text spinner" ></span> <span id="animation-spin-repeat" class="btn-slot text spinner" ></span>
</div> </div>
</div>
<div class="elset font-normal"> <div class="elset font-normal">
<span class="btn-slot text" id="animation-checkbox-rewind"></span> <span class="btn-slot text" id="animation-checkbox-rewind"></span>
</div> </div>

View file

@ -215,8 +215,10 @@ define([
iconCls: 'toolbar__icon transition-fade', iconCls: 'toolbar__icon transition-fade',
lock: [_set.slideDeleted, _set.noSlides, _set.noAnimationPreview], lock: [_set.slideDeleted, _set.noSlides, _set.noAnimationPreview],
dataHint: '1', dataHint: '1',
dataHintDirection: 'left', /*dataHintDirection: 'left',
dataHintOffset: 'medium' dataHintOffset: 'medium'*/
dataHintDirection: 'bottom',
dataHintOffset: 'small'
}); });
this.lockedControls.push(this.btnPreview); this.lockedControls.push(this.btnPreview);
@ -352,8 +354,8 @@ define([
defaultUnit: '', defaultUnit: '',
lock: [_set.slideDeleted, _set.noSlides, _set.noGraphic, _set.noAnimation], lock: [_set.slideDeleted, _set.noSlides, _set.noGraphic, _set.noAnimation],
dataHint: '1', dataHint: '1',
dataHintDirection: 'bottom', dataHintDirection: 'top',
dataHintOffset: 'big' dataHintOffset: 'small'
}); });
this.lockedControls.push(this.numRepeat); this.lockedControls.push(this.numRepeat);
@ -481,8 +483,10 @@ define([
setMenuParameters: function (effectId, effectGroup, option) setMenuParameters: function (effectId, effectGroup, option)
{ {
var arrEffectOptions;
var effect = _.findWhere(this.allEffects, {group: effectGroup, value: effectId}); var effect = _.findWhere(this.allEffects, {group: effectGroup, value: effectId});
var arrEffectOptions = Common.define.effectData.getEffectOptionsData(effect.group, effect.value); if(effect)
arrEffectOptions = Common.define.effectData.getEffectOptionsData(effect.group, effect.value);
if(!arrEffectOptions) { if(!arrEffectOptions) {
this.btnParameters.menu.removeAll(); this.btnParameters.menu.removeAll();
this._effectId = effectId this._effectId = effectId

View file

@ -73,9 +73,15 @@ define([
if ((this.options.activeEffect != undefined) && (this.options.activeEffect != AscFormat.ANIM_PRESET_NONE) && (this.options.activeEffect !== AscFormat.ANIM_PRESET_MULTIPLE)){ if ((this.options.activeEffect != undefined) && (this.options.activeEffect != AscFormat.ANIM_PRESET_NONE) && (this.options.activeEffect !== AscFormat.ANIM_PRESET_MULTIPLE)){
this._state.activeEffect = this.options.activeEffect; this._state.activeEffect = this.options.activeEffect;
this._state.activeGroupValue = this.options.groupValue; this._state.activeGroupValue = this.options.groupValue;
this._state.activeGroup = _.findWhere(this.EffectGroupData, {value: this._state.activeGroupValue}).id; var group = _.findWhere(this.EffectGroupData, {value: this._state.activeGroupValue})
var itemEffect = _.findWhere(this.allEffects,{group: this._state.activeGroup, value: this._state.activeEffect}); this._state.activeGroup = group.id;
this.activeLevel = itemEffect.level; var itemEffect = _.findWhere(this.allEffects, {
group: this._state.activeGroup,
value: this._state.activeEffect
});
if(itemEffect)
this.activeLevel = itemEffect.level;
} }
Common.UI.Window.prototype.initialize.call(this, this.options); Common.UI.Window.prototype.initialize.call(this, this.options);
}, },
@ -154,7 +160,9 @@ define([
fillEffect: function () { fillEffect: function () {
var arr = _.where(this.allEffects, {group: this._state.activeGroup, level: this.activeLevel }); var arr = _.where(this.allEffects, {group: this._state.activeGroup, level: this.activeLevel });
this.lstEffectList.store.reset(arr); this.lstEffectList.store.reset(arr);
var item = (this._state.activeEffect != undefined)?this.lstEffectList.store.findWhere({value: this._state.activeEffect}):this.lstEffectList.store.at(0); var item = this.lstEffectList.store.findWhere({value: this._state.activeEffect});
if(!item)
item = this.lstEffectList.store.at(0);
this.lstEffectList.selectRecord(item); this.lstEffectList.selectRecord(item);
this._state.activeEffect = item.get('value'); this._state.activeEffect = item.get('value');
}, },