[richfaces-svn-commits] JBoss Rich Faces SVN: r5879 - in trunk/ui/pickList/src/main: java/org/richfaces/component and 1 other directories.

richfaces-svn-commits at lists.jboss.org richfaces-svn-commits at lists.jboss.org
Wed Feb 6 13:38:40 EST 2008


Author: abelevich
Date: 2008-02-06 13:38:40 -0500 (Wed, 06 Feb 2008)
New Revision: 5879

Modified:
   trunk/ui/pickList/src/main/config/component/picklist.xml
   trunk/ui/pickList/src/main/java/org/richfaces/component/UIPickList.java
   trunk/ui/pickList/src/main/java/org/richfaces/renderkit/PickListRenderer.java
Log:
clean classes

Modified: trunk/ui/pickList/src/main/config/component/picklist.xml
===================================================================
--- trunk/ui/pickList/src/main/config/component/picklist.xml	2008-02-06 16:48:00 UTC (rev 5878)
+++ trunk/ui/pickList/src/main/config/component/picklist.xml	2008-02-06 18:38:40 UTC (rev 5879)
@@ -29,29 +29,12 @@
        	</tag>
        	
        	<properties>
-       		<property>
-       			<name>displayValueOnly</name>
-       			<classname>boolean</classname>
-       			<defaultvalue>false</defaultvalue>
-       		</property>       	
-       		<property>
-       			<name>displayValueOnlyStyle</name>
-       			<classname>java.lang.String</classname>
-       			<defaultvalue>""</defaultvalue>
-       		</property>
-       		<property>
-       			<name>displayValueOnlyStyleClass</name>
-       			<classname>java.lang.String</classname>
-       			<defaultvalue>""</defaultvalue>
-       		</property>
-       		<property>
-       			<name>size</name>
-       			<classname>int</classname>
-       		</property>
+       		     		
        		<property hidden="true">
        			<name>selectedValues</name>
        			<classname>java.lang.Object</classname>
        		</property>
+       		
        		<property>
        			<name>valueChangeListener</name>
        			<classname>javax.el.MethodExpression</classname>
@@ -65,7 +48,7 @@
        		</property>
        		
        		<property>
-       			<name>showButtonLabels</name>
+       			<name>showButtonsLabel</name>
        			<classname>java.lang.String</classname>
        			<defaultvalue>"true"</defaultvalue>
        		</property>
@@ -93,68 +76,67 @@
        			<classname>java.lang.String</classname>
        			<defaultvalue>""</defaultvalue>
        		</property>
-       		
+       		      		
+	       	<property>
+		    	<name>listClass</name>
+		    	<classname>java.lang.String</classname>
+		        <description>CSS class for a list</description>
+		    	<defaultvalue><![CDATA[""]]></defaultvalue>
+		    </property>
+		    
+	       	<property>
+	            <name>switchByClick</name>
+	            <classname>boolean</classname>
+	            <description>If &quot;true&quot;, dragging between lists realized by click </description>
+	            <defaultvalue>false</defaultvalue>
+	        </property>
+	        
+	        <property>
+	            <name>sourceListWidth</name>
+	            <classname>java.lang.String</classname>
+	            <description>
+	                Defines width of a source list
+	            </description>
+	            <defaultvalue>"140px"</defaultvalue>
+	        </property>
+	        
+	        <property>
+	            <name>targetListWidth</name>
+	            <classname>java.lang.String</classname>
+	            <description>
+	                Defines width of a target list
+	            </description>
+	            <defaultvalue>"140px"</defaultvalue>
+	        </property>
+	        
+	        <property>
+	            <name>listsHeight</name>
+	            <classname>java.lang.String</classname>
+	            <description>
+	                Defines height of the list
+	            </description>
+	            <defaultvalue>"140px"</defaultvalue>
+	        </property>     		
+	       		&ui_component_attributes;
+	       		&html_universal_attributes;
+	       		&html_events;
+	       		&html_control_events;
+	       		
        		<property>
-       			<name>value</name>
-       			<classname>java.lang.String</classname>
-       		</property>
-       		       		
-       	<property>
-	    	<name>listClass</name>
-	    	<classname>java.lang.String</classname>
-	        <description>CSS class for a list</description>
-	    	<defaultvalue><![CDATA[""]]></defaultvalue>
-	    </property>
-       	<property>
-            <name>switchByClick</name>
-            <classname>boolean</classname>
-            <description>If &quot;true&quot;, dragging between lists realized by click </description>
-            <defaultvalue>false</defaultvalue>
-        </property>
-        <property>
-            <name>sourceListWidth</name>
-            <classname>java.lang.String</classname>
-            <description>
-                Defines width of a source list
-            </description>
-            <defaultvalue>"140"</defaultvalue>
-        </property>
-        <property>
-            <name>targetListWidth</name>
-            <classname>java.lang.String</classname>
-            <description>
-                Defines width of a target list
-            </description>
-            <defaultvalue>"140"</defaultvalue>
-        </property>
-        <property>
-            <name>listsHeight</name>
-            <classname>java.lang.String</classname>
-            <description>
-                Defines height of the list
-            </description>
-            <defaultvalue>"140"</defaultvalue>
-        </property>     		
-       		&ui_component_attributes;
-       		&html_universal_attributes;
-       		&html_events;
-       		&html_control_events;
-       		
-       		<property>
        			<name>enabledStyleClass</name>
        			<classname>java.lang.String</classname>
        		</property>
-       		
+	       		
        		<property>
        			<name>enabledStyle</name>
        			<classname>java.lang.String</classname>
        		</property>
-       		
+	       		
        		<property>
        			<name>disabledStyleClass</name>
        			<classname>java.lang.String</classname>
        		</property>
-       		
+	       		
        		<property>
        			<name>disabledStyle</name>
        			<classname>java.lang.String</classname>

Modified: trunk/ui/pickList/src/main/java/org/richfaces/component/UIPickList.java
===================================================================
--- trunk/ui/pickList/src/main/java/org/richfaces/component/UIPickList.java	2008-02-06 16:48:00 UTC (rev 5878)
+++ trunk/ui/pickList/src/main/java/org/richfaces/component/UIPickList.java	2008-02-06 18:38:40 UTC (rev 5879)
@@ -12,24 +12,12 @@
 	public abstract String getMoveControlsVerticalAlign();
 	public abstract void setMoveControlsVerticalAlign(String moveControlsVerticalAlign);
 	
-	public abstract boolean isDisplayValueOnly();
-	public abstract void setDisplayValueOnly(boolean displayValueOnly);
-	 
-	public abstract String getDisplayValueOnlyStyle();
-	public abstract void setDisplayValueOnlyStyle(String style);
-		
-	public abstract String getDisplayValueOnlyStyleClass();
-	public abstract void setDisplayValueOnlyStyleClass(String styleClass);
-	 
 	public abstract int getSize();
 	public abstract void setSize(int size);
 	
 	public abstract boolean isDisabled();
 	public abstract void setDisabled(boolean disabled);
 	
-	public abstract boolean isFastOrderControlsVisible();
-	public abstract void setFastOrderControlsVisible(boolean visible);
-	
 	/**
 	 * Get base clietntId of this component ( withowt iteration part )
 	 * 

Modified: trunk/ui/pickList/src/main/java/org/richfaces/renderkit/PickListRenderer.java
===================================================================
--- trunk/ui/pickList/src/main/java/org/richfaces/renderkit/PickListRenderer.java	2008-02-06 16:48:00 UTC (rev 5878)
+++ trunk/ui/pickList/src/main/java/org/richfaces/renderkit/PickListRenderer.java	2008-02-06 18:38:40 UTC (rev 5879)
@@ -40,7 +40,7 @@
 	
 	private static final String HIDDEN_SUFFIX = "valueKeeper";
     protected static final OrderingComponentRendererBase.ControlsHelper[] SHUTTLE_HELPERS = ListShuttleControlsHelper.HELPERS;
-    protected final static String SHOW_LABELS_ATTRIBUTE_NAME = "showButtonLabels";
+    protected final static String SHOW_LABELS_ATTRIBUTE_NAME = "showButtonsLabel";
     private static final String MESSAGE_BUNDLE_NAME = OrderingListRendererBase.class.getPackage().getName() + "ListShuttle";
     private boolean isSelectedList;
     private boolean isAvailableList;
@@ -86,7 +86,7 @@
 	    String hiddenClientId = picklist.getClientId(context) + HIDDEN_SUFFIX;
 	    Map paramValuesMap = context.getExternalContext().getRequestParameterValuesMap();
 
-	    if (isDisabledOrReadOnly(picklist)) {
+	    if (picklist.isDisabled()) {
 	    	return;
 	    }
 
@@ -103,10 +103,6 @@
 	    }
 	}
 	
-	private boolean isDisabledOrReadOnly(UIPickList picklist) {		
-		return picklist.isDisplayValueOnly() || isTrue(picklist.getAttributes().get("disabled"));
-	}
-	
 	private static boolean isTrue(Object obj) {
 		if (!(obj instanceof Boolean)) {
 			return false;
@@ -298,7 +294,7 @@
           	boolean enable;
         	for (int i = 0; i < SHUTTLE_HELPERS.length; i++) {
         		OrderingComponentRendererBase.ControlsHelper helper = SHUTTLE_HELPERS[i];
-        	    if (helper.getName().equals(ListShuttleControlsHelper.NAME_REMOVEALL)) {
+        	    if (helper.getName().equals(ListShuttleControlsHelper.DEFAULT_LABEL_COPY_ALL)) {
         		enable = isSelectedList;
         	    } else if (helper.getName().equals(ListShuttleControlsHelper.NAME_COPYALL)) {
         		enable = isAvailableList;




More information about the richfaces-svn-commits mailing list