Package com.smartgwt.client.widgets.form.fields

Examples of com.smartgwt.client.widgets.form.fields.TextItem


        String helpStr = MSG.view_alert_definition_condition_editor_drift_tooltip();
        StaticTextItem helpItem = buildHelpTextItem("driftHelp", helpStr, ifFunc);
        formItems.add(helpItem);

        TextItem driftDefNameRegex = new TextItem(DRIFT_DEFNAME_REGEX_ITEMNAME,
            MSG.view_alert_definition_condition_editor_drift_configname_regex());
        driftDefNameRegex.setRequired(false);
        driftDefNameRegex.setTooltip(MSG.view_alert_definition_condition_editor_drift_configname_regex_tooltip());
        driftDefNameRegex.setHoverWidth(200);
        driftDefNameRegex.setWrapTitle(false);
        driftDefNameRegex.setShowIfCondition(ifFunc);

        TextItem driftPathNameRegex = new TextItem(DRIFT_PATHNAME_REGEX_ITEMNAME,
            MSG.view_alert_definition_condition_editor_drift_pathname_regex());
        driftPathNameRegex.setRequired(false);
        driftPathNameRegex.setTooltip(MSG.view_alert_definition_condition_editor_drift_pathname_regex_tooltip());
        driftPathNameRegex.setHoverWidth(200);
        driftPathNameRegex.setWrapTitle(false);
        driftPathNameRegex.setShowIfCondition(ifFunc);
        if (editMode) {
            driftDefNameRegex.setDefaultValue(existingCondition.getName());
            driftPathNameRegex.setDefaultValue(existingCondition.getOption());
        }

        formItems.add(driftDefNameRegex);
        formItems.add(driftPathNameRegex);
        return formItems;
View Full Code Here


        exceptionItem.setWidth(200);
        exceptionItem.setMinValue(0);
        exceptionItem.setMaxValue(10);
        exceptionItem.setDefaultValue(0);

        final TextItem conciseMessageItem = new TextItem("conciseMessage", "Concise Message");
        conciseMessageItem.setWidth(200);
        conciseMessageItem.setValue("A concise message string.");

        final TextItem detailsMessageItem = new TextItem("detailsMessage", "Details or Root Cause Message");
        detailsMessageItem.setWidth(200);
        detailsMessageItem.setValue("The details or the inner-most exception message.");

        ButtonItem button = new ButtonItem("showMessage", "Show Message");
        button.addClickHandler(new ClickHandler() {
            public void onClick(ClickEvent event) {
                EnumSet<Option> options = EnumSet.noneOf(Option.class);
                String[] optionsArray = optionMenu.getValues();
                if (optionsArray != null && optionsArray.length > 0) {
                    for (String optString : optionsArray) {
                        options.add(Option.valueOf(optString));
                    }
                }

                Severity severity = Severity.valueOf(severityMenu.getValueAsString());
                String conciseMessage = conciseMessageItem.getValueAsString();
                String detailsMessage = detailsMessageItem.getValueAsString();
                Message msg;
                Number exceptionDepth = (Number) exceptionItem.getValue();
                if (exceptionDepth != null && exceptionDepth.intValue() > 0) {
                    Throwable t = null;
                    for (int depth = exceptionDepth.intValue(); depth > 0; depth--) {
View Full Code Here

        SelectItem categoryFilter = new EnumSelectItem(DriftDataSource.FILTER_CATEGORIES, MSG.common_title_category(),
            DriftCategory.class, categories, categoryIcons);

        // drift file path filter
        TextItem pathFilter = new TextItem(DriftDataSource.FILTER_PATH, MSG.common_title_path());
        pathFilter.setEndRow(true);

        if (isShowFilterForm()) {
            setFilterFormItems(categoryFilter, pathFilter);
        }
    }
View Full Code Here

    protected DynamicForm getAvailableFilterForm() {
        DynamicForm availableFilterForm = new DynamicForm();
        availableFilterForm.setWidth100();
        availableFilterForm.setNumCols(4);

        final TextItem search = new TextItem("search", MSG.common_title_search());

        SelectItem groupCategorySelect = new SelectItem("groupCategory", MSG.widget_resourceSelector_groupCategory());
        groupCategorySelect.setValueMap(CATEGORY_VALUE_MAP);
        if (null == categoryFilter) {
            groupCategorySelect.setAllowEmptyValue(true);
View Full Code Here

    protected DynamicForm getAvailableFilterForm() {
        if (null == availableFilterForm) {
            availableFilterForm = new DynamicForm();
            availableFilterForm.setNumCols(6);
            availableFilterForm.setWidth("75%");
            final TextItem search = new TextItem("search", MSG.common_title_search());
            final SelectItem categorySelect;

            typeSelectItem = new IPickTreeItem("type", MSG.common_title_type());
            typeSelectItem.setDataSource(new ResourceTypePluginTreeDataSource(false));
            typeSelectItem.setValueField("itemId");
View Full Code Here

    }

    protected DynamicForm getAvailableFilterForm() {
        DynamicForm availableFilterForm = new DynamicForm();
        availableFilterForm.setNumCols(4);
        final TextItem search = new TextItem("search", MSG.common_title_search());

        availableFilterForm.setItems(search);

        return availableFilterForm;
    }
View Full Code Here

    }

    private DynamicForm createAnotherUserForm() {
        DynamicForm form = new DynamicForm();
        form.setTitleOrientation(TitleOrientation.TOP);
        anotherUserName = new TextItem("userName", MSG.common_title_username());
        anotherUserPassword = new PasswordItem("password", MSG.common_title_password());
        anotherUserPassword.setAttribute("autocomplete", "off");
        verifyUserButton = new ButtonItem("verify",
            MSG.view_alert_definition_notification_cliScript_editor_verifyAuthentication());
View Full Code Here

    @Override
    protected List<FormItem> createFormItems(EnhancedDynamicForm form) {
        List<FormItem> items = new ArrayList<FormItem>();

        TextItem nameItem = new TextItem(BundleGroupsDataSource.FIELD_NAME);
        nameItem.setShowTitle(true);
        nameItem.setSelectOnFocus(true);
        nameItem.setTabIndex(1);
        nameItem.setAttribute(EnhancedDynamicForm.OUTPUT_AS_HTML_ATTRIBUTE, true);
        items.add(nameItem);

        TextItem descriptionItem = new TextItem(BundleGroupsDataSource.FIELD_DESCRIPTION);
        descriptionItem.setShowTitle(true);
        descriptionItem.setTabIndex(5);
        descriptionItem.setColSpan(form.getNumCols());
        descriptionItem.setAttribute(EnhancedDynamicForm.OUTPUT_AS_HTML_ATTRIBUTE, true);
        items.add(descriptionItem);

        return items;
    }
View Full Code Here

     * item such as a checkbox, radio buttons, etc.
     * 
     * @return the form item used to edit the value
     */
    protected FormItem instantiateEditFormItem() {
        TextItem item = new TextItem();
        return item;
    }
View Full Code Here

        super.onInit();
    }

    @Override
    protected void configureTableFilters() {
        final TextItem sourceFilter = new TextItem("source", MSG.view_inventory_eventHistory_sourceFilter());
        final TextItem detailsFilter = new TextItem("detail", MSG.view_inventory_eventHistory_detailsFilter());

        LinkedHashMap<String, String> severities = new LinkedHashMap<String, String>(5);
        severities.put(EventSeverity.DEBUG.name(), MSG.common_severity_debug());
        severities.put(EventSeverity.INFO.name(), MSG.common_severity_info());
        severities.put(EventSeverity.WARN.name(), MSG.common_severity_warn());
View Full Code Here

TOP

Related Classes of com.smartgwt.client.widgets.form.fields.TextItem

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.