Package org.zkoss.zul.api

Examples of org.zkoss.zul.api.Combobox


    }

    public void showAdvances() {
        Button showAdvancesButton = (Button) getFellow("showAdvances");
        if (disabilityConfiguration.isAdvancesEnabled()) {
            Combobox progressTypesCombo = (Combobox) getFellow("cbProgressTypes");
            if (isShowingAdvances) {
                context.hideAdvances();
                diagramGraph.removePostGraphChangeListener(showAdvanceOnChange);
                showAdvancesButton.setSclass("planner-command");
                showAdvancesButton.setTooltiptext(_("Show progress"));
                if (progressTypesCombo.getItemCount() > 0) {
                    progressTypesCombo.setSelectedIndex(0);
                }
            } else {
                context.showAdvances();
                diagramGraph.addPostGraphChangeListener(showAdvanceOnChange);
                showAdvancesButton.setSclass("planner-command clicked");
View Full Code Here


        leftPane.addSeeScheduledOfListener(seeScheduledOfListener);
        resourceLoadList.addSeeScheduledOfListener(seeScheduledOfListener);
    }

    private void setupNameFilter() {
        Combobox filterByNameCombo = (Combobox) getFellow("filterByNameCombo");
        filterByNameCombo.getChildren().clear();
        int size = groups.size();

        if(size > numberOfGroupsByName) {
            int position = 0;
            while(position < size) {
                String firstName = groups.get(position).getConceptName();
                String lastName;
                int newPosition = position + numberOfGroupsByName;
                if(newPosition - 1 < size) {
                    lastName = groups.get(newPosition - 1)
                    .getConceptName();
                }
                else {
                    lastName = groups.get(size - 1)
                    .getConceptName();
                }

                Comboitem item = new Comboitem();
                item.setLabel(firstName.substring(0, 1) + " - " + lastName.substring(0, 1));
                item.setDescription(firstName + " - " + lastName);
                item.setValue(position);
                filterByNameCombo.appendChild(item);
                position = newPosition;
            }
        }

        Comboitem lastItem = new Comboitem();
        lastItem.setLabel(_("All"));
        lastItem.setDescription(_("Show all elements"));
        lastItem.setValue(new Integer(-1));
        filterByNameCombo.appendChild(lastItem);

        filterByNameCombo.setSelectedIndex(0);
        refreshNameFilter = false;
    }
View Full Code Here

            }
        });
    }

    public void setInternalPaginationDisabled(boolean disabled) {
        Combobox combo = ((Combobox) getFellow("filterByNameCombo"));
        if (combo != null && combo.isDisabled() != disabled) {
            filterByNamePosition = disabled? -1 :
                ((Integer)combo.getSelectedItemApi().getValue()).intValue();
            combo.setDisabled(disabled);
        }
    }
View Full Code Here

TOP

Related Classes of org.zkoss.zul.api.Combobox

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.