Package com.vaadin.event.Action

Examples of com.vaadin.event.Action.Handler


                                "../runo/icons/16/user.png")
                                : FontAwesome.ANDROID);
                    }
                }));

        Handler actionHandler = new Handler() {
            Action[] actions = { new Action("Do it!", icon) };

            @Override
            public void handleAction(Action action, Object sender, Object target) {
View Full Code Here


public class ButtonEnterWithWindowShortcut extends TestBase {
    Log log = new Log(5);

    @Override
    protected void setup() {
        getMainWindow().addActionHandler(new Handler() {
            private static final long serialVersionUID = -4976129418325394913L;

            @Override
            public void handleAction(Action action, Object sender, Object target) {
                log.log(action.getCaption() + " pressed in window");
View Full Code Here

    private List<Handler> actionHandlers = new ArrayList<Handler>();

    public void add() {
        getMainWindow().setCaption(
                getMainWindow().getCaption() + " - Added handler");
        Handler actionHandler = new Handler() {

            @Override
            public Action[] getActions(Object target, Object sender) {
                return new Action[] { new ShortcutAction("Ctrl+Left",
                        ShortcutAction.KeyCode.ARROW_LEFT,
View Full Code Here

        addHandler(actionHandler);
    }

    public void addAnother() {
        Handler actionHandler = new Handler() {

            @Override
            public Action[] getActions(Object target, Object sender) {
                return new Action[] { new ShortcutAction("Ctrl+Right",
                        ShortcutAction.KeyCode.ARROW_RIGHT,
View Full Code Here

        Label help = new Label(
                "Use CTRL X to fire action, CTRL C to remove it (fails before fix)");

        w.addComponent(help);

        w.addActionHandler(new Handler() {

            final ShortcutAction a1 = new ShortcutAction("action", KeyCode.X,
                    new int[] { ModifierKey.CTRL });
            final ShortcutAction a2 = new ShortcutAction("action", KeyCode.C,
                    new int[] { ModifierKey.CTRL });
View Full Code Here

            public void blur(BlurEvent event) {
                Notification.show("Blurred window");
            }
        });

        window.addActionHandler(new Handler() {

            private Action[] s = new Action[] { new ShortcutAction("^Save") };

            @Override
            public Action[] getActions(Object target, Object sender) {
View Full Code Here

            }
        };

        tree1.setDropHandler(dropHandler);

        Handler actionHandler = new Handler() {

            private Action[] actions = new Action[] { new Action("Remove") };

            @Override
            public void handleAction(Action action, Object sender, Object target) {
View Full Code Here

    private List<Handler> actionHandlers = new ArrayList<Handler>();

    public void add() {
        panel.setCaption(panel.getCaption() + " - Added handler");
        Handler actionHandler = new Handler() {

            @Override
            public Action[] getActions(Object target, Object sender) {
                return new Action[] { new ShortcutAction("Ctrl+Left",
                        ShortcutAction.KeyCode.ARROW_LEFT,
View Full Code Here

        addHandler(actionHandler);
    }

    public void addAnother() {
        Handler actionHandler = new Handler() {

            @Override
            public Action[] getActions(Object target, Object sender) {
                return new Action[] { new ShortcutAction("Ctrl+Right",
                        ShortcutAction.KeyCode.ARROW_RIGHT,
View Full Code Here

        calendar.setLastVisibleHourOfDay(22);
        calendar.setTimeFormat(TimeFormat.Format24H);
        calendar.setHandler((EventResizeHandler) null);

        setEnabled(true);
        calendar.addActionHandler(new Handler() {
            @Override
            public void handleAction(Action action, Object sender, Object target) {
                Label label1 = new Label(calendar.toString());
                label1.setId("calendarlabel");
                addComponent(label1);
View Full Code Here

TOP

Related Classes of com.vaadin.event.Action.Handler

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.