Package org.apache.isis.viewer.dnd.view.control

Examples of org.apache.isis.viewer.dnd.view.control.Button


    }

    private ToolbarView createToolbar(final CalendarGrid calendar) {
        final ToolbarView toolbarView = new ToolbarView(getContent(), null);

        toolbarView.addView(new Button(new AbstractButtonAction("+Row") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.addRow();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("-Row") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.removeRow();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Across") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.acrossFirst();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Down") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.downFirst();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Next") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.nextPeriod();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Previous") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.previousePeriod();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Day") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showSingleDay();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Days") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showDays();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Weeks") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showWeeks();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Months") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showMonths();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Years") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showYears();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Today") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.today();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Date") {
            @Override
            public void execute(final Workspace workspace, View view, final Location at) {
                final Content content = new NullContent() {
                };
                view = DatePickerControl.getPicker(content);
View Full Code Here


        super(view);

        buttons = new View[actions.length];
        for (int i = 0; i < actions.length; i++) {
            final ButtonAction action = actions[i];
            buttons[i] = new Button(action, view);
            if (action.isDefault()) {
                defaultAction = action;
            }
        }
        // space for: line & button with whitespace
View Full Code Here

    }

    private ToolbarView createToolbar(final CalendarGrid calendar) {
        final ToolbarView toolbarView = new ToolbarView(getContent(), null);

        toolbarView.addView(new Button(new AbstractButtonAction("+Row") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.addRow();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("-Row") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.removeRow();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Across") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.acrossFirst();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Down") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.downFirst();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Next") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.nextPeriod();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Previous") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.previousePeriod();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Day") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showSingleDay();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Days") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showDays();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Weeks") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showWeeks();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Months") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showMonths();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Years") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showYears();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Today") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.today();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Date") {
            @Override
            public void execute(final Workspace workspace, View view, final Location at) {
                final Content content = new NullContent() {
                };
                view = DatePickerControl.getPicker(content);
View Full Code Here

        super(view);

        buttons = new View[actions.length];
        for (int i = 0; i < actions.length; i++) {
            final ButtonAction action = actions[i];
            buttons[i] = new Button(action, view);
            if (action.isDefault()) {
                defaultAction = action;
            }
        }
        // space for: line & button with whitespace
View Full Code Here

    }

    private ToolbarView createToolbar(final CalendarGrid calendar) {
        final ToolbarView toolbarView = new ToolbarView(getContent(), null);

        toolbarView.addView(new Button(new AbstractButtonAction("+Row") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.addRow();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("-Row") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.removeRow();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Across") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.acrossFirst();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Down") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.downFirst();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Next") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.nextPeriod();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Previous") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.previousePeriod();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Day") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showSingleDay();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Days") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showDays();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Weeks") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showWeeks();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Months") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showMonths();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Years") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.showYears();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Today") {
            @Override
            public void execute(final Workspace workspace, final View view, final Location at) {
                calendar.today();
            }
        }, this));

        toolbarView.addView(new Button(new AbstractButtonAction("Date") {
            @Override
            public void execute(final Workspace workspace, View view, final Location at) {
                final Content content = new NullContent() {
                };
                view = DatePickerControl.getPicker(content);
View Full Code Here

TOP

Related Classes of org.apache.isis.viewer.dnd.view.control.Button

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.