All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.ioc.commons.impl.gwt.client.globalflowcontroller.GwtGlobalEventBusImpl Maven / Gradle / Ivy

There is a newer version: 1.2.1
Show newest version
package org.ioc.commons.impl.gwt.client.globalflowcontroller;

import org.ioc.commons.flowcontrol.common.BindRegistration;
import org.ioc.commons.flowcontrol.eventbus.EventHandler;
import org.ioc.commons.flowcontrol.eventbus.IsEvent;
import org.ioc.commons.flowcontrol.globalflowcontroller.GlobalFlowController.GlobalEventBus;
import org.ioc.commons.impl.gwt.client.flowcontrol.eventbus.GwtEventBusImpl;
import org.ioc.commons.ui.IsWidget;

import com.google.web.bindery.event.shared.EventBus;

/**
 * GWT implementation for {@link GlobalEventBus}
 * 
 * @author Jesús Lunar Pérez
 * 
 * @param 
 *            Event type
 */
class GwtGlobalEventBusImpl> extends GwtEventBusImpl implements GlobalEventBus {

	public GwtGlobalEventBusImpl(EventBus eventBus, Object owner) {
		super(eventBus, owner);
	}

	@Override
	public BindRegistration bindEvent(IsWidget whileDisplayIsActive, E event, EventHandler handler) {
		BindRegistration registration = this.bindEvent(event, handler);

		GwtGlobalFlowController.unbindWhenDetach(registration, whileDisplayIsActive);

		return registration;
	}

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy