[PE mobile] Fixed display default table styles.
This commit is contained in:
parent
3ea69c7b7e
commit
6ed79dec7a
|
@ -48,7 +48,8 @@ define([
|
|||
'use strict';
|
||||
|
||||
PE.Controllers.AddTable = Backbone.Controller.extend(_.extend((function() {
|
||||
var _styles = [];
|
||||
var _styles = [],
|
||||
_initDefaultStyles = false;
|
||||
|
||||
return {
|
||||
models: [],
|
||||
|
@ -75,8 +76,11 @@ define([
|
|||
initEvents: function () {
|
||||
var me = this;
|
||||
|
||||
if (_styles.length < 1) {
|
||||
me.api.asc_GetDefaultTableStyles();
|
||||
if (!_initDefaultStyles) {
|
||||
_initDefaultStyles = true;
|
||||
_styles = [];
|
||||
|
||||
me.api.asc_GetDefaultTableStyles && me.api.asc_GetDefaultTableStyles();
|
||||
}
|
||||
|
||||
$('#add-table li').single('click', _.buffered(me.onStyleClick, 100, me));
|
||||
|
|
|
@ -194,7 +194,7 @@ define([
|
|||
$layoutNavbar
|
||||
.find('.center')
|
||||
.removeClass('categories')
|
||||
.html(layoutEditors[0].caption);
|
||||
.html(layoutEditors.length>0 ? layoutEditors[0].caption: '');
|
||||
} else {
|
||||
if (isAndroid) {
|
||||
$layoutNavbar
|
||||
|
|
Loading…
Reference in a new issue