|
|
|
@ -260,7 +260,7 @@ K.options = {
|
|
|
|
|
items : [ 'emoticons',
|
|
|
|
|
'source','plainpaste', 'wordpaste', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist', '|',
|
|
|
|
|
'formatblock', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold',
|
|
|
|
|
'italic', 'underline', 'removeformat', '|','imagedirectupload','table', 'link'
|
|
|
|
|
'italic', 'underline', 'removeformat', '|','imagedirectupload','table', 'link', 'fullscreen',"more"
|
|
|
|
|
],
|
|
|
|
|
noDisableItems : ['source', 'fullscreen'],
|
|
|
|
|
colorTable : [
|
|
|
|
@ -3909,10 +3909,15 @@ _extend(KToolbar, KWidget, {
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
get : function(name) {
|
|
|
|
|
if (this._itemMap[name]) {
|
|
|
|
|
return this._itemMap[name];
|
|
|
|
|
}
|
|
|
|
|
return (this._itemMap[name] = K('span.ke-icon-' + name, this.div).parent());
|
|
|
|
|
// if (this._itemMap[name]) {
|
|
|
|
|
// return this._itemMap[name];
|
|
|
|
|
// }
|
|
|
|
|
if($("#define").css('display') == 'block'){
|
|
|
|
|
pdiv = $("#define")
|
|
|
|
|
}else if($("#full").css('display') == 'block'){
|
|
|
|
|
pdiv = $("#full")
|
|
|
|
|
}
|
|
|
|
|
return (this._itemMap[name] = K('span.ke-icon-' + name, pdiv).parent());
|
|
|
|
|
},
|
|
|
|
|
select : function(name) {
|
|
|
|
|
_selectToolbar.call(this, name, function(knode) {
|
|
|
|
@ -4915,6 +4920,7 @@ KEditor.prototype = {
|
|
|
|
|
self.srcElement.before(container);
|
|
|
|
|
}
|
|
|
|
|
var toolbarDiv = K('.toolbar', container),
|
|
|
|
|
toolBarDivFull = K('.toolbar', container),
|
|
|
|
|
editDiv = K('.edit', container),
|
|
|
|
|
statusbar = self.statusbar = K('.statusbar', container);
|
|
|
|
|
container.removeClass('container')
|
|
|
|
@ -4959,9 +4965,36 @@ KEditor.prototype = {
|
|
|
|
|
htmlList.push('<span class="ke-toolbar-icon ke-toolbar-icon-url ke-icon-' + name + '" unselectable="on"></span></span>');
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
htmlList.unshift('<div style="display:block" id="define"/>')
|
|
|
|
|
htmlList.push('</div>')
|
|
|
|
|
var htmlListFull = [];
|
|
|
|
|
var fullItems = [
|
|
|
|
|
'emoticons',
|
|
|
|
|
'source','plainpaste', 'wordpaste', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist', '|',
|
|
|
|
|
'formatblock', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold',
|
|
|
|
|
'italic', 'underline', 'removeformat', '|','imagedirectupload','table', 'link', 'fullscreen',"more",
|
|
|
|
|
'/',
|
|
|
|
|
'undo', 'redo', '|', 'preview', 'print', 'template', 'code', 'cut', 'plainpaste',
|
|
|
|
|
'justifyfull', 'insertunorderedlist', 'indent', 'outdent', 'subscript',
|
|
|
|
|
'superscript', 'clearhtml', 'quickformat', 'selectall', 'fontname',
|
|
|
|
|
'strikethrough', 'lineheight', '|', 'imagedirectupload', 'hr', 'pagebreak',
|
|
|
|
|
'anchor', 'unlink'
|
|
|
|
|
]
|
|
|
|
|
K.each(fullItems, function(i, name) {
|
|
|
|
|
if (name == '|') {
|
|
|
|
|
htmlListFull.push('<span class="ke-inline-block ke-separator"></span>');
|
|
|
|
|
} else if (name == '/') {
|
|
|
|
|
htmlListFull.push('<div class="ke-hr"></div>');
|
|
|
|
|
} else {
|
|
|
|
|
htmlListFull.push('<span class="ke-outline" data-name="' + name + '" title="' + self.lang(name) + '" unselectable="on">');
|
|
|
|
|
htmlListFull.push('<span class="ke-toolbar-icon ke-toolbar-icon-url ke-icon-' + name + '" unselectable="on"></span></span>');
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
htmlListFull.unshift('<div style="display:none" id="full"/>')
|
|
|
|
|
htmlListFull.push('</div>')
|
|
|
|
|
var toolbar = self.toolbar = _toolbar({
|
|
|
|
|
src : toolbarDiv,
|
|
|
|
|
html : htmlList.join(''),
|
|
|
|
|
html : htmlList.join('')+htmlListFull.join(''),
|
|
|
|
|
noDisableItems : self.noDisableItems,
|
|
|
|
|
click : function(e, name) {
|
|
|
|
|
e.stop();
|
|
|
|
@ -4975,6 +5008,7 @@ KEditor.prototype = {
|
|
|
|
|
self.clickToolbar(name);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
var editHeight = _removeUnit(height) - toolbar.div.height();
|
|
|
|
|
var edit = self.edit = _edit({
|
|
|
|
|
height : editHeight > 0 && _removeUnit(height) > self.minHeight ? editHeight : self.minHeight,
|
|
|
|
@ -5306,8 +5340,9 @@ KEditor.prototype = {
|
|
|
|
|
createMenu : function(options) {
|
|
|
|
|
var self = this,
|
|
|
|
|
name = options.name,
|
|
|
|
|
knode = self.toolbar.get(name),
|
|
|
|
|
knode = self.toolbar.get(name),
|
|
|
|
|
pos = knode.pos();
|
|
|
|
|
|
|
|
|
|
options.x = pos.x;
|
|
|
|
|
options.y = pos.y + knode.height();
|
|
|
|
|
options.z = self.options.zIndex;
|
|
|
|
@ -5992,4 +6027,5 @@ _plugin('core', function(K) {
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
})(window);
|
|
|
|
|