// private
onResize : function(w, h)
{
- //Roo.log('resize: ' +w + ',' + h );
+ Roo.log('resize: ' +w + ',' + h );
//Roo.HtmlEditorCore.superclass.onResize.apply(this, arguments);
if(!this.iframe){
return;
if(this.sourceEditMode){
- this.iframe.className = 'x-hidden hide'; //FIXME - what's the BS styles for these
+ Roo.get(this.iframe).addClass(['x-hidden','hide']); //FIXME - what's the BS styles for these
}else{
-
- this.iframe.className = '';
+ Roo.get(this.iframe).removeClass(['x-hidden','hide']);
+ //this.iframe.className = '';
this.deferFocus();
}
//this.setSize(this.owner.wrap.getSize());
name: false,
target: false,
+
+ pressed : null,
+
+
getAutoCreate : function(){
var cfg = {
}
cfg.html = this.html || cfg.html;
- if (this.toggle===true) {
+ if (this.toggle === true) {
cfg={
tag: 'div',
cls: 'slider-frame roo-button',
if(this.preventDefault){
e.preventDefault();
}
+ if (this.pressed === true || this.pressed === false) {
+ this.pressed = !this.pressed;
+ this[this.pressed ? 'addClass' : 'removeClass']('active');
+ this.fireEvent('toggle', this,e);
+ }
+
this.fireEvent('click', this, e);
}
// actually if flexy:foreach is found, we really want to create
// multiple copies here...
- Roo.log('render');
- Roo.log(this[cntr]());
+ //Roo.log('render');
+ //Roo.log(this[cntr]());
cn.render(this[cntr]());
}
// then add the element..
// private
onResize : function(w, h)
{
- //Roo.log('resize: ' +w + ',' + h );
+ Roo.log('resize: ' +w + ',' + h );
Roo.bootstrap.HtmlEditor.superclass.onResize.apply(this, arguments);
var ew = false;
var eh = false;
ew = aw;
}
if(typeof h == 'number'){
- var tbh = 0;
+ var tbh = -11; // fixme it needs to tool bar size!
for (var i =0; i < this.toolbars.length;i++) {
// fixme - ask toolbars for heights?
- tbh += this.toolbars[i].tb.el.getHeight();
- if (this.toolbars[i].footer) {
- tbh += this.toolbars[i].footer.el.getHeight();
- }
+ tbh += this.toolbars[i].el.getHeight();
+ //if (this.toolbars[i].footer) {
+ // tbh += this.toolbars[i].footer.el.getHeight();
+ //}
}
+