\r
onLoad : function()\r
{\r
- var dialog = this,\r
- isUpdating;\r
+ var dialog = this;\r
\r
var styles = dialog.getContentElement( 'advanced', 'advStyles' );\r
\r
{\r
styles.on( 'change', function( evt )\r
{\r
- if ( isUpdating )\r
- return;\r
-\r
- // Flag to avoid recursion.\r
- isUpdating = 1;\r
-\r
// Synchronize width value.\r
var width = this.getStyle( 'width', '' ),\r
txtWidth = dialog.getContentElement( 'info', 'txtWidth' ),\r
width = parseInt( width, 10 );\r
}\r
\r
- txtWidth && txtWidth.setValue( width );\r
- cmbWidthType && cmbWidthType.setValue( isPx ? 'pixels' : 'percents' );\r
+ txtWidth && txtWidth.setValue( width, true );\r
+ cmbWidthType && cmbWidthType.setValue( isPx ? 'pixels' : 'percents', true );\r
\r
// Synchronize height value.\r
var height = this.getStyle( 'height', '' ),\r
txtHeight = dialog.getContentElement( 'info', 'txtHeight' );\r
\r
height && ( height = parseInt( height, 10 ) );\r
- txtHeight && txtHeight.setValue( height );\r
-\r
- isUpdating = 0;\r
+ txtHeight && txtHeight.setValue( height, true );\r
});\r
}\r
},\r
this._.selectedElement = selectedTable;\r
}\r
\r
- // Enable, disable and select the row, cols, width fields.\r
+ // Enable or disable the row, cols, width fields.\r
if ( selectedTable )\r
{\r
this.setupContent( selectedTable );\r
rowsInput && rowsInput.disable();\r
colsInput && colsInput.disable();\r
- widthInput && widthInput.select();\r
}\r
else\r
{\r
rowsInput && rowsInput.enable();\r
colsInput && colsInput.enable();\r
- rowsInput && rowsInput.select();\r
}\r
\r
// Call the onChange method for the widht and height fields so\r