Examples of RadioGroup


Examples of org.apache.wicket.markup.html.form.RadioGroup

    {
      conditionCheckBox.setVisible(false);
      conditionCheckBox.setRequired(false);
    }

    RadioGroup createNewEquipe = new RadioGroup("createNewEquipe",
        new PropertyModel(composantAutresInfos, "createNewEquipe"))
    {
      private static final long serialVersionUID = 1L;

      @Override
      protected void onSelectionChanged(Object newSelection)
      {
        updateChampsEquipe((Boolean) newSelection, composantAutresInfos);
      }

      @Override
      protected boolean wantOnSelectionChangedNotifications()
      {
        return true;
      }
    };

    createNewEquipe.setVisible(composantAutresInfos.isNeedEquipe());
    createNewEquipe.add(new Radio("newEquipeOui", new Model(true))
        .setVisible(composantAutresInfos.isNeedEquipe()));
    createNewEquipe.add(new Radio("newEquipeNon", new Model(false))
        .setVisible(composantAutresInfos.isNeedEquipe()));
    autresInfosForm.add(createNewEquipe);

    equipeExistante = new DropDownChoice("equipeExistante",
        new PropertyModel(composantAutresInfos, "equipeExistante"),
View Full Code Here

Examples of org.apache.wicket.markup.html.form.RadioGroup

            public void onClick(AjaxRequestTarget target) {
                setSearchType(ALL);
                setResponsePage(TweetSearchPage.class, getParams(query, selectedIndex, null, loggedInUser));
            }
        }));
        final RadioGroup rg = new RadioGroup("searchTypes", new PropertyModel(this, "selectedIndex"));
        final Button buttonRight = new Button("submitbutton") {

            @Override
            public void onSubmit() {
                setResponsePage(TweetSearchPage.class, getParams(query, selectedIndex, userName, loggedInUser));
            }
        };
        final Button bttnLeft = new Button("submitbuttonleft") {

            @Override
            public void onSubmit() {
                buttonRight.onSubmit();
            }
        };
        form = new Form("searchform") {

            @Override
            public void onSubmit() {
                buttonRight.onSubmit();
            }
        };
       
        form.add(new BookmarkablePageLink("homelink", TweetSearchPage.class));
//        buttonRight.add(new EffectBehavior(new BounceEffect()));
        form.add(buttonRight);
        form.add(bttnLeft);
        form.setMarkupId("queryform");
        add(form);

        AutoCompleteSettings config = new AutoCompleteSettings().setUseHideShowCoveredIEFix(false);
        config.setThrottleDelay(200);

        // connect the form's textfield with the java property       
        queryTF = new MyAutoCompleteTextField("textField",
                new PropertyModel(this, "query"), config) {

            @Override
            protected Iterator getChoices(String input) {
                return SearchBox.this.getQueryChoices(input).iterator();
            }

            @Override
            protected void onSelectionChange(AjaxRequestTarget target, String newValue) {
                SearchBox.this.onSelectionChange(target, newValue);
            }
        };
        queryTF.add(new DefaultFocusBehaviour());
        // autosubmit when user selects choice -> problem: the user text will be submitted although it should be cleared before submit
//        queryTF.add(new AjaxFormSubmitBehavior(form, "onchange") {
//
//            @Override
//            protected void onSubmit(AjaxRequestTarget target) {
//            }
//
//            @Override
//            protected void onError(AjaxRequestTarget target) {
//            }
//        });
        queryTF.setMarkupId("querybox");
        form.add(queryTF);

        MyAutoCompleteTextField userTF = new MyAutoCompleteTextField("userTextField",
                new PropertyModel(this, "userName"), config) {

            @Override
            protected Iterator getChoices(String input) {
                return SearchBox.this.getUserChoices(input).iterator();
            }

            @Override
            protected void onSelectionChange(AjaxRequestTarget target, String newValue) {
                //"Not supported yet."
            }
        };
        userTF.setMarkupId("userbox");

        rg.add(new Radio("0", new Model(0)).setMarkupId("sbnone"));
        rg.add(new Radio("1", new Model(1)).setMarkupId("sbfriends"));
        rg.add(new Radio("2", new Model(2)).setMarkupId("sbuser"));
        rg.add(userTF);
        if (showSpacer)
            form.add(new AttributeAppender("class", new Model("not-logged-in-spacer"), " "));

        form.add(rg);
       
View Full Code Here

Examples of org.objectstyle.wolips.wooeditor.widgets.RadioGroup

    createSpacer(form, displayGroupComposite, 1);
    Composite radioGroupComposite = new Composite(displayGroupComposite, SWT.NO_BACKGROUND);
    radioGroupComposite.setLayout(new GridLayout());

    // Sort order radio buttons
    mySortRadioGroup = new RadioGroup();
    for (String s : DisplayGroup.SORT_OPTIONS) {
      Button sortButton = form.createButton(radioGroupComposite, s, SWT.RADIO);
      GridData sortButtonLayoutData = new GridData(SWT.FILL, SWT.FILL, true, false);
      sortButton.setLayoutData(sortButtonLayoutData);
      mySortRadioGroup.add(sortButton);
View Full Code Here

Examples of org.springframework.ide.eclipse.wizard.gettingstarted.boot.RadioGroup

    assertGroupNames(radioGroups, "type", "packaging", "javaVersion", "language", "bootVersion");
  }

  public void testPackagingRadios() throws Exception {
    NewSpringBootWizardModel model = parseFrom("initializr.json");
    RadioGroup packagingTypes = model.getRadioGroups().getGroup("packaging");
    assertNotNull(packagingTypes);
    assertGroupValues(packagingTypes, "jar", "war");
    assertEquals("jar", packagingTypes.getDefault().getValue());
  }
View Full Code Here

Examples of org.zkoss.zul.Radiogroup

            } catch (Exception iae) {
                iae.printStackTrace();
            }
        }

        Radiogroup isEquipment = (Radiogroup) getFellow("isEquipment");
        Textbox equipmentNameTB = (Textbox) getFellow("equipmentName");
        Combobox supplierIdCB = (Combobox) getFellow("supplierId");
        Textbox pccCodeTB = (Textbox) getFellow("pccCode");
        Textbox venderCodeTB = (Textbox) getFellow("venderCode");

        obj.setIsEquipment(isEquipment.getSelectedItem().getValue());
        obj.setEquipmentName(equipmentNameTB.getText());
        obj.setSupplier((Supplier) supplierIdCB.getSelectedItem().getValue());
        obj.setPccCode(pccCodeTB.getText());
        obj.setVenderCode(venderCodeTB.getText());
View Full Code Here

Examples of org.zkoss.zul.Radiogroup

    }

    public void objToView(Object obj) {
        EquipmentForm var = (EquipmentForm) obj;

        Radiogroup isEquipment = (Radiogroup) getFellow("isEquipment");
        Textbox equipmentNameTB = (Textbox) getFellow("equipmentName");
        Combobox supplierIdCB = (Combobox) getFellow("supplierId");
        Textbox pccCodeTB = (Textbox) getFellow("pccCode");
        Textbox venderCodeTB = (Textbox) getFellow("venderCode");

        Iterator it = isEquipment.getItems().iterator();
        while (it.hasNext()) {
            Radio radio = (Radio) it.next();
            if (radio.getValue().equals(var.getIsEquipment())) {
                radio.setChecked(true);
            }
View Full Code Here

Examples of org.zkoss.zul.Radiogroup

    }

    public void objToView(Object obj) {
        MechanicForm form = (MechanicForm) obj;

        Radiogroup hasCitizenshipRG = (Radiogroup) getFellow("hasCitizenship");
        Textbox mechanicNameTB = (Textbox) getFellow("mechanicName");
        Textbox uniIdTB = (Textbox) getFellow("uniId");
        Combobox companyCB = (Combobox) getFellow("company");
        Radiogroup sexRG = (Radiogroup) getFellow("sex");

        Iterator it = hasCitizenshipRG.getItems().iterator();
        while (it.hasNext()) {
            Radio r = (Radio) it.next();
            if (r.getValue().equals(form.getHasCitizenship())) {
                r.setChecked(true);
            }
        }
        mechanicNameTB.setText(form.getMechanicName());
        uniIdTB.setText(form.getUniId());

        boolean mechanicBelongToCompany = false;
        Iterator companyCBItr = companyCB.getItems().iterator();
        while (companyCBItr.hasNext()) {
            Comboitem item = (Comboitem) companyCBItr.next();
            Org varCompany = (Org) item.getValue();
            if (form.getCompanyId() != null
                    && varCompany.getOrgId().equals(form.getCompanyId())) {
                companyCB.setSelectedItem(item);
                form.setCompany(varCompany); // if has company, re-link it now
                mechanicBelongToCompany = true;
            }
          
        }
        if(!mechanicBelongToCompany){
            companyCB.setValue("please");
        }

       
        Iterator sexRGItr = sexRG.getItems().iterator();
        while (sexRGItr.hasNext()) {
            Radio r = (Radio) sexRGItr.next();
            if (r.getValue().equals(form.getSex())) {
                r.setChecked(true);
            }
View Full Code Here

Examples of org.zkoss.zul.Radiogroup

                iae.printStackTrace();
            }
        }


        Radiogroup hasCitizenshipRG = (Radiogroup) getFellow("hasCitizenship");
        Textbox mechanicNameTB = (Textbox) getFellow("mechanicName");
        Textbox uniIdTB = (Textbox) getFellow("uniId");
        Combobox companyCB = (Combobox) getFellow("company");
        Radiogroup sexRG = (Radiogroup) getFellow("sex");

        var.setHasCitizenship(
                hasCitizenshipRG.getSelectedItem().getValue());
        var.setMechanicName(mechanicNameTB.getText());
        var.setUniId(uniIdTB.getText());
        if (companyCB.getSelectedItem() != null) {
            var.setCompany((Org) companyCB.getSelectedItem().getValue());
        }
        var.setSex(sexRG.getSelectedItem().getValue());


        Datebox birthdayDB = (Datebox) getFellow("birthday");
        Textbox homePhoneTB = (Textbox) getFellow("homePhone");
        Textbox mobileTB = (Textbox) getFellow("mobile");
View Full Code Here

Examples of org.zkoss.zul.Radiogroup

    public void objToView(Object obj) {
        Auth var = (Auth) obj;

        Textbox authNameTB = (Textbox) getFellow("authName");
        Textbox authDescTB = (Textbox) getFellow("authDescription");
        Radiogroup editable = (Radiogroup) getFellow("editable");

        authNameTB.setText(var.getAuthName());
        authDescTB.setText(var.getAuthDescription());

        Iterator it = editable.getItems().iterator();
        while (it.hasNext()) {
            Radio radio = (Radio) it.next();
            if (radio.getValue().equals(var.getEditable())) {
                radio.setChecked(true);
            }
View Full Code Here

Examples of org.zkoss.zul.Radiogroup

        Textbox authNameTB = (Textbox) getFellow("authName");
        Textbox authTypeTB = (Textbox) getFellow("authType");
        Textbox unitIDTB = (Textbox) getFellow("unitId");
        Textbox authDescTB = (Textbox) getFellow("authDescription");
        Radiogroup editable = (Radiogroup) getFellow("editable");

        var.setAuthName(authNameTB.getText());
        var.setAuthType(authTypeTB.getText());
        var.setUnitId(unitIDTB.getText());
        var.setAuthDescription(authDescTB.getText());
        var.setEditable(editable.getSelectedItem().getValue());

        return var;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.