From: Alan Date: Tue, 15 Mar 2022 07:19:54 +0000 (+0800) Subject: Roo/htmleditor/BlockFigure.js X-Git-Url: http://git.roojs.org/?p=roojs1;a=commitdiff_plain;h=9cfecbb3c4f103303af48c3b2dc6523a2583cf89 Roo/htmleditor/BlockFigure.js --- diff --git a/Roo/htmleditor/BlockFigure.js b/Roo/htmleditor/BlockFigure.js index 73b336ca00..a26f4887e9 100644 --- a/Roo/htmleditor/BlockFigure.js +++ b/Roo/htmleditor/BlockFigure.js @@ -234,7 +234,11 @@ Roo.extend(Roo.htmleditor.BlockFigure, Roo.htmleditor.Block, { pressed : false, enableToggle : true, setValue : function(v) { - this.toggle(v == 'block' ? false : true); + // this trigger toggle. + + var b = block(); + this.setText(b.caption_display == 'block' ? "Hide Caption" : "Show Caption"); + this.setPressed(b.caption_display == 'block' ? false: true); }, listeners : { toggle: function (btn, state)