[ Index ]
 

Code source de vtiger CRM 5.0.2

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/include/fckeditor/editor/_source/classes/ -> fckevents.js (source)

   1  /*
   2   * FCKeditor - The text editor for internet
   3   * Copyright (C) 2003-2005 Frederico Caldeira Knabben
   4   * 
   5   * Licensed under the terms of the GNU Lesser General Public License:
   6   *         http://www.opensource.org/licenses/lgpl-license.php
   7   * 
   8   * For further information visit:
   9   *         http://www.fckeditor.net/
  10   * 
  11   * "Support Open Source software. What about a donation today?"
  12   * 
  13   * File Name: fckevents.js
  14   *     FCKEvents Class: used to handle events is a advanced way.
  15   * 
  16   * File Authors:
  17   *         Frederico Caldeira Knabben (fredck@fckeditor.net)
  18   */
  19  
  20  var FCKEvents ;
  21  
  22  if ( !( FCKEvents = NS.FCKEvents ) )
  23  {
  24      FCKEvents = NS.FCKEvents = function( eventsOwner )
  25      {
  26          this.Owner = eventsOwner ;
  27          this.RegisteredEvents = new Object() ;
  28      }
  29  
  30      FCKEvents.prototype.AttachEvent = function( eventName, functionPointer )
  31      {
  32          if ( ! this.RegisteredEvents[ eventName ] ) this.RegisteredEvents[ eventName ] = new Array() ;
  33  
  34          this.RegisteredEvents[ eventName ][ this.RegisteredEvents[ eventName ].length ] = functionPointer ;
  35      }
  36  
  37      FCKEvents.prototype.FireEvent = function( eventName, params )
  38      {
  39          var bReturnValue = true ;
  40  
  41          var oCalls = this.RegisteredEvents[ eventName ] ;
  42          if ( oCalls )
  43          {
  44              for ( var i = 0 ; i < oCalls.length ; i++ )
  45                  bReturnValue = ( oCalls[ i ]( this.Owner, params ) && bReturnValue ) ;
  46          }
  47  
  48          return bReturnValue ;
  49      }
  50  }


Généré le : Sun Feb 25 10:22:19 2007 par Balluche grâce à PHPXref 0.7