Create tab Transitions in applyLayout

This commit is contained in:
OVSharova 2021-07-27 20:51:37 +03:00
parent 9cd64f4d33
commit 3e9f3b0b3a
3 changed files with 10 additions and 10 deletions

View file

@ -2386,12 +2386,10 @@ define([
this.toolbar.createDelayedElements();
this.attachUIEvents(this.toolbar);
},
setTrantitTab:function (){
var tab = {action: 'transit', caption: this.toolbar.textTabTransitions};
var $panel = this.getApplication().getController('Transitions').createToolbarPanel();
setTrantitTab:function (el){
var $panel = this.getApplication().getController('Transitions').createToolbarPanel();
if ( $panel ) {
this.toolbar.addTab(tab, $panel, 3);
this.toolbar.setVisible('transit', true);
el.find('#transitions-panel').replaceWith($panel);
}
},
onAppShowed: function (config) {

View file

@ -142,7 +142,7 @@
<span class="btn-slot text x-huge" id="slot-btn-insvideo"></span>
</div>
</section>
<!-- <section id="transitions-panel" class="panel" data-tab="transit"> </section>-->
<section id="transitions-panel" class="panel" data-tab="transit"> </section>
</section>
</section>
</div>

View file

@ -129,7 +129,8 @@ define([
tabs: [
{caption: me.textTabFile, action: 'file', extcls: 'canedit', haspanel:false},
{caption: me.textTabHome, action: 'home', extcls: 'canedit'},
{caption: me.textTabInsert, action: 'ins', extcls: 'canedit'}
{caption: me.textTabInsert, action: 'ins', extcls: 'canedit'},
{caption: me.textTabTransitions, action: 'transit', extcls: 'canedit'}
]
}
);
@ -1002,11 +1003,12 @@ define([
Common.UI.Mixtbar.prototype.onResize.apply(me, arguments);
}
});
//_.bind(function (element){
//},me);
if ( mode.isEdit ) {
me.setTab('home');
me.processPanelVisible();
this.fireEvent('transit:settab',[this]);
}
if ( me.isCompactView )
@ -1036,7 +1038,7 @@ define([
var _injectComponent = function (id, cmp) {
Common.Utils.injectComponent($host.find(id), cmp);
};
this.fireEvent('transit:settab',[$host]);
_injectComponent('#slot-field-fontname', this.cmbFontName);
_injectComponent('#slot-field-fontsize', this.cmbFontSize);
_injectComponent('#slot-btn-changeslide', this.btnChangeSlide);