[DE] Fix preview toc
This commit is contained in:
parent
1799fb270c
commit
e0ceb8a841
|
@ -312,7 +312,7 @@ define([
|
|||
},
|
||||
|
||||
onTableContentsOpen: function(menu) {
|
||||
this.api.asc_getButtonsTOC(menu.items[0].id, menu.items[1].id);
|
||||
this.api.asc_getButtonsTOC(menu.items[0].options.previewId, menu.items[1].options.previewId);
|
||||
},
|
||||
|
||||
onNotesClick: function(type) {
|
||||
|
|
|
@ -235,15 +235,15 @@ define([
|
|||
(new Promise(function (accept, reject) {
|
||||
accept();
|
||||
})).then(function(){
|
||||
var contentsTemplate = _.template('<a id="<%= id %>" tabindex="-1" type="menuitem" class="item-contents"><div></div></a>');
|
||||
var contentsTemplate = _.template('<a id="<%= id %>" tabindex="-1" type="menuitem" class="item-contents"><div id="<%= options.previewId %>"></div></a>');
|
||||
me.btnsContents.forEach( function(btn) {
|
||||
btn.updateHint( me.tipContents );
|
||||
|
||||
var _menu = new Common.UI.Menu({
|
||||
cls: 'toc-menu shifted-left',
|
||||
items: [
|
||||
{template: contentsTemplate, offsety: 0, value: 0, id: 'id-toolbar-toc-0'},
|
||||
{template: contentsTemplate, offsety: 72, value: 1, id: 'id-toolbar-toc-1'},
|
||||
{template: contentsTemplate, offsety: 0, value: 0, previewId: 'id-toolbar-toc-0'},
|
||||
{template: contentsTemplate, offsety: 72, value: 1, previewId: 'id-toolbar-toc-1'},
|
||||
{caption: me.textContentsSettings, value: 'settings'},
|
||||
{caption: me.textContentsRemove, value: 'remove'}
|
||||
]
|
||||
|
@ -255,8 +255,8 @@ define([
|
|||
me.contentsMenu = new Common.UI.Menu({
|
||||
cls: 'toc-menu shifted-left',
|
||||
items: [
|
||||
{template: contentsTemplate, offsety: 0, value: 0, id: 'id-toolbar-toc-menu-0'},
|
||||
{template: contentsTemplate, offsety: 72, value: 1, id: 'id-toolbar-toc-menu-1'},
|
||||
{template: contentsTemplate, offsety: 0, value: 0, previewId: 'id-toolbar-toc-menu-0'},
|
||||
{template: contentsTemplate, offsety: 72, value: 1, previewId: 'id-toolbar-toc-menu-1'},
|
||||
{caption: me.textContentsSettings, value: 'settings'},
|
||||
{caption: me.textContentsRemove, value: 'remove'}
|
||||
]
|
||||
|
|
Loading…
Reference in a new issue