/*\r
* pettanR work.js\r
- * version 0.4.26\r
+ * version 0.4.27\r
* \r
* author:\r
* itozyun\r
function edit(){\r
if( currentElement === null || currentElement.type !== PANEL_ELEMENT_TYPE_TEXT) return;\r
pettanr.textEditor.bootInOverlay( PANEL_CONTROL.x(), PANEL_CONTROL.y(), currentElement );\r
- buttonBackOrForward( true);\r
+ buttonBackOrForward( true );\r
}\r
function change(){\r
if( currentElement === null) return;\r
})();\r
\r
var JQ_WRAPPER = jqTextElementOrigin.clone( true ),\r
- TEXT_ELM = JQ_WRAPPER.find( 'td,.speach-inner').eq( 0),\r
+ elmText = JQ_WRAPPER.find( 'td,.speach-inner' ).get( 0 ),\r
type = data.balloon_template_id,\r
text = ( function(){\r
var _speachs = data.speaches_attributes;\r
}\r
function updateText( _text ){\r
text = _text || text || '';\r
- TEXT_ELM.html( text );\r
+ elmText.firstChild.data = text;\r
}\r
function resizeBalloon(){\r
balloon && balloon.resize( a, w, h );\r
delete instance.init;\r
}\r
this.angle = function( _a ){\r
- _a !== undefined && instance.resize( undefined, undefined, undefined, undefined, _a );\r
+ _a !== undefined && instance.resize( x, y, w, h, _a );\r
return a;\r
}\r
- this.text = function( _text){\r
+ this.text = function( _text ){\r
if( _text && text !== _text) {\r
HISTORY_CONTROL.saveState( updateText, text || '', _text );\r
- updateText( _text);\r
+ updateText( _text );\r
}\r
return text;\r
}\r
animate !== true && resizeBalloon();\r
}\r
this.animate = function ( _x, _y, _w, _h, _a ){\r
- instance.resize( _x, _y, _w, _h, _a, true);\r
+ instance.resize( _x, _y, _w, _h, _a, true );\r
}\r
this.destroy = function(){\r
delete instance.destroy;\r
\r
JQ_WRAPPER.stop().remove();\r
balloon.destroy();\r
- JQ_WRAPPER = TEXT_ELM = data = balloon = instance = null;\r
+ JQ_WRAPPER = elmText = data = balloon = instance = null;\r
}\r
}\r
TextElementClass.prototype = new AbstractComicElement( PANEL_ELEMENT_TYPE_TEXT );\r