X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=_source%2Fplugins%2Fforms%2Fdialogs%2Fbutton.js;h=fc49f70bd3c2fada5445b1ac223b133d4991bf68;hb=039a051ccf3901311661022a30afd60fc38130c9;hp=dc718d7761f0de9ba3fdeeb9a5d50efd3518b1d0;hpb=ea7e3453c7b0f023b050aca6d9f83ab372860d91;p=ckeditor.git diff --git a/_source/plugins/forms/dialogs/button.js b/_source/plugins/forms/dialogs/button.js index dc718d7..fc49f70 100644 --- a/_source/plugins/forms/dialogs/button.js +++ b/_source/plugins/forms/dialogs/button.js @@ -1,5 +1,5 @@ /* -Copyright (c) 2003-2009, CKSource - Frederico Knabben. All rights reserved. +Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.html or http://ckeditor.com/license */ CKEDITOR.dialog.add( 'button', function( editor ) @@ -12,10 +12,10 @@ CKEDITOR.dialog.add( 'button', function( editor ) { delete this.button; var element = this.getParentEditor().getSelection().getSelectedElement(); - if ( element && element.getName() == "input" ) + if ( element && element.is( 'input' ) ) { var type = element.getAttribute( 'type' ); - if ( type == "button" || type == "reset" || type == "submit" ) + if ( type in { button:1, reset:1, submit:1 } ) { this.button = element; this.setupContent( element );