io.box.text_html={initialize:function(_1){
if(_1.io.type.state.editor){
var _2=io.type.getContentsChild(_1);
if(_1.io.access>1){
_1.io.type.events.keyup.push(dojo.connect(_2,"keyup",null,io.box.text_html.onKeyUp));
}else{
_1.io.type.events.keyup=[];
}
}
return true;
},disconnect:function(_3){
if(_3.io&&_3.io.initialized){
while(_3.io.type.events.keyup.length>0){
dojo.disconnect(_3.io.type.events.keyup.pop());
}
}
return true;
},onKeyUp:function(_4){
_4=io.fixEvent(_4);
if(io.box.selected){
if(io.box.selected==_4.io.box){
if(!_4.io.box.io.type.state.edited){
_4.io.box.io.type.state.edited=true;
}
}
}
},edit:function(_5){
io.box.text_html.disconnect(_5);
io.box.text_html.initialize(_5);
var _6=io.type.getContentsChild(_5);
if(_6){
if(_6.typeName="TEXTAREA"){
_6.focus();
_5.io.type.state.editor=true;
}
}
},save:function(_7){
_7=io.getBox(_7);
if(_7){
var _8=io.getContents(_7);
if(_8){
var _9=io.type.getContentsChild(_7);
if(_9.tagName=="TEXTAREA"){
_7.io.type.data.contents=_9.value;
}
}
}
},list:{touchStart:function(_a){
ioEvent=io.fixEvent(_a);
return true;
},touchEnd:function(_b){
ioEvent=io.fixEvent(_b);
return true;
}},settings:{touchEnd:function(_c){
_c=io.fixEvent(_c);
var _d=_c.io.target;
while(!dojo.hasClass(_d,"control")){
_d=_d.parentNode;
}
if(io.controls.controlScroll.moved){
return false;
}
var _e=io.box.selected;
if(_d.id=="control_property_info"){
io.dialog.open(io.box.info);
}else{
if(_d.id=="control_property_background"){
io.dialog.open(io.box.backgroundColor);
}else{
if(_d.id=="control_property_borderColor"){
io.dialog.open(io.box.borderColor);
}else{
if(_d.id=="control_property_borderWidth"){
var _f=io.box.selected.io.frame.data._borderWidth;
if(_c.io.target.id=="borderWidthUp"){
var _10=_f+1;
}else{
if(_c.io.target.id=="borderWidthDown"){
_10=_f-1;
if(_10<0){
_10=0;
}
}else{
_10=_f;
}
}
if(_10!=_f){
io.box.selected.io.frame.data._borderWidth=_10;
io.box.selected.style.borderWidth=_10+"px";
io.frame.save(io.box.selected);
}
}else{
if(_d.id=="control_property_borderRadius"){
var _11=io.box.selected.io.frame.data._borderRadius;
if(_c.io.target.id=="borderRadiusUp"){
var _12=_11+1;
}else{
if(_c.io.target.id=="borderRadiusDown"){
_12=_11-1;
if(_12<0){
_12=0;
}
}else{
_12=_11;
}
}
if(_12!=_11){
io.box.selected.io.frame.data._borderRadius=_12;
io.box.selected.style.borderRadius=_12+"px";
io.frame.save(io.box.selected);
}
}else{
if(_d.id=="control_property_binding"){
var _13=io.box.selected.io.frame.data.binding;
var _14=_13;
if(_c.io.target.id=="bindingPosition"){
_14^=1;
}else{
if(_c.io.target.id=="bindingSize"){
_14^=2;
}else{
if(_c.io.target.id=="bindingContent"){
_14^=4;
}else{
if(_c.io.target.id=="bindingAccess"){
_14^=8;
}
}
}
}
if(_14!=_13){
io.box.selected.io.frame.data.binding=_14;
io.frame.save(io.box.selected);
}
}else{
if(_d.id=="control_property_locking"){
var _15=io.box.selected.io.frame.data.locking;
var _16=_15;
if(_c.io.target.id=="lockingPosition"){
_16^=1;
}else{
if(_c.io.target.id=="lockingSize"){
_16^=2;
}else{
if(_c.io.target.id=="lockingContent"){
_16^=4;
}else{
if(_c.io.target.id=="lockingAccess"){
_16^=8;
}
}
}
}
if(_16!=_15){
io.box.selected.io.frame.data.locking=_16;
io.frame.save(io.box.selected);
}
}else{
if(_d.id=="control_property_layerIndex"){
var _17=io.box.selected.io.frame.data.position;
if(_c.io.target.id=="layerMoveUp"){
var _18=_17+1;
}else{
if(_c.io.target.id=="layerMoveDown"){
_18=_17-1;
}else{
_18=_17;
}
}
io.frame.updateLayers(io.box.selected,_17,_18);
}
}
}
}
}
}
}
}
return true;
},touchStart:function(_19){
ioEvent=io.fixEvent(_19);
return true;
}},undo:{touchStart:function(_1a){
ioEvent=io.fixEvent(_1a);
return true;
},touchEnd:function(_1b){
ioEvent=io.fixEvent(_1b);
return true;
}},access:{touchStart:function(_1c){
ioEvent=io.fixEvent(_1c);
return true;
},touchEnd:function(_1d){
ioEvent=io.fixEvent(_1d);
return true;
}}};
io.onTypeLoad("text_html",io.box.text_html);


