Ticket #7073: 7073.patch
File 7073.patch, 1.2 KB (added by , 13 years ago) |
---|
-
_source/plugins/image/dialogs/image.js
196 196 197 197 var dialog = this.getDialog(), 198 198 value = '', 199 dimension = (( this.id == 'txtWidth' )? 'width' : 'height' ),199 dimension = this.id == 'txtWidth' ? 'width' : 'height', 200 200 size = element.getAttribute( dimension ); 201 201 202 202 if ( size ) … … 636 636 validate : function() 637 637 { 638 638 var aMatch = this.getValue().match( regexGetSizeOrEmpty ); 639 if ( !aMatch )639 if ( !aMatch || aMatch[1] == 0 ) 640 640 alert( editor.lang.common.invalidWidth ); 641 641 return !!aMatch; 642 642 }, … … 685 685 validate : function() 686 686 { 687 687 var aMatch = this.getValue().match( regexGetSizeOrEmpty ); 688 if ( !aMatch )688 if ( !aMatch || aMatch[1] == 0 ) 689 689 alert( editor.lang.common.invalidHeight ); 690 690 return !!aMatch; 691 691 },