#4210: CKEditor plugin for jQuery
----------------------------+-----------------------------------------------
 Reporter:  tobiasz.cudnik  |       Owner:  tobiasz.cudnik
     Type:  Bug             |      Status:  assigned      
 Priority:  Normal          |   Milestone:  CKEditor 3.1  
Component:  General         |     Version:                
 Keywords:  Confirmed       |  
----------------------------+-----------------------------------------------

Comment(by tobiasz.cudnik):

 Replying to [comment:12 garry.yao]:
 >  1. Could we overload 'jQuery.fn.ckeditor' instead of a new
 'jQuery.fn.ckeditorGet' in following form?
 >   * Instance creation when instance doesn't exist with the specified
 config and invoke the callback if any.
 >   * Return instance when it's already existed
 This can't be done because of following:
  * jQuery chaining prevents returning anything other then jQuery object
 (if we want to preserve chain)
  * This could create troubles for end developers which will expect
 synchronous behavior (returning instance at once) when it wont be possible
 (editor wasn't ready then)
  * End developer most of the time would have to write both synchronous and
 asynchronous version of code dealing with CKEditor. This is one possible
 situation:
 {{{
 function myCode()
 {
   this.setUiColor( '#FFFFFF' );
 }
 var editor = $( 'textarea' ).ckeditor( myCode );
 if ( editor )
   myCode.call( editor );
 }}}
  Which is quite terrible and raises questions like "does myCode was
 executed as callback or not ?".

 That's why synchronous and asynchronous calls have been separated into 2
 explicit methods.

 Replying to [comment:12 garry.yao]:
 > 3. It seems 'jquerySyncTextareaOnSubmit' is unnecessary since the editor
 has already listened to 'submit' event for textarea so it's integrate
 'jQuery.fn.trigger' naturally
 Native submit listener which is used by config.autoUpdateElement is
 probably triggered too late to support AJAX forms, thats why this is done
 using native jQuery event system. Although merging those settings is
 possible and reasonable.

-- 
Ticket URL: <http://dev.fckeditor.net/ticket/4210#comment:13>
FCKeditor <http://www.fckeditor.net/>
The text editor for Internet
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
FCKeditor-Trac mailing list
FCKeditor-Trac@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/fckeditor-trac

Reply via email to