[richfaces-svn-commits] JBoss Rich Faces SVN: r5103 - in trunk/sandbox/ui/combobox/src/main: java/org/richfaces/renderkit/images and 2 other directories.

richfaces-svn-commits at lists.jboss.org richfaces-svn-commits at lists.jboss.org
Sat Dec 29 09:11:08 EST 2007


Author: abelevich
Date: 2007-12-29 09:11:08 -0500 (Sat, 29 Dec 2007)
New Revision: 5103

Added:
   trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxBtnGradient.java
   trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxInputGradient.java
Removed:
   trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxGradient.java
Modified:
   trunk/sandbox/ui/combobox/src/main/config/resources/resource-config.xml
   trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxImage.java
   trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/css/combobox.xcss
   trunk/sandbox/ui/combobox/src/main/templates/combobox.jspx
Log:
new mockup

Modified: trunk/sandbox/ui/combobox/src/main/config/resources/resource-config.xml
===================================================================
--- trunk/sandbox/ui/combobox/src/main/config/resources/resource-config.xml	2007-12-29 13:42:29 UTC (rev 5102)
+++ trunk/sandbox/ui/combobox/src/main/config/resources/resource-config.xml	2007-12-29 14:11:08 UTC (rev 5103)
@@ -1,6 +1,12 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <resource-config>
-	<resource class="org.richfaces.renderkit.images.ComboBoxGradient">
-		<name>org.richfaces.renderkit.images.ComboBoxGradient</name>
+	<resource class="org.richfaces.renderkit.images.ComboBoxBtnGradient">
+		<name>org.richfaces.renderkit.images.ComboBoxBtnGradient</name>
 	</resource>
+	<resource class="org.richfaces.renderkit.images.ComboBoxInputGradient">
+		<name>org.richfaces.renderkit.images.ComboBoxInputGradient</name>
+	</resource>
+	<resource class="org.richfaces.renderkit.images.ComboBoxImage">
+		<name>org.richfaces.renderkit.images.ComboBoxImage</name>
+	</resource>
 </resource-config>

Added: trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxBtnGradient.java
===================================================================
--- trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxBtnGradient.java	                        (rev 0)
+++ trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxBtnGradient.java	2007-12-29 14:11:08 UTC (rev 5103)
@@ -0,0 +1,16 @@
+/**
+ * 
+ */
+package org.richfaces.renderkit.images;
+
+import org.richfaces.renderkit.html.BaseGradient;
+
+/**
+ * @author Anton Belevich
+ *
+ */
+public class ComboBoxBtnGradient extends BaseGradient {
+	public ComboBoxBtnGradient() {
+		super(30,50 , 20,"generalBackgroundColor", "tabBackgroundColor");
+	}
+}

Deleted: trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxGradient.java
===================================================================
--- trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxGradient.java	2007-12-29 13:42:29 UTC (rev 5102)
+++ trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxGradient.java	2007-12-29 14:11:08 UTC (rev 5103)
@@ -1,16 +0,0 @@
-/**
- * 
- */
-package org.richfaces.renderkit.images;
-
-import org.richfaces.renderkit.html.BaseGradient;
-
-/**
- * @author Anton Belevich
- *
- */
-public class ComboBoxGradient extends BaseGradient {
-	public ComboBoxGradient() {
-		super(30, 50, 20,"headerGradientColor", "headerBackgroundColor");
-	}
-}

Modified: trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxImage.java
===================================================================
--- trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxImage.java	2007-12-29 13:42:29 UTC (rev 5102)
+++ trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxImage.java	2007-12-29 14:11:08 UTC (rev 5103)
@@ -64,10 +64,10 @@
 		Integer color = (Integer) restoreData(context);
 		g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
 		g2d.setColor(new Color(color.intValue()));
-		g2d.drawLine(5,5,11,5);
-		g2d.drawLine(6,6,10,6);
-		g2d.drawLine(7,7,9,7);
-		g2d.drawLine(8,8,8,8);
+		g2d.drawLine(4,5,10,5);
+		g2d.drawLine(5,6,9,6);
+		g2d.drawLine(6,7,8,7);
+		g2d.drawLine(7,8,7,8);
 	}
 	
 }

Added: trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxInputGradient.java
===================================================================
--- trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxInputGradient.java	                        (rev 0)
+++ trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/images/ComboBoxInputGradient.java	2007-12-29 14:11:08 UTC (rev 5103)
@@ -0,0 +1,16 @@
+/**
+ * 
+ */
+package org.richfaces.renderkit.images;
+
+import org.richfaces.renderkit.html.BaseGradient;
+
+/**
+ * @author Anton Belevich
+ *
+ */
+public class ComboBoxInputGradient extends BaseGradient {
+	public ComboBoxInputGradient() {
+		super(30, 50, 12, "additionalBackgroundColor", "controlBackgroundColor");
+	}
+}

Modified: trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/css/combobox.xcss
===================================================================
--- trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/css/combobox.xcss	2007-12-29 13:42:29 UTC (rev 5102)
+++ trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/css/combobox.xcss	2007-12-29 14:11:08 UTC (rev 5103)
@@ -37,6 +37,81 @@
 	cursor:pointer;
 }
 
+
+.rich_cb_width {
+	 width : 150px;
+}
+
+.rich_cb_font { 
+	font-size : 11px/*generalSizeFont*/; font-family : arial/*generalFamilyFont*/; color : #000000/*generalTextColor*/
+} 
+
+.rich_cb_strut { 
+	position : relative; 
+	visibility : hidden;  
+	margin : 0px; padding : 2px;
+}
+
+.rich_cb_shell {
+	position : relative;
+}
+
+.rich_cb_field { 
+	position : absolute; 
+	top : 0px; left : 0; 
+	padding-right :20px; 
+	padding-left :3px; 
+	margin : 0px; 
+	border : 1px solid #c0c0c0; 
+	background-position:left top;
+	background-repeat:repeat-x; 
+	border-color: #BED6F8 rgb(255, 255, 255) #BED6F8 rgb(190, 214, 248); 
+} /*panelBorderColor*/
+
+.rich_cb_button { 
+	position : absolute; 
+	top : 0px; 
+	right : 0; 
+	width : 17px; 
+	margin : 0px; 
+	border : 1px solid #c0c0c0; 
+	border-color: #BED6F8 rgb(190, 214, 248) #BED6F8 rgb(190, 214, 248); 
+} /*panelBorderColor*/
+
+.rich_cb_button_bg { 
+	background : top  repeat-x #C7D7EC;
+} 
+
+.rich_cb_button_bg_press { 
+	background : url(images/bg_press.png) repeat-x bottom #C7D7EC 
+} /*gradient - from tabBackgroundColor to generalBackgroundColor, background-color - tabBackgroundColor*/
+
+.rich_cb_button_arrow { 
+	background : center  no-repeat; cursor : pointer;
+}
+
+
 ]]>
+
 </f:verbatim>
+	/*gradient - from generalBackgroundColor to tabBackgroundColor, background-color - tabBackgroundColor*/
+	<u:selector name=".rich_cb_button_bg">
+		<u:style name="background-image">
+			<f:resource f:key="org.richfaces.renderkit.images.ComboBoxBtnGradient" />
+		</u:style>
+	</u:selector>
+	
+	<u:selector name=".rich_cb_field">
+		<u:style name="background-image">
+			<f:resource f:key="org.richfaces.renderkit.images.ComboBoxInputGradient" />
+		</u:style>
+	</u:selector>
+	
+	<u:selector name=".rich_cb_button_arrow">
+		<u:style name="background-image">
+			<f:resource f:key="org.richfaces.renderkit.images.ComboBoxImage" />
+		</u:style>
+	</u:selector>
+	
+
 </f:template>
\ No newline at end of file

Modified: trunk/sandbox/ui/combobox/src/main/templates/combobox.jspx
===================================================================
--- trunk/sandbox/ui/combobox/src/main/templates/combobox.jspx	2007-12-29 13:42:29 UTC (rev 5102)
+++ trunk/sandbox/ui/combobox/src/main/templates/combobox.jspx	2007-12-29 14:11:08 UTC (rev 5103)
@@ -17,21 +17,24 @@
 			scripts/comboboxUtils.js,
 			scripts/combobox.js
 	</h:scripts>
-	
-	<f:resource	name="org.richfaces.renderkit.html.images.SpinnerButtonDown" var="down_arrow" />
-	 
+ 
 	<f:clientid var="clientId" />
-	 <div id="#{clientId}">
-		<div id="comboboxControl#{clientId}" class="" style="position:relative;">
-			<input id="comboboxField#{clientId}" class="" type="text" size="20" autocomplete="off"/>
-			<img id="comboboxButton#{clientId}" class="" style="position:absolute; top:0pt; border:1px solid black;" src="#{combo_img}"/>
+
+	<div id="comboboxControl#{clientId}" class="rich_cb_width rich_cb_font rich_cb_shell">
+		<input id="comboboxField#{clientId}" class="rich_cb_width rich_cb_font rich_cb_field" type="text" size="20" autocomplete="off">
+		</input>
+		<input readonly="" type="text" value="" class="rich_cb_button rich_cb_font rich_cb_button_bg">
+		</input>
+		<input id="comboboxButton#{clientId}" readonly="" type="text" value="" class="rich_cb_button rich_cb_font rich_cb_button_arrow">
+		</input>
+		<input type="text" class="rich_cb_width rich_cb_strut rich_cb_font">
+		</input>
+		<div id="list#{clientId}" style="display:none" class="rich-combobox-list">
+			<f:call name="encodeItems"/>
 		</div>
-		<div id="listParent#{clientId}" style="display:none" class="rich-combobox-list">
-			<div id="list#{clientId}">
-				<f:call name="encodeItems"/>
-			</div>
-		</div>
 	</div>
+		
+
 	<script type="text/javascript">
 		var combobox = new Richfaces.ComboBox("#{clientId}", 
 							   "list#{clientId}", 




More information about the richfaces-svn-commits mailing list