Changeset 5822
- Timestamp:
- 08/13/10 19:41:53 (3 years ago)
- Location:
- CKEditor/branches/versions/3.4.x
- Files:
-
- 5 edited
-
CHANGES.html (modified) (2 diffs)
-
_source/plugins/dialog/plugin.js (modified) (3 diffs)
-
_source/plugins/dialogadvtab/plugin.js (modified) (3 diffs)
-
_source/plugins/dialogui/plugin.js (modified) (5 diffs)
-
_source/plugins/table/dialogs/table.js (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
CKEditor/branches/versions/3.4.x/CHANGES.html
r5821 r5822 1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 2 2 <!-- 3 3 Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved. … … 45 45 <li><a href="http://dev.fckeditor.net/ticket/6135">#6135</a> : The dialogadvtab plugin now uses the correct label.</li> 46 46 <li><a href="http://dev.fckeditor.net/ticket/6125">#6125</a> : Focus was lost after applying commands in Opera.</li> 47 <li><a href="http://dev.fckeditor.net/ticket/6137">#6137</a> : The table dialog was missing the default width value on second opening.</li> 47 48 </ul> 48 49 <h3> -
CKEditor/branches/versions/3.4.x/_source/plugins/dialog/plugin.js
r5758 r5822 763 763 { 764 764 for ( var j in this._.contents[i] ) 765 fn( this._.contents[i][j] );765 fn( this._.contents[i][j] ); 766 766 } 767 767 return this; … … 776 776 reset : (function() 777 777 { 778 var fn = function( widget ){ if ( widget.reset ) widget.reset( ); };778 var fn = function( widget ){ if ( widget.reset ) widget.reset( 1 ); }; 779 779 return function(){ this.foreach( fn ); return this; }; 780 780 })(), … … 2355 2355 * Sets the value of this dialog UI object. 2356 2356 * @param {Object} value The new value. 2357 * @param {Boolean} noChangeEvent Internal commit, to supress 'change' event on this element. 2357 2358 * @returns {CKEDITOR.dialog.uiElement} The current UI element. 2358 2359 * @example 2359 2360 * uiElement.setValue( 'Dingo' ); 2360 2361 */ 2361 setValue : function( value )2362 setValue : function( value, noChangeEvent ) 2362 2363 { 2363 2364 this.getInputElement().setValue( value ); 2364 this.fire( 'change', { value : value } );2365 !noChangeEvent && this.fire( 'change', { value : value } ); 2365 2366 return this; 2366 2367 }, -
CKEditor/branches/versions/3.4.x/_source/plugins/dialogadvtab/plugin.js
r5819 r5822 43 43 } 44 44 } 45 46 var isUpdating;47 45 48 46 CKEDITOR.plugins.add( 'dialogadvtab', … … 145 143 updateStyle : function( name, value ) 146 144 { 147 if ( isUpdating )148 return;149 150 // Flag to avoid recursion.151 isUpdating = 1;152 153 145 var styles = this.getValue(); 154 146 … … 168 160 } 169 161 170 this.setValue( styles ); 171 172 isUpdating = 0; 162 this.setValue( styles, true ); 163 173 164 }, 174 165 -
CKEditor/branches/versions/3.4.x/_source/plugins/dialogui/plugin.js
r5758 r5822 60 60 }, 61 61 62 reset : function( )62 reset : function( noChangeEvent ) 63 63 { 64 this.setValue( this.getInitValue() );64 this.setValue( this.getInitValue(), noChangeEvent ); 65 65 }, 66 66 … … 1062 1062 { 1063 1063 !value && ( value = '' ); 1064 return CKEDITOR.ui.dialog.uiElement.prototype.setValue. call( this, value);1064 return CKEDITOR.ui.dialog.uiElement.prototype.setValue.apply( this, arguments ); 1065 1065 }, 1066 1066 … … 1157 1157 * @example 1158 1158 * @param {Boolean} true to tick the checkbox, false to untick it. 1159 */ 1160 setValue : function( checked ) 1159 * @param {Boolean} noChangeEvent Internal commit, to supress 'change' event on this element. 1160 */ 1161 setValue : function( checked, noChangeEvent ) 1161 1162 { 1162 1163 this.getInputElement().$.checked = checked; 1163 this.fire( 'change', { value : checked } );1164 !noChangeEvent && this.fire( 'change', { value : checked } ); 1164 1165 }, 1165 1166 … … 1223 1224 * @example 1224 1225 * @param {String} value The value of the button to be chcked. 1225 */ 1226 setValue : function( value ) 1226 * @param {Boolean} noChangeEvent Internal commit, to supress 'change' event on this element. 1227 */ 1228 setValue : function( value, noChangeEvent ) 1227 1229 { 1228 1230 var children = this._.children, … … 1230 1232 for ( var i = 0 ; ( i < children.length ) && ( item = children[i] ) ; i++ ) 1231 1233 item.getElement().$.checked = ( item.getValue() == value ); 1232 this.fire( 'change', { value : value } );1234 !noChangeEvent && this.fire( 'change', { value : value } ); 1233 1235 }, 1234 1236 -
CKEditor/branches/versions/3.4.x/_source/plugins/table/dialogs/table.js
r5818 r5822 33 33 onLoad : function() 34 34 { 35 var dialog = this, 36 isUpdating; 35 var dialog = this; 37 36 38 37 var styles = dialog.getContentElement( 'advanced', 'advStyles' ); … … 42 41 styles.on( 'change', function( evt ) 43 42 { 44 if ( isUpdating )45 return;46 47 // Flag to avoid recursion.48 isUpdating = 1;49 50 43 // Synchronize width value. 51 44 var width = this.getStyle( 'width', '' ), … … 60 53 } 61 54 62 txtWidth && txtWidth.setValue( width );63 cmbWidthType && cmbWidthType.setValue( isPx ? 'pixels' : 'percents' );55 txtWidth && txtWidth.setValue( width, true ); 56 cmbWidthType && cmbWidthType.setValue( isPx ? 'pixels' : 'percents', true ); 64 57 65 58 // Synchronize height value. … … 68 61 69 62 height && ( height = parseInt( height, 10 ) ); 70 txtHeight && txtHeight.setValue( height ); 71 72 isUpdating = 0; 63 txtHeight && txtHeight.setValue( height, true ); 73 64 }); 74 65 }
Note: See TracChangeset
for help on using the changeset viewer.
