Package org.zkoss.zul

Examples of org.zkoss.zul.Button


            isShowingReportedHours = !isShowingReportedHours;
        }
    }

    public void showMoneyCostBar() {
        Button showMoneyCostBarButton = (Button) getFellow("showMoneyCostBar");
        if (disabilityConfiguration.isMoneyCostBarEnabled()) {
            if (isShowingMoneyCostBar) {
                context.hideMoneyCostBar();
                diagramGraph
                        .removePostGraphChangeListener(showMoneyCostBarOnChange);
                showMoneyCostBarButton.setSclass("planner-command");
                showMoneyCostBarButton.setTooltiptext(_("Show money cost bar"));
            } else {
                context.showMoneyCostBar();
                diagramGraph
                        .addPostGraphChangeListener(showMoneyCostBarOnChange);
                showMoneyCostBarButton.setSclass("planner-command clicked");
                showMoneyCostBarButton.setTooltiptext(_("Hide money cost bar"));
            }
            isShowingMoneyCostBar = !isShowingMoneyCostBar;
        }
    }
View Full Code Here


                }
            }

            private void appendButtonPlan(final Treecell cell,
                    final LoadTimeLine taskLine) {
                Button buttonPlan = new Button();
                buttonPlan.setSclass("icono");
                buttonPlan.setImage("/common/img/ico_planificador1.png");
                buttonPlan.setHoverImage("/common/img/ico_planificador.png");
                buttonPlan.setTooltiptext(_("See scheduling"));
                buttonPlan.addEventListener("onClick", new EventListener() {
                    @Override
                    public void onEvent(Event event) {
                        schedule(taskLine);
                    }
                });
View Full Code Here

            isShowingMoneyCostBar = !isShowingMoneyCostBar;
        }
    }

    public void showAllLabels() {
        Button showAllLabelsButton = (Button) getFellow("showAllLabels");
        if (isShowingLabels) {
            Clients.evalJavaScript("ganttz.TaskList.getInstance().hideAllTaskLabels()");
            showAllLabelsButton.setSclass("planner-command show-labels");
        } else {
            Clients.evalJavaScript("ganttz.TaskList.getInstance().showAllTaskLabels()");
            showAllLabelsButton
                    .setSclass("planner-command show-labels clicked");
        }
        isShowingLabels = !isShowingLabels;
    }
View Full Code Here

        }
        isShowingLabels = !isShowingLabels;
    }

    public void showAllResources() {
        Button showAllLabelsButton = (Button) getFellow("showAllResources");
        if (isShowingResources) {
            Clients.evalJavaScript("ganttz.TaskList.getInstance().hideResourceTooltips()");
            showAllLabelsButton.setSclass("planner-command show-resources");
        } else {
            Clients.evalJavaScript("ganttz.TaskList.getInstance().showResourceTooltips()");
            showAllLabelsButton
            .setSclass("planner-command show-resources clicked");
        }
        isShowingResources = !isShowingResources;
    }
View Full Code Here

    public boolean showMoneyCostBarRightNow() {
        return (areShownMoneyCostBarByDefault() || isShowingMoneyCostBar);
    }

    public void expandAll() {
        Button expandAllButton = (Button) getFellow("expandAll");
        if (disabilityConfiguration.isExpandAllEnabled()) {
            if (isExpandAll) {
                context.collapseAll();
                expandAllButton.setSclass("planner-command");
            } else {
                context.expandAll();
                expandAllButton.setSclass("planner-command clicked");
            }
        }
        isExpandAll = !isExpandAll;
    }
View Full Code Here

        }
        isExpandAll = !isExpandAll;
    }

    public void expandAllAlways() {
        Button expandAllButton = (Button) getFellow("expandAll");
        if (disabilityConfiguration.isExpandAllEnabled()) {
                context.expandAll();
                expandAllButton.setSclass("planner-command clicked");
        }
    }
View Full Code Here

            Clients.evalJavaScript("ganttz.TaskList.getInstance().showResourceTooltips();");
        }
    }

    public void flattenTree() {
        Button flattenTreeButton = (Button) getFellow("flattenTree");
        if (disabilityConfiguration.isFlattenTreeEnabled()) {
            if (isFlattenTree) {
                predicate.setFilterContainers(false);
                flattenTreeButton.setSclass("planner-command");
            } else {
                predicate.setFilterContainers(true);
                flattenTreeButton.setSclass("planner-command clicked");
            }
            setTaskListPredicate(predicate);
        }
        isFlattenTree = !isFlattenTree;
        Clients.evalJavaScript("ganttz.Planner.getInstance().adjustScrollableDimensions()");
View Full Code Here

            toolbar.removeChild(b);
        }
    }

    private Button asButton(final IToolbarCommand c) {
        Button result = new Button();
        result.addEventListener(Events.ON_CLICK, new EventListener() {
            @Override
            public void onEvent(Event event) {
                c.doAction();
            }
        });
        if (!StringUtils.isEmpty(c.getImage())) {
            result.setImage(c.getImage());
            result.setTooltiptext(c.getLabel());
        } else {
            result.setLabel(c.getLabel());
        }
        return result;
    }
View Full Code Here

        }

        final Window printProperties = (Window) Executions.createComponents(
                "/planner/print_configuration.zul", planner, null);

        Button printButton = (Button) printProperties.getFellow("printButton");
        printButton.addEventListener(Events.ON_CLICK, new EventListener() {
            @Override
            public void onEvent(Event event) {
                printProperties.detach();
                configuration.print(buildParameters(printProperties),planner);
            }
        });
        printButton.setParent(printProperties);

        try {
            printProperties.doModal();
        } catch (Exception e) {
            e.printStackTrace();
View Full Code Here

                    public void onEvent(Event event) {
                        goToEditForm(advanceType);
                    }
                }));

                Button removeButton = Util
                        .createRemoveButton(new EventListener() {

                    @Override
                            public void onEvent(Event event) throws InstanceNotFoundException {
                        confirmDelete(advanceType);
                    }
                });
                removeButton.setDisabled(advanceTypeModel
                        .isImmutableOrAlreadyInUse(advanceType));
                hbox.appendChild(removeButton);

                row.appendChild(hbox);
            }
View Full Code Here

TOP

Related Classes of org.zkoss.zul.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.