blob: 7530425c62ffddb1885f7d5c39bf6ceed3f3e913 [file] [log] [blame]
/*******************************************************************************
* Copyright (c) 2012 EclipseSource and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* EclipseSource - initial API and implementation
******************************************************************************/
org.eclipse.rwt.protocol.AdapterRegistry.add( "rwt.clientscripting.EventBinding", {
factory : function( properties ) {
var source = org.eclipse.rwt.protocol.ObjectManager.getObject( properties.targetObject );
var eventType = org.eclipse.rap.clientscripting.SWT[ properties.eventType ];
var targetFunction = org.eclipse.rwt.protocol.ObjectManager.getObject( properties.listener );
return new org.eclipse.rap.clientscripting.EventBinding( source, eventType, targetFunction );
}
} );