Package Framework

Examples of Framework.ListElement$qq_Resolver


     * isInherited=FALSE
     */
    public DropList getqq_thingsArray_size() {
        if (qq_thingsArray_size == null) {
            ListElement[] elements = new ListElement[3];
            elements[0] = new ListElement( 1, "Small", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
            elements[1] = new ListElement( 2, "Medium", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
            elements[2] = new ListElement( 3, "Large", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );

            qq_thingsArray_size = DropFillinFactory.newDropList(elements);
            qq_thingsArray_size.setName("size");
            // OPTIONAL UIutils.reloadLabelText(qq_thingsArray_size, mcat);
            qq_thingsArray_size.setMaximumRowCount(4);
View Full Code Here


    public RadioList getqq_thingsArray_Colour() {
        if (qq_thingsArray_Colour == null) {
            String[] names = {"Yellow", "Blue", "Green", "Red"};
            qq_thingsArray_Colour = ListFieldFactory.newRadioList(Constants.FO_HORIZONTAL, "", names, 1, Constants.LP_CONSTANT);
            Array_Of_ListElement<ListElement> elements = new Array_Of_ListElement<ListElement>();
            elements.add( new ListElement( 1, names[0], ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE ) );
            elements.add( new ListElement( 2, names[1], ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE ) );
            elements.add( new ListElement( 3, names[2], ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE ) );
            elements.add( new ListElement( 4, names[3], ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE ) );
            qq_thingsArray_Colour.setName("Colour");
            qq_thingsArray_Colour.setModel(new RadioListModel(new SelectionInList(elements), qq_thingsArray_Colour) );
            if (qq_thingsArray_Colour.getSelectedIndex() == -1)
                qq_thingsArray_Colour.setSelectedIndex(0);
            // OPTIONAL UIutils.reloadLabelText(qq_thingsArray_Colour, mcat);
View Full Code Here

      Array_Of_ListElement<ListElement> elements = new Array_Of_ListElement<ListElement>();
        for (int i = 0; i < model.getSize(); i++ ) {

            // Check to stop Swing Designer from crashing. CraigM: 02/08/2007
            if (model.getElementAt(i) instanceof String) {
                elements.add(new ListElement((String)model.getElementAt(i)));
            }
            else {
                elements.add((ListElement)model.getElementAt(i));
            }
        }
View Full Code Here

            model = new ListModel() {
                public void addListDataListener(ListDataListener l) {}

                public Object getElementAt(int index) {
                    return new ListElement( index, namesForVisualEditor[index], ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
                }

                public int getSize() {
                    if (RadioList.this.namesForVisualEditor == null || RadioList.this.namesForVisualEditor.length == 0)
                        return 1;
View Full Code Here

    public Array_Of_ListElement<ListElement> getElementList() {
        return kids;
    }

    public ListElement extractListElementByIndex(int index) {
        ListElement le = null;
        if ((kids != null) && (index > 0) && (index <= kids.size())) {
            le = kids.get(index - 1);
        }
        return le;
    }
View Full Code Here

        return le;
    }

    public ListElement extractListElement(int value) {
        for (Iterator<ListElement> it = kids.iterator(); it.hasNext();) {
            ListElement le = it.next();
            if (le.getIntegerValue() == value)
                return le;
        }
        return null;
    }
View Full Code Here

   
    public void setElementList(Array_Of_ListElement<ListElement> les) {
        // TF:8/8/07:Made a shallow clone in case there is a really big object attached to the list element
        Array_Of_ListElement<ListElement> clonedList = CloneHelper.clone(les, false);
        Object currentValue = this.list.getValue();
        ListElement valueToReselect = null;
        if (currentValue instanceof ListElement && clonedList != null && this.list.getSelectionHolder() instanceof TypeAwareValueModel) {
          TypeAwareValueModel tavm = (TypeAwareValueModel)this.list.getSelectionHolder();
          // We need to find an item in the new list which is the same as an item in the old list,
          // depending on the type being considered. For example, if the list is mapped to an int,
          // we need to find an element in the new list with the same IntegerValue.
          Class<?> clazz = tavm.getValueType();
          ListElement currentSelection = (ListElement)currentValue;
          for (ListElement item : clonedList) {
            if (clazz.equals(Integer.TYPE) ||
                clazz.equals(Short.TYPE) ||
                NumericData.class.isAssignableFrom(clazz) ||
                Number.class.isAssignableFrom(clazz)) {
              if (item.getIntegerValue() == currentSelection.getIntegerValue()) {
                valueToReselect = item;
                break;
              }
            }
            else if (String.class.isAssignableFrom(clazz) || TextData.class.isAssignableFrom(clazz) && currentSelection.getTextValue() != null) {
              if (currentSelection.getTextValue().equals(item.getTextValue())) {
                valueToReselect = item;
                break;
              }
            }
            else {
              if (currentSelection.getObjectValue() != null && currentSelection.getObjectValue() == item.getObjectValue()) {
                valueToReselect = item;
                break;
              }
            }
          }
View Full Code Here

    public RadioList getqq_aList1Array_aRadioList() {
        if (qq_aList1Array_aRadioList == null) {
            String[] names = {"One", "Two"};
            qq_aList1Array_aRadioList = ListFieldFactory.newRadioList(Constants.FO_HORIZONTAL, "", names, 1, Constants.LP_PACKED);
            Array_Of_ListElement<ListElement> elements = new Array_Of_ListElement<ListElement>();
            elements.add( new ListElement( 1, names[0], ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE ) );
            elements.add( new ListElement( 2, names[1], ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE ) );
            qq_aList1Array_aRadioList.setName("aRadioList");
            qq_aList1Array_aRadioList.setModel(new RadioListModel(new SelectionInList(elements), qq_aList1Array_aRadioList) );
            if (qq_aList1Array_aRadioList.getSelectedIndex() == -1)
                qq_aList1Array_aRadioList.setSelectedIndex(0);
            // OPTIONAL UIutils.reloadLabelText(qq_aList1Array_aRadioList, mcat);
View Full Code Here

     * isInherited=FALSE
     */
    public DropList getqq_aList1Array_aDropList() {
        if (qq_aList1Array_aDropList == null) {
            ListElement[] elements = new ListElement[4];
            elements[0] = new ListElement( 1, "One", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
            elements[1] = new ListElement( 2, "Two", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
            elements[2] = new ListElement( 3, "Three", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
            elements[3] = new ListElement( 4, "Four", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );

            qq_aList1Array_aDropList = DropFillinFactory.newDropList(elements);
            qq_aList1Array_aDropList.setName("aDropList");
            // OPTIONAL UIutils.reloadLabelText(qq_aList1Array_aDropList, mcat);
            qq_aList1Array_aDropList.setMaximumRowCount(4);
View Full Code Here

     * isInherited=FALSE
     */
    public FillInField getqq_aList1Array_aFillinField() {
        if (qq_aList1Array_aFillinField == null) {
            ListElement[] elements = new ListElement[4];
            elements[0] = new ListElement( 1, "One", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
            elements[1] = new ListElement( 2, "Two", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
            elements[2] = new ListElement( 3, "Three", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
            elements[3] = new ListElement( 4, "Four", ListElement.qq_Resolver.cINTEGERVALUE_TEXTVALUE );
            qq_aList1Array_aFillinField = DropFillinFactory.newFillinField(elements);
            qq_aList1Array_aFillinField.setName("aFillinField");
            // OPTIONAL UIutils.reloadLabelText(qq_aList1Array_aFillinField, mcat);
            qq_aList1Array_aFillinField.setMaximumRowCount(4);
            qq_aList1Array_aFillinField.setVisibleColumns(8);
View Full Code Here

TOP

Related Classes of Framework.ListElement$qq_Resolver

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.