Java 类com.google.gwt.user.client.ui.FormPanel.SubmitEvent 实例源码

项目:blogwt    文件:SearchPart.java   
@UiHandler("frmSearch")
void onSearchSubmit (SubmitEvent event) {
    if (isValid()) {
        PageTypeHelper.show(PageType.SearchPostsPageType,
                txtQuery.getValue());
        txtQuery.setValue("");
    } else {
        showErrors();
    }

    event.cancel();
}
项目:qafe-platform    文件:SearchBoxViewGwtImpl.java   
public SearchBoxViewGwtImpl() {

        FormPanel formPanel = new FormPanel("");
        formPanel.addSubmitHandler(new SubmitHandler() {

            @Override
            public void onSubmit(SubmitEvent event) {
                event.cancel();

            }
        });
        MSearchBox searchBox = new MSearchBox();
        formPanel.setWidget(searchBox);
        scrollPanel.setWidget(formPanel);
    }
项目:dtgov    文件:AddDeploymentFormSubmitHandler.java   
/**
 * @see com.google.gwt.user.client.ui.FormPanel.SubmitHandler#onSubmit(com.google.gwt.user.client.ui.FormPanel.SubmitEvent)
 */
@Override
public void onSubmit(SubmitEvent event) {
    dialog.hide(false);
    notification = notificationService.startProgressNotification(
            i18n.format("add-deployment-submit.adding-deployment"), //$NON-NLS-1$
            i18n.format("add-deployment-submit.adding-deployment-msg")); //$NON-NLS-1$
}
项目:blogwt    文件:FormPart.java   
@UiHandler("frmForm")
void onFormSubmit (SubmitEvent se) {
    if (isValid()) {
        loading();

        Form form = new Form();
        form.name = name;

        // add fields to form
        final int count = pnlFields.getWidgetCount();
        Widget current;
        Field field;

        for (int i = 0; i < count; i++) {
            current = pnlFields.getWidget(i);
            field = null;

            if (current instanceof FormField) {
                field = new Field().name(((FormField) current).name())
                        .value(((FormField) current).value());
                if (form.fields == null) {
                    form.fields = new ArrayList<Field>();
                }

                form.fields.add(field);

                if (current instanceof TextBoxPart) {
                    field.type(FieldTypeType.FieldTypeTypeText);
                } else if (current instanceof TextAreaPart) {
                    field.type(FieldTypeType.FieldTypeTypeLongText);
                } else if (current instanceof ListBoxPart) {
                    field.type(FieldTypeType.FieldTypeTypeSingleOption);
                } else if (current instanceof ReCaptchaPart) {
                    field.type(FieldTypeType.FieldTypeTypeCaptcha);
                }
            }
        }

        FormController.get().submitForm(form);
    }

    se.cancel();
}
项目:socom    文件:InfluenceAnswerFreeAudioView.java   
@UiHandler("answerForm")
public void onFileFormSubmitComplete(SubmitEvent event)
{
    this.fireEvent(new FormSubmitEvent(this));
}
项目:socom    文件:InfluenceAnswerFreeImageView.java   
@UiHandler("answerForm")
public void onFileFormSubmitComplete(SubmitEvent event) {
    this.fireEvent(new FormSubmitEvent(this));
}