JBoss Rich Faces SVN: r5675 - branches/3.1.x/ui/panelbar/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2008-01-28 14:54:18 -0500 (Mon, 28 Jan 2008)
New Revision: 5675
Modified:
branches/3.1.x/ui/panelbar/src/main/resources/org/richfaces/renderkit/html/scripts/panelbar.js
Log:
http://jira.jboss.com/jira/browse/RF-2069
Modified: branches/3.1.x/ui/panelbar/src/main/resources/org/richfaces/renderkit/html/scripts/panelbar.js
===================================================================
--- branches/3.1.x/ui/panelbar/src/main/resources/org/richfaces/renderkit/html/scripts/panelbar.js 2008-01-28 18:42:41 UTC (rev 5674)
+++ branches/3.1.x/ui/panelbar/src/main/resources/org/richfaces/renderkit/html/scripts/panelbar.js 2008-01-28 19:54:18 UTC (rev 5675)
@@ -204,10 +204,13 @@
// this.header.style.overflowX="hidden";
// this.header.style.overflowY="visible";
// this.header.style.cursor="pointer";
- this.header.onclick=this.headerOnClick.bindAsEventListener(this);
- this.header.onselectstart=this.headerOnSelectStart.bindAsEventListener(this);
- this.header_act.onclick=this.headerOnClick.bindAsEventListener(this);
- this.header_act.onselectstart=this.headerOnSelectStart.bindAsEventListener(this);
+
+ Event.observe(this.header, "click", this.headerOnClick.bindAsEventListener(this));
+ Event.observe(this.header, "selectstart", this.headerOnSelectStart.bindAsEventListener(this));
+
+ Event.observe(this.header_act, "click", this.headerOnClick.bindAsEventListener(this));
+ Event.observe(this.header_act, "selectstart", this.headerOnSelectStart.bindAsEventListener(this));
+
this.content.style.display="none";
this.content.style.overflow="auto";
this.content.style.height="0px";
16 years, 3 months
JBoss Rich Faces SVN: r5674 - branches/3.1.x/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2008-01-28 13:42:41 -0500 (Mon, 28 Jan 2008)
New Revision: 5674
Modified:
branches/3.1.x/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid/GridHeader.js
Log:
RF-1777
Modified: branches/3.1.x/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid/GridHeader.js
===================================================================
--- branches/3.1.x/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid/GridHeader.js 2008-01-28 17:01:31 UTC (rev 5673)
+++ branches/3.1.x/ui/scrollableDataTable/src/main/javascript/ClientUI/controls/grid/GridHeader.js 2008-01-28 18:42:41 UTC (rev 5674)
@@ -107,9 +107,11 @@
this.helpObj = new ClientUI.common.box.Box(this.frozenContentBox.getElement(), null, true);
- var fcount = this.headerFrozenRow.getElement().rows[0].cells.length;
- var ncount = this.headerRow.getElement().rows[0].cells.length;
- var columns = new Array(fcount + ncount);
+ var fcols = this.headerFrozenRow.getElement().getElementsByTagName("col");
+ this.fcount = fcols.length;
+ var cols = this.headerRow.getElement().getElementsByTagName("col");
+ this.ncount = cols.length;
+ var columns = new Array(this.fcount + this.ncount);
var defaultWidth = 0;
var defaultHeight = 0;
@@ -117,16 +119,14 @@
// Get columns information
var i = 0, h, j=0, cell;
- var cols = this.headerFrozenRow.getElement().getElementsByTagName("col");
var cells = this.headerFrozenRow.getElement().rows[0].cells;
var ids = this.grid.options.ids;
- var count = cells.length;
- for(i=0; i<count; i++) {
+ for(i=0; i<this.fcount; i++) {
cell = cells[i];
columns[j] = {
columnId: ids[i],
- col: cols[i],
- width: parseInt(cols[i].width),
+ col: fcols[i],
+ width: parseInt(fcols[i].width),
styleClass: cell.className,
id: cell.id,
align: cell.align,
@@ -164,10 +164,8 @@
j++;
}
- cols = this.headerRow.getElement().getElementsByTagName("col");
cells = this.headerRow.getElement().rows[0].cells;
- count = cells.length;
- for(i=0; i<count; i++) {
+ for(i=0; i<this.ncount; i++) {
cell = cells[i];
columns[j] = {
@@ -240,15 +238,14 @@
var i=0;
var fcells = this.headerFrozenRow.getElement().rows[0].cells;
var ncells = this.headerRow.getElement().rows[0].cells;
- var length = fcells.length;
var delta = 4;
if (ncells[0].offsetWidth == ncells[0].clientWidth) {
delta--;
}
- for(var j=0; j<length; i++,j++) {
+ for(var j=0; j<this.fcount; i++,j++) {
this._columns[i].sep.moveToX(fcells[j].offsetLeft + fcells[j].offsetWidth - delta);
}
- var length = ncells.length - 1;
+ var length = this.ncount - 1;
for(var j=0; j<length; i++,j++) {
this._columns[i].sep.moveToX(ncells[j].offsetLeft + ncells[j].offsetWidth - delta);
}
16 years, 3 months
JBoss Rich Faces SVN: r5673 - trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2008-01-28 12:01:31 -0500 (Mon, 28 Jan 2008)
New Revision: 5673
Modified:
trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/ComboBoxBaseRenderer.java
Log:
fix do decode
Modified: trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/ComboBoxBaseRenderer.java
===================================================================
--- trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/ComboBoxBaseRenderer.java 2008-01-28 16:51:14 UTC (rev 5672)
+++ trunk/sandbox/ui/combobox/src/main/java/org/richfaces/renderkit/ComboBoxBaseRenderer.java 2008-01-28 17:01:31 UTC (rev 5673)
@@ -73,9 +73,7 @@
Map request = context.getExternalContext().getRequestParameterMap();
if (request.containsKey(clientId)) {
String newValue = (String)request.get(clientId);
- if (!newValue.equals(comboBox.getDefaultLabel())) {
- comboBox.setSubmittedValue(newValue);
- }
+ comboBox.setSubmittedValue(newValue);
}
}
16 years, 3 months
JBoss Rich Faces SVN: r5672 - trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: vmolotkov
Date: 2008-01-28 11:51:14 -0500 (Mon, 28 Jan 2008)
New Revision: 5672
Modified:
trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
Log:
button's handlers are added
Modified: trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
===================================================================
--- trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-01-28 16:46:46 UTC (rev 5671)
+++ trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-01-28 16:51:14 UTC (rev 5672)
@@ -495,6 +495,9 @@
}
}
this.list.style.height = height;
+ if (this.iframe) {
+ this.iframe.style.height = height;
+ }
this.setWidth(this.width);
},
16 years, 3 months
JBoss Rich Faces SVN: r5671 - trunk/docs/userguide/en/src/main/docbook/included.
by richfaces-svn-commits@lists.jboss.org
Author: artdaw
Date: 2008-01-28 11:46:46 -0500 (Mon, 28 Jan 2008)
New Revision: 5671
Modified:
trunk/docs/userguide/en/src/main/docbook/included/calendar.xml
Log:
http://jira.jboss.com/jira/browse/RF-2057 - internationalization method to redefine and localize the labels described
Modified: trunk/docs/userguide/en/src/main/docbook/included/calendar.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/calendar.xml 2008-01-28 16:43:23 UTC (rev 5670)
+++ trunk/docs/userguide/en/src/main/docbook/included/calendar.xml 2008-01-28 16:46:46 UTC (rev 5671)
@@ -395,6 +395,20 @@
object. It could be used in the custom date representation on the calendar (inside the
custom facet).</listitem>
</itemizedlist>
+
+ <para>
+ The <emphasis role="bold">
+ <property><rich:calendar></property>
+ </emphasis> component provides the possibility to use internationalization method to redefine and localize the labels.
+ You could use application resource bundle and define
+ <property>RICH_CALENDAR_APPLY_LABEL</property>,
+ <property>RICH_CALENDAR_TODAY_LABEL</property>,
+ <property>RICH_CALENDAR_CLOSE_LABEL</property>,
+ <property>RICH_CALENDAR_OK_LABEL</property>,
+ <property>RICH_CALENDAR_CLEAN_LABEL</property>,
+ <property>RICH_CALENDAR_CANCEL_LABEL </property> there.
+ </para>
+ <para>You could also pack <property>org.richfaces.renderkit.calendar</property> resource bundle with your JARs defining the same properties.</para>
</section>
<section>
16 years, 3 months
JBoss Rich Faces SVN: r5670 - trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: vmolotkov
Date: 2008-01-28 11:43:23 -0500 (Mon, 28 Jan 2008)
New Revision: 5670
Modified:
trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
Log:
button's handlers are added
Modified: trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
===================================================================
--- trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-01-28 16:36:11 UTC (rev 5669)
+++ trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-01-28 16:43:23 UTC (rev 5670)
@@ -56,10 +56,10 @@
initHandlers : function() {
this.button.observe("click", function(e){this.buttonClickHandler(e);}.bindAsEventListener(this));
- //this.button.observe("mouseup", function(e){this.buttonMouseUpHandler(e);}.bindAsEventListener(this));
- //this.button.observe("mousedown", function(e){this.buttonMousedownHandler(e);}.bindAsEventListener(this));
- //this.button.observe("mouseover", function(e){this.buttonMouseOverHandler(e);}.bindAsEventListener(this));
- //this.button.observe("mouseout", function(e){this.buttonMouseOutHandler(e);}.bindAsEventListener(this));
+ this.button.observe("mouseup", function(e){this.buttonMouseUpHandler(e);}.bindAsEventListener(this));
+ this.button.observe("mousedown", function(e){this.buttonMousedownHandler(e);}.bindAsEventListener(this));
+ this.button.observe("mouseover", function(e){this.buttonMouseOverHandler(e);}.bindAsEventListener(this));
+ this.button.observe("mouseout", function(e){this.buttonMouseOutHandler(e);}.bindAsEventListener(this));
this.field.observe("keydown", function(e){this.fieldKeyDownHandler(e);}.bindAsEventListener(this));
this.field.observe("blur", function(e){this.fieldBlurHandler(e);}.bindAsEventListener(this));
16 years, 3 months
JBoss Rich Faces SVN: r5669 - trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: vmolotkov
Date: 2008-01-28 11:36:11 -0500 (Mon, 28 Jan 2008)
New Revision: 5669
Modified:
trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
Log:
iframe's added
Modified: trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
===================================================================
--- trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-01-28 16:26:53 UTC (rev 5668)
+++ trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-01-28 16:36:11 UTC (rev 5669)
@@ -48,8 +48,8 @@
}
if (Prototype.Browser.IE) {
- //this.comboList.createIframe(this.combobox, listWidth, this.combobox.id,
- // "rich-combobox-list-width rich-combobox-list-scroll rich-combobox-list-position");
+ this.comboList.createIframe(this.combobox, listWidth, this.combobox.id,
+ "rich-combobox-list-width rich-combobox-list-scroll rich-combobox-list-position");
}
this.initHandlers();
},
@@ -523,19 +523,19 @@
if (parseInt(listHeight) > (docHeight - comBottom)) {
if (fieldTop > (docHeight - comBottom)) {
top = fieldTop - parseInt(listHeight);
- var upPos = true;
+ //var upPos = true;
}
}
this.listParent.style.top = top + "px";
this.listParent.style.left = fieldLeft + "px";
- if (!upPos) {
+ /*if (!upPos) {
top = Richfaces.ComboBoxList.getElemXY(this.listParent).top + this.fieldDimensions.height;
- }
+ }*/
if (this.iframe) {
this.iframe.style.top = top + "px";
- this.iframe.style.left = Richfaces.ComboBoxList.getElemXY(this.listParent).left + "px";
+ this.iframe.style.left = fieldLeft + "px";
}
},
16 years, 3 months
JBoss Rich Faces SVN: r5668 - in trunk/sandbox/ui/combobox/src/main: templates and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: vmolotkov
Date: 2008-01-28 11:26:53 -0500 (Mon, 28 Jan 2008)
New Revision: 5668
Modified:
trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
trunk/sandbox/ui/combobox/src/main/templates/combobox.jspx
Log:
layout is corrected
Modified: trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js
===================================================================
--- trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-01-28 16:21:58 UTC (rev 5667)
+++ trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/scripts/combobox.js 2008-01-28 16:26:53 UTC (rev 5668)
@@ -4,7 +4,7 @@
Richfaces.ComboBox.prototype = {
- initialize: function(combobox, listId, parentListId, fieldId, buttonId, buttonBGId, iframeId, classes,
+ initialize: function(combobox, listId, parentListId, fieldId, buttonId, buttonBGId, classes,
listWidth, listHeight, itemsText, directInputSuggestions, filterNewValue,
selectFirstOnUpdate, onlistcall, onselected, defaultMessage, isDisabled, value,
showDelay, hideDelay) {
@@ -23,7 +23,7 @@
// fieldDem.height = this.field.offsetHeight;
listWidth = (!listWidth) ? this.getCurrentWidth() : listWidth;
- this.comboList = new Richfaces.ComboBoxList(listId, parentListId, iframeId, selectFirstOnUpdate, classes.COMBO_LIST, listWidth,
+ this.comboList = new Richfaces.ComboBoxList(listId, parentListId, selectFirstOnUpdate, classes.COMBO_LIST, listWidth,
listHeight, itemsText, onlistcall, fieldId, showDelay, hideDelay);
this.defaultMessage = defaultMessage;
if (value) {
@@ -46,15 +46,20 @@
if (this.isDisabled) {
this.doDisable();
}
+
+ if (Prototype.Browser.IE) {
+ //this.comboList.createIframe(this.combobox, listWidth, this.combobox.id,
+ // "rich-combobox-list-width rich-combobox-list-scroll rich-combobox-list-position");
+ }
this.initHandlers();
},
initHandlers : function() {
this.button.observe("click", function(e){this.buttonClickHandler(e);}.bindAsEventListener(this));
- this.button.observe("mouseup", function(e){this.buttonMouseUpHandler(e);}.bindAsEventListener(this));
- this.button.observe("mousedown", function(e){this.buttonMousedownHandler(e);}.bindAsEventListener(this));
- this.button.observe("mouseover", function(e){this.buttonMouseOverHandler(e);}.bindAsEventListener(this));
- this.button.observe("mouseout", function(e){this.buttonMouseOutHandler(e);}.bindAsEventListener(this));
+ //this.button.observe("mouseup", function(e){this.buttonMouseUpHandler(e);}.bindAsEventListener(this));
+ //this.button.observe("mousedown", function(e){this.buttonMousedownHandler(e);}.bindAsEventListener(this));
+ //this.button.observe("mouseover", function(e){this.buttonMouseOverHandler(e);}.bindAsEventListener(this));
+ //this.button.observe("mouseout", function(e){this.buttonMouseOutHandler(e);}.bindAsEventListener(this));
this.field.observe("keydown", function(e){this.fieldKeyDownHandler(e);}.bindAsEventListener(this));
this.field.observe("blur", function(e){this.fieldBlurHandler(e);}.bindAsEventListener(this));
@@ -344,12 +349,13 @@
Richfaces.ComboBoxList = Class.create();
Richfaces.ComboBoxList.prototype = {
- initialize: function(listId, parentListId, iframeId, selectFirstOnUpdate, classes, width, height, itemsText, onlistcall, fieldId,
+ initialize: function(listId, parentListId, selectFirstOnUpdate, classes, width, height, itemsText, onlistcall, fieldId,
showDelay, hideDelay) {
this.list = $(listId);
this.listParent = $(parentListId);
- this.iframe = $(iframeId);
+ //this.iframe = $(iframeId);
+ this.iframe = null;
this.fieldElem = $(fieldId);
this.itemsText = itemsText;
@@ -411,7 +417,7 @@
show : function() {
this.fieldDimensions = Richfaces.ComboBoxList.getElemXY(this.fieldElem);
- this.fieldDimensions.height = this.fieldElem.offsetHeight;
+ this.fieldDimensions.height = this.fieldElem.parentNode.offsetHeight;
this.setSize();
@@ -432,7 +438,9 @@
}
}
}
- this.iframe.show();
+ if (this.iframe) {
+ this.iframe.show();
+ }
this.listParent.show();
this.listParent.fire("rich:onlistcall", {});
@@ -447,7 +455,9 @@
hide : function() {
this.resetState();
- this.iframe.hide();
+ if (this.iframe) {
+ this.iframe.hide();
+ }
this.listParent.hide();
},
@@ -490,36 +500,43 @@
},
setWidth : function(width) {
- var positionElem = this.listParent.childNodes[2];
+ var positionElem = this.listParent.childNodes[1];
var combobox = this.listParent.parentNode;
//positionElem.style.width = width;
- var correction = parseInt(width) - Richfaces.getBorderWidth(positionElem.firstChild, "lr") - Richfaces.getPaddingWidth(positionElem.firstChild, "lr") + "px";
+ var correction = parseInt(width) - Richfaces.getBorderWidth(positionElem.firstChild, "lr") - Richfaces.getPaddingWidth(positionElem.firstChild, "lr") + "px";
this.list.style.width = correction;
combobox.style.width = correction;
- this.iframe.style.width = correction;
+ if (this.iframe) {
+ this.iframe.style.width = correction;
+ }
},
setPosition : function(fieldTop, fieldLeft, fieldHeight) {
var docHeight = Richfaces.getDocumentHeight();
var comBottom = fieldTop + fieldHeight;
- var listHeight = this.list.style.height;
+ var listHeight = parseInt(this.list.style.height) + Richfaces.getBorderWidth(this.list.parentNode, "tb");
- var top = 0 ;//= -4;
+ //var top = 0 ;//= -4;
+ var top = comBottom;
if (parseInt(listHeight) > (docHeight - comBottom)) {
if (fieldTop > (docHeight - comBottom)) {
- top -= (parseInt(listHeight) + fieldHeight);
+ top = fieldTop - parseInt(listHeight);
var upPos = true;
}
- }
+ }
+
this.listParent.style.top = top + "px";
- this.listParent.style.left = 0 + "px";
+ this.listParent.style.left = fieldLeft + "px";
+
if (!upPos) {
top = Richfaces.ComboBoxList.getElemXY(this.listParent).top + this.fieldDimensions.height;
}
- this.iframe.style.top = top + "px";
- this.iframe.style.left = Richfaces.ComboBoxList.getElemXY(this.listParent).left + "px";
+ if (this.iframe) {
+ this.iframe.style.top = top + "px";
+ this.iframe.style.left = Richfaces.ComboBoxList.getElemXY(this.listParent).left + "px";
+ }
},
scrolling : function(event) {
@@ -606,7 +623,7 @@
resetState : function() {
var tempList = this.list.cloneNode(false);
- this.listParent.childNodes[2].firstChild.replaceChild(tempList, this.list);
+ this.listParent.childNodes[1].firstChild.replaceChild(tempList, this.list);
this.list = $(tempList.id);
this.activeItem = null;
this.isList = false;
@@ -655,19 +672,34 @@
createItem : function(text, className) {
return "<span class=\"" + className+ "\">" + text + "</span>";
+ },
+
+ createIframe : function(parentElem, width, comboboxId, classes) {
+ var iframe = document.createElement("iframe");
+
+ iframe.id = "iframe" + comboboxId;
+
+ iframe.style.display = "none";
+ iframe.style.width = width;
+ iframe.style.zIndex = "2";
+
+ iframe.className = classes;
+
+ parentElem.appendChild(iframe);
+ this.iframe = $(iframe.id);
}
}
Richfaces.ComboBoxList.getElemXY = function(elem) {
// for FF support
- var originalVisibility = elem.style.visibility;
+ /*var originalVisibility = elem.style.visibility;
var originalPosition = elem.style.position;
var originalDisplay = elem.style.display;
elem.style.visibility = 'hidden';
elem.style.position = 'absolute';
- elem.style.display = 'block';
+ elem.style.display = 'block';*/
var x = elem.offsetLeft;
var y = elem.offsetTop;
@@ -678,10 +710,9 @@
y += parent.offsetTop;
}
- elem.style.display = originalDisplay;
+ /*elem.style.display = originalDisplay;
elem.style.visibility = originalVisibility;
- elem.style.position = originalPosition;
-
+ elem.style.position = originalPosition;*/
return {left: x, top: y};
}
Modified: trunk/sandbox/ui/combobox/src/main/templates/combobox.jspx
===================================================================
--- trunk/sandbox/ui/combobox/src/main/templates/combobox.jspx 2008-01-28 16:21:58 UTC (rev 5667)
+++ trunk/sandbox/ui/combobox/src/main/templates/combobox.jspx 2008-01-28 16:26:53 UTC (rev 5668)
@@ -203,10 +203,10 @@
</jsp:scriptlet>
<f:resource var="spacer" name="images/spacer.gif"/>
-<div id="control#{clientId}" class="rich-combobox-list-width rich-combobox-font rich-combobox-shell rich-combobox= #{styleClass}" style="width:#{listWidth};#{style}"
+<div id="control#{clientId}" class="rich-combobox-list-width rich-combobox-font rich-combobox #{styleClass}" style="width:#{listWidth};#{style}"
x:passThruWithExclusions="value,name,type,id,styleClass,class,style,size,autocomplete,disabled,onchange">
<div class="rich-combobox-list-cord"></div>
- <div class="rich-combobox-input-width rich-combobox-font rich-combobox-shell" style="width:#{width};">
+ <div class="rich-combobox-input-width rich-combobox-font rich-combobox-shell" style="width:#{width};z-index:1;">
<input id="comboboxField#{clientId}"
name="comboboxField#{clientId}"
disabled="#{disabled}"
@@ -224,8 +224,7 @@
<div class="rich-combobox-input-width rich-combobox-strut rich-combobox-font" style="width:#{correction}">Strut</div>
</div>
- <div id="listParent#{clientId}" class="rich-combobox-list-cord #{listClass}" style="display:none; #{listStyle};">
- <iframe id="iframe#{clientId}" class="rich-combobox-list-width rich-combobox-list-scroll rich-combobox-list-position" frameborder="0" style="display:none; width:#{listWidth};"/>
+ <div id="listParent#{clientId}" class="rich-combobox-list-cord #{listClass}" style="display:none; #{listStyle};z-index: 3;position:absolute;">
<div class="rich-combobox-shadow">
<table cellpadding="0" cellspacing="0" border="0" width="255" height="109">
<tr>
@@ -303,7 +302,6 @@
"comboboxField#{clientId}",
"comboboxButton#{clientId}",
"comboBoxButtonBG#{clientId}",
- "iframe#{clientId}",
Richfaces.ComboBox.CLASSES,
"#{listWidth}", "#{listHeight}",
#{this:getItemsTextAsJSArray(context, component)},
16 years, 3 months
JBoss Rich Faces SVN: r5667 - trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/css.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2008-01-28 11:21:58 -0500 (Mon, 28 Jan 2008)
New Revision: 5667
Modified:
trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/css/combobox.xcss
Log:
add border color for button
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 2008-01-28 14:52:59 UTC (rev 5666)
+++ trunk/sandbox/ui/combobox/src/main/resources/org/richfaces/renderkit/html/css/combobox.xcss 2008-01-28 16:21:58 UTC (rev 5667)
@@ -240,6 +240,18 @@
<u:style name="border-color" skin="selectControlColor"/>
</u:selector>
+ <u:selector name=".rich-combobox-button">
+ <u:style name="border-color" skin="panelBorderColor"/>
+ </u:selector>
+
+ <u:selector name=".rich-combobox-button-inactive">
+ <u:style name="border-color" skin="panelBorderColor"/>
+ </u:selector>
+
+ <u:selector name=".rich-combobox-button-disabled">
+ <u:style name="border-color" skin="panelBorderColor"/>
+ </u:selector>
+
<u:selector name=".rich-combobox-font">
<u:style name="font-size" skin="generalSizeFont"/>
<u:style name="font-family" skin="generalFamilyFont"/>
16 years, 3 months
JBoss Rich Faces SVN: r5666 - trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2008-01-28 09:52:59 -0500 (Mon, 28 Jan 2008)
New Revision: 5666
Modified:
trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonDown.java
trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonImage.java
trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonUp.java
Log:
re-skinning
Modified: trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonDown.java
===================================================================
--- trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonDown.java 2008-01-28 14:52:33 UTC (rev 5665)
+++ trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonDown.java 2008-01-28 14:52:59 UTC (rev 5666)
@@ -41,12 +41,30 @@
}
protected void paint(ResourceContext context, Graphics2D g2d) {
- Integer color = (Integer) restoreData(context);
+ Color[] color = (Color []) restoreData(context);
+ Color triangleColor = color[0];
+ Color borderColor = color[1];
+
g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
- g2d.setColor(new Color(color.intValue()));
+ g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF);
+ g2d.setRenderingHint(RenderingHints.KEY_STROKE_CONTROL, RenderingHints.VALUE_STROKE_NORMALIZE);
+ g2d.setRenderingHint(RenderingHints.KEY_COLOR_RENDERING, RenderingHints.VALUE_COLOR_RENDER_QUALITY);
+ g2d.setRenderingHint(RenderingHints.KEY_DITHERING, RenderingHints.VALUE_DITHER_DISABLE);
+ g2d.setRenderingHint(RenderingHints.KEY_ALPHA_INTERPOLATION, RenderingHints.VALUE_ALPHA_INTERPOLATION_QUALITY);
+ g2d.setRenderingHint(RenderingHints.KEY_INTERPOLATION, RenderingHints.VALUE_INTERPOLATION_BICUBIC);
+ g2d.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY);
+
+ g2d.setColor(triangleColor);
g2d.drawLine(5,2,9,2);
g2d.drawLine(6,3,8,3);
g2d.drawLine(7,4,7,4);
+
+ g2d.setColor(borderColor);
+ g2d.drawLine(5, 1, 9, 1);
+ g2d.drawLine(10, 2, 7, 5);
+ g2d.drawLine(7, 5, 4, 2);
+
+
}
Modified: trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonImage.java
===================================================================
--- trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonImage.java 2008-01-28 14:52:33 UTC (rev 5665)
+++ trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonImage.java 2008-01-28 14:52:59 UTC (rev 5666)
@@ -21,6 +21,7 @@
package org.richfaces.renderkit.html.images;
+import java.awt.Color;
import java.util.Date;
import javax.faces.context.FacesContext;
@@ -44,24 +45,37 @@
if (objectArray == null) {
return null;
}
-
- return new Integer(new Zipper2(objectArray).nextIntColor());
+ Zipper2 zipper = new Zipper2(objectArray);
+ return new Color[] {zipper.nextColor(), zipper.nextColor()};
}
protected Object getDataToStore(FacesContext context, Object data) {
Skin skin = SkinFactory.getInstance().getSkin(context);
+ byte[] ret = new byte[6];
+ Zipper2 zipper = new Zipper2(ret);
- String skinParameter = "headerTextColor";
- String headerTextColor = (String) skin.getParameter(context, skinParameter);
- if (null == headerTextColor || "".equals(headerTextColor)) {
+ String skinParameterTextColor = "generalTextColor";
+ String generalTextColor = (String) skin.getParameter(context, skinParameterTextColor);
+ if (null == generalTextColor || "".equals(generalTextColor)) {
Skin defaultSkin = SkinFactory.getInstance().getDefaultSkin(context);
- headerTextColor = (String) defaultSkin.getParameter(context, skinParameter);
+ generalTextColor = (String) defaultSkin.getParameter(context, skinParameterTextColor);
}
+
+ Integer color = HtmlColor.decode( generalTextColor == null ? "#000000":generalTextColor ).getRGB();
+
+ zipper.addColor(color);
- int intValue = HtmlColor.decode( headerTextColor == null ? "#000000":headerTextColor ).getRGB();
- byte[] ret = new byte[3];
- new Zipper2(ret).addColor(intValue);
+ String skinParameterBackgroundColor = "controlBackgroundColor";
+ String generalBackgroundColor = (String) skin.getParameter(context, skinParameterBackgroundColor);
+ if (null == generalBackgroundColor || "".equals(generalBackgroundColor)) {
+ Skin defaultSkin = SkinFactory.getInstance().getDefaultSkin(context);
+ generalBackgroundColor = (String) defaultSkin.getParameter(context, skinParameterBackgroundColor);
+ }
+
+ color = HtmlColor.decode( generalTextColor == null ? "#FFFFFF":generalBackgroundColor ).getRGB();
+ zipper.addColor(color);
+
return ret;
}
Modified: trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonUp.java
===================================================================
--- trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonUp.java 2008-01-28 14:52:33 UTC (rev 5665)
+++ trunk/framework/impl/src/main/java/org/richfaces/renderkit/html/images/SpinnerButtonUp.java 2008-01-28 14:52:59 UTC (rev 5666)
@@ -41,14 +41,31 @@
}
protected void paint(ResourceContext context, Graphics2D g2d) {
- Integer color = (Integer) restoreData(context);
- g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
- g2d.setColor(new Color(color.intValue()));
+
+ Color [] data = (Color []) restoreData(context);
+ Color textColor = data[0];
+ Color borderColor = data[1];
+
+ g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_OFF);
+ g2d.setRenderingHint(RenderingHints.KEY_STROKE_CONTROL, RenderingHints.VALUE_STROKE_NORMALIZE);
+ g2d.setRenderingHint(RenderingHints.KEY_COLOR_RENDERING, RenderingHints.VALUE_COLOR_RENDER_QUALITY);
+ g2d.setRenderingHint(RenderingHints.KEY_DITHERING, RenderingHints.VALUE_DITHER_DISABLE);
+ g2d.setRenderingHint(RenderingHints.KEY_ALPHA_INTERPOLATION, RenderingHints.VALUE_ALPHA_INTERPOLATION_QUALITY);
+ g2d.setRenderingHint(RenderingHints.KEY_INTERPOLATION, RenderingHints.VALUE_INTERPOLATION_BICUBIC);
+ g2d.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY);
+
+ g2d.setColor(textColor);
g2d.drawLine(5,5,9,5);
g2d.drawLine(6,4,8,4);
g2d.drawLine(7,3,7,3);
+
+ g2d.setColor(borderColor);
+ g2d.drawLine(5, 6, 9, 6);
+ g2d.drawLine(10, 5, 7, 2);
+ g2d.drawLine(7, 2, 4, 5);
+
}
-
+
+}
-}
16 years, 3 months