/*
* Copyright 2011 Vaadin Ltd.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
package com.vaadin.event;
import java.io.Serializable;
import java.lang.reflect.Method;
import com.vaadin.event.MouseEvents.ClickEvent;
import com.vaadin.terminal.gwt.client.MouseEventDetails;
import com.vaadin.tools.ReflectTools;
import com.vaadin.ui.Component;
public interface LayoutEvents {
public interface LayoutClickListener extends ComponentEventListener {
public static final Method clickMethod = ReflectTools.findMethod(
LayoutClickListener.class, "layoutClick",
LayoutClickEvent.class);
/**
* Layout has been clicked
*
* @param event
* Component click event.
*/
public void layoutClick(LayoutClickEvent event);
}
/**
* The interface for adding and removing LayoutClickEvent
* listeners. By implementing this interface a class explicitly announces
* that it will generate a LayoutClickEvent when a component
* inside it is clicked and a LayoutClickListener is
* registered.
*
* Note: The general Java convention is not to explicitly declare that a
* class generates events, but to directly define the
* addListener and removeListener methods. That
* way the caller of these methods has no real way of finding out if the
* class really will send the events, or if it just defines the methods to
* be able to implement an interface.
*