Package org.xulfaces.tag.input

Source Code of org.xulfaces.tag.input.SelectOneListBoxTag

/*
*   xulfaces : bring XUL power to Java
*  
*  Copyright (C) 2005  Olivier SCHMITT
*  This library is free software; you can redistribute it and/or
*  modify it under the terms of the GNU Lesser General Public
*  License as published by the Free Software Foundation; either
*  version 2.1 of the License, or (at your option) any later version.
*
*  This library is distributed in the hope that it will be useful,
*  but WITHOUT ANY WARRANTY; without even the implied warranty of
*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
*  Lesser General Public License for more details.
*
*  You should have received a copy of the GNU Lesser General Public
*  License along with this library; if not, write to the Free Software
*  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
*/


package org.xulfaces.tag.input;

import javax.faces.component.UIComponent;
import javax.faces.context.FacesContext;

import org.xulfaces.annotation.taglib.ATTRIBUTE;
import org.xulfaces.annotation.taglib.TAG;
import org.xulfaces.tag.ModelTag;

/**
*
* @author kito31
* @version $Id: SelectOneListBoxTag.java,v 1.4 2007/05/08 14:17:56 kito31 Exp $
*/
@TAG(name="selectOneListbox",description="Defines a XUL listbox element with single selection.")
public class SelectOneListBoxTag extends ModelTag {
 
  @ATTRIBUTE(mappedType="java.lang.Boolean",description = "If this attribute is not used, the user can navigate to specific items in the list by pressing the first the first letter of the item's label.")
  private String disableKeyNavigation; 
 
  @ATTRIBUTE(mappedType="java.lang.Boolean",description = "Indicates whether the description is disabled or not.")
  private String disabled; 
 
  @ATTRIBUTE(description = "Connects the checkbox to a corresponding preference. ")    
  private String preference;

  @ATTRIBUTE(mappedType="java.lang.Integer",description = "The number of rows to display in the list box.")    
  private String rows;

  @ATTRIBUTE(mappedType="java.lang.Boolean",description = "If this attribue is not specified, a select event is fired whenever an item is selected, either by the user or by calling one of the select methods. If set to true, the select event is never fired.")
  private String suppressonselect;
 
  @ATTRIBUTE(mappedType="java.lang.Integer",description = "The tab order of the element. ")
  private String tabindex;
 
     
    public String getComponentType() {
        return "xul.component.SelectOneListBox";
    }

    public String getRendererType() {
        return "xul.renderer.SelectOneOrMany";
    }

  // @StartGeneration

  protected void setProperties(UIComponent component) {
        super.setProperties(component);
        FacesContext facesContext  = getFacesContext();

    setBooleanAttribute(facesContext,component,"disableKeyNavigation",disableKeyNavigation);
    setBooleanAttribute(facesContext,component,"disabled",disabled);
    setStringAttribute(facesContext,component,"preference",preference);
    setIntegerAttribute(facesContext,component,"rows",rows);
    setBooleanAttribute(facesContext,component,"suppressonselect",suppressonselect);
    setIntegerAttribute(facesContext,component,"tabindex",tabindex);

  }
 
                // @EndGeneration
 
 
  public String getDisabled() {
    return disabled;
  }

  public void setDisabled(String disabled) {
    this.disabled = disabled;
  }

  public String getDisableKeyNavigation() {
    return disableKeyNavigation;
  }

  public void setDisableKeyNavigation(String disableKeyNavigation) {
    this.disableKeyNavigation = disableKeyNavigation;
  }

  public String getPreference() {
    return preference;
  }

  public void setPreference(String preference) {
    this.preference = preference;
  }

  public String getRows() {
    return rows;
  }

  public void setRows(String rows) {
    this.rows = rows;
  }

  public String getSuppressonselect() {
    return suppressonselect;
  }

  public void setSuppressonselect(String suppressonselect) {
    this.suppressonselect = suppressonselect;
  }

  public String getTabindex() {
    return tabindex;
  }

  public void setTabindex(String tabindex) {
    this.tabindex = tabindex;
  }
 


 
 
   
}
TOP

Related Classes of org.xulfaces.tag.input.SelectOneListBoxTag

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.