JBoss Rich Faces SVN: r21373 - branches/enterprise/3.3.X/framework/impl/src/test/java/org/ajax4jsf/io.
by richfaces-svn-commits@lists.jboss.org
Author: jbalunas(a)redhat.com
Date: 2011-02-01 13:38:31 -0500 (Tue, 01 Feb 2011)
New Revision: 21373
Modified:
branches/enterprise/3.3.X/framework/impl/src/test/java/org/ajax4jsf/io/ByteBufferTest.java
Log:
RF-8738 fixed unit test to check for StackOverflowError
Modified: branches/enterprise/3.3.X/framework/impl/src/test/java/org/ajax4jsf/io/ByteBufferTest.java
===================================================================
--- branches/enterprise/3.3.X/framework/impl/src/test/java/org/ajax4jsf/io/ByteBufferTest.java 2011-02-01 18:28:52 UTC (rev 21372)
+++ branches/enterprise/3.3.X/framework/impl/src/test/java/org/ajax4jsf/io/ByteBufferTest.java 2011-02-01 18:38:31 UTC (rev 21373)
@@ -47,8 +47,13 @@
//create a dummy byte array
byte[] bs = new byte[10];
- //attempt to append the byte[] to the first buffer
- buffer1.append(bs, 0, bs.length);
+ try{
+ //attempt to append the byte[] to the first buffer
+ buffer1.append(bs, 0, bs.length);
+ }catch(StackOverflowError e){
+ fail("StackOverflowError while attempting to test ByteBuffer.append(), " +
+ "endless recursion found");
+ }
}
13 years, 11 months
JBoss Rich Faces SVN: r21372 - in branches/enterprise/3.3.X/framework/impl/src: test/java/org/ajax4jsf/io and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: jbalunas(a)redhat.com
Date: 2011-02-01 13:28:52 -0500 (Tue, 01 Feb 2011)
New Revision: 21372
Added:
branches/enterprise/3.3.X/framework/impl/src/test/java/org/ajax4jsf/io/ByteBufferTest.java
Modified:
branches/enterprise/3.3.X/framework/impl/src/main/java/org/ajax4jsf/io/ByteBuffer.java
Log:
RF-8738 Resolved endless recursion issue
Modified: branches/enterprise/3.3.X/framework/impl/src/main/java/org/ajax4jsf/io/ByteBuffer.java
===================================================================
--- branches/enterprise/3.3.X/framework/impl/src/main/java/org/ajax4jsf/io/ByteBuffer.java 2011-02-01 18:00:25 UTC (rev 21371)
+++ branches/enterprise/3.3.X/framework/impl/src/main/java/org/ajax4jsf/io/ByteBuffer.java 2011-02-01 18:28:52 UTC (rev 21372)
@@ -95,7 +95,7 @@
*/
public ByteBuffer append(byte[] bs, int off, int len) {
if(next != null) {
- return append(bs, off, len);
+ return next.append(bs, off, len);
}
if(len + usedSize <= cacheSize) {
System.arraycopy(bs, off, bytes, usedSize, len);
Added: branches/enterprise/3.3.X/framework/impl/src/test/java/org/ajax4jsf/io/ByteBufferTest.java
===================================================================
--- branches/enterprise/3.3.X/framework/impl/src/test/java/org/ajax4jsf/io/ByteBufferTest.java (rev 0)
+++ branches/enterprise/3.3.X/framework/impl/src/test/java/org/ajax4jsf/io/ByteBufferTest.java 2011-02-01 18:28:52 UTC (rev 21372)
@@ -0,0 +1,55 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2011 Red Hat Inc. and/or its affiliates and other contributors
+ * as indicated by the @authors tag. All rights reserved.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This copyrighted material is made available to anyone wishing to use,
+ * modify, copy, or redistribute it subject to the terms and conditions
+ * of the GNU Lesser General Public License, v. 2.1.
+ * This program is distributed in the hope that it will be useful, but WITHOUT A
+ * 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,
+ * v.2.1 along with this distribution; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
+ */
+package org.ajax4jsf.io;
+
+import junit.framework.TestCase;
+
+/**
+ * Test cases for the ByteBuffer class
+ * @author balunasj
+ *
+ */
+public class ByteBufferTest extends TestCase {
+
+ /**
+ * Test method for RF-8738 at {@link org.ajax4jsf.io.ByteBuffer#append(byte[] bs, int off, int len)}.
+ *
+ * RF-8738 reports a possible endless recursion when appending to a byte buffer
+ * who is not the last in the chain. i.e. who's "next" is not null.
+ */
+ public void testByteBufferAppend_RF_8738() throws Exception {
+ //Does not really matter how big this is for the test
+ int cacheSize = 2;
+
+ //Create two buffer
+ ByteBuffer buffer1 = new ByteBuffer(cacheSize);
+ ByteBuffer buffer2 = new ByteBuffer(cacheSize);
+
+ //add one buffer as the "next" of the other
+ buffer1.setNext(buffer2);
+
+ //create a dummy byte array
+ byte[] bs = new byte[10];
+
+ //attempt to append the byte[] to the first buffer
+ buffer1.append(bs, 0, bs.length);
+
+ }
+
+}
13 years, 11 months
JBoss Rich Faces SVN: r21371 - trunk/ui/output/ui/src/main/resources/META-INF/resources/org.richfaces.
by richfaces-svn-commits@lists.jboss.org
Author: artdaw
Date: 2011-02-01 13:00:25 -0500 (Tue, 01 Feb 2011)
New Revision: 21371
Modified:
trunk/ui/output/ui/src/main/resources/META-INF/resources/org.richfaces/popupPanel.js
Log:
RF-10249: popup panel is fixed for domElementAttachment=form
Modified: trunk/ui/output/ui/src/main/resources/META-INF/resources/org.richfaces/popupPanel.js
===================================================================
--- trunk/ui/output/ui/src/main/resources/META-INF/resources/org.richfaces/popupPanel.js 2011-02-01 16:46:45 UTC (rev 21370)
+++ trunk/ui/output/ui/src/main/resources/META-INF/resources/org.richfaces/popupPanel.js 2011-02-01 18:00:25 UTC (rev 21371)
@@ -243,7 +243,7 @@
if ('parent' == domElementAttachment) {
newParent = this.parent;
} else if ('form' == domElementAttachment) {
- newParent = this.findForm(element) || document.body;
+ newParent = this.findForm(element)[0] || document.body;
} else {
//default - body
newParent = document.body;
13 years, 11 months
JBoss Rich Faces SVN: r21370 - in modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest: richPopupPanel and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: ppitonak(a)redhat.com
Date: 2011-02-01 11:46:45 -0500 (Tue, 01 Feb 2011)
New Revision: 21370
Modified:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/TestRichHashParam.java
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richPopupPanel/TestRichPopupPanel.java
Log:
* code cleaned
Modified: modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/TestRichHashParam.java
===================================================================
--- modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/TestRichHashParam.java 2011-02-01 16:44:00 UTC (rev 21369)
+++ modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/TestRichHashParam.java 2011-02-01 16:46:45 UTC (rev 21370)
@@ -46,7 +46,6 @@
private JQueryLocator openButton = pjq("input[id$=openPanelButton]");
private JQueryLocator panel = pjq("div[id$=popupPanel]");
private JQueryLocator panelContainer = jq("div.rf-pp-cntr");
- private JQueryLocator content = jq("div.rf-pp-cnt");
private JQueryLocator header = jq("div.rf-pp-hdr");
private JQueryLocator controls = jq("div.rf-pp-hdr-cntrls a");
private JQueryLocator scroller = jq("div.rf-pp-cnt-scrlr");
Modified: modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richPopupPanel/TestRichPopupPanel.java
===================================================================
--- modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richPopupPanel/TestRichPopupPanel.java 2011-02-01 16:44:00 UTC (rev 21369)
+++ modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richPopupPanel/TestRichPopupPanel.java 2011-02-01 16:46:45 UTC (rev 21370)
@@ -483,7 +483,6 @@
top = (top - 300) / 2;
selenium.click(openButton);
waitGui.failWith("Panel was not opened.").until(isDisplayed.locator(panel));
- waitFor(6000);
assertEquals(selenium.getElementPositionTop(panelContainer), Math.round(top), "Top margin of the panel");
selenium.type(pjq("input[id$=topInput]"), "200");
13 years, 11 months
JBoss Rich Faces SVN: r21369 - in modules/tests/metamer/trunk: ftest-source/src/main/java/org/richfaces/tests/metamer/ftest and 1 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: ppitonak(a)redhat.com
Date: 2011-02-01 11:44:00 -0500 (Tue, 01 Feb 2011)
New Revision: 21369
Added:
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/
modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/TestRichHashParam.java
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richHashParam/simple.xhtml
Log:
https://issues.jboss.org/browse/RFPL-736
* added 7 tests for rich:hashParam
Modified: modules/tests/metamer/trunk/application/src/main/webapp/components/richHashParam/simple.xhtml
===================================================================
--- modules/tests/metamer/trunk/application/src/main/webapp/components/richHashParam/simple.xhtml 2011-02-01 16:20:31 UTC (rev 21368)
+++ modules/tests/metamer/trunk/application/src/main/webapp/components/richHashParam/simple.xhtml 2011-02-01 16:44:00 UTC (rev 21369)
@@ -42,8 +42,7 @@
<rich:popupPanel id="popupPanel" resizeable="true"
header="Popup panel shown using rich:componentControl and rich:hashParam">
<f:facet name="controls">
- <h:outputLink value="#"
- onclick="#{rich:component('popupPanel')}.hide(); return false;">
+ <h:outputLink value="#" onclick="#{rich:component('popupPanel')}.hide(); return false;">
X
</h:outputLink>
</f:facet>
@@ -71,7 +70,7 @@
</fieldset>
</rich:popupPanel>
- <h:commandButton value="Show popup">
+ <h:commandButton id="openPanelButton" value="Show popup">
<rich:componentControl target="popupPanel" operation="show">
<a4j:param noEscape="true" value="event" />
<rich:hashParam>
@@ -79,8 +78,8 @@
<f:param name="height" value="345px" />
<f:param name="minWidth" value="300px" />
<f:param name="minHeight" value="150px" />
- <a4j:param noEscape="true" name="left" value="(jQuery(window).width()/2)-250" />
- <a4j:param noEscape="true" name="top" value="(jQuery(window).height()/2)-150" />
+ <a4j:param noEscape="true" name="left" value="33+44" />
+ <a4j:param noEscape="true" name="top" value="55-33" />
</rich:hashParam>
</rich:componentControl>
</h:commandButton>
Added: modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/TestRichHashParam.java
===================================================================
--- modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/TestRichHashParam.java (rev 0)
+++ modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/TestRichHashParam.java 2011-02-01 16:44:00 UTC (rev 21369)
@@ -0,0 +1,157 @@
+/*******************************************************************************
+ * JBoss, Home of Professional Open Source
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This 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 software 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 software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ *******************************************************************************/
+package org.richfaces.tests.metamer.ftest.richHashParam;
+
+import static org.jboss.test.selenium.locator.LocatorFactory.jq;
+import static org.jboss.test.selenium.utils.URLUtils.buildUrl;
+import static org.testng.Assert.assertEquals;
+import static org.testng.Assert.assertFalse;
+import static org.testng.Assert.assertTrue;
+
+import java.net.URL;
+
+import org.jboss.test.selenium.css.CssProperty;
+import org.jboss.test.selenium.geometry.Offset;
+import org.jboss.test.selenium.locator.JQueryLocator;
+import org.richfaces.tests.metamer.ftest.AbstractMetamerTest;
+import org.testng.annotations.Test;
+
+/**
+ * Test case for page /faces/components/richHashParam/simple.xhtml
+ *
+ * @author <a href="mailto:ppitonak@redhat.com">Pavol Pitonak</a>
+ * @version $Revision$
+ */
+public class TestRichHashParam extends AbstractMetamerTest {
+
+ private JQueryLocator openButton = pjq("input[id$=openPanelButton]");
+ private JQueryLocator panel = pjq("div[id$=popupPanel]");
+ private JQueryLocator panelContainer = jq("div.rf-pp-cntr");
+ private JQueryLocator content = jq("div.rf-pp-cnt");
+ private JQueryLocator header = jq("div.rf-pp-hdr");
+ private JQueryLocator controls = jq("div.rf-pp-hdr-cntrls a");
+ private JQueryLocator scroller = jq("div.rf-pp-cnt-scrlr");
+ private JQueryLocator shadow = jq("div.rf-pp-shdw");
+ private JQueryLocator resizerW = jq("div.rf-pp-hndlr-l");
+ private JQueryLocator resizerN = jq("div.rf-pp-hndlr-t");
+ private JQueryLocator resizerE = jq("div.rf-pp-hndlr-r");
+ private JQueryLocator resizerS = jq("div.rf-pp-hndlr-b");
+ private JQueryLocator resizerNW = jq("div.rf-pp-hndlr-tl");
+ private JQueryLocator resizerNE = jq("div.rf-pp-hndlr-tr");
+ private JQueryLocator resizerSW = jq("div.rf-pp-hndlr-bl");
+ private JQueryLocator resizerSE = jq("div.rf-pp-hndlr-br");
+
+ @Override
+ public URL getTestUrl() {
+ return buildUrl(contextPath, "faces/components/richHashParam/simple.xhtml");
+ }
+
+ @Test
+ public void testPanelInit() {
+ assertTrue(selenium.isElementPresent(openButton), "Button for opening popup should be on the page.");
+ assertTrue(selenium.isElementPresent(panel), "Popup panel is not present on the page.");
+ assertFalse(selenium.isVisible(panel), "Popup panel is visible.");
+
+ selenium.click(openButton);
+ assertTrue(selenium.isVisible(panel), "Popup panel should be visible.");
+ assertTrue(selenium.isVisible(panelContainer), "Popup panel's container should be visible.");
+ assertTrue(selenium.isVisible(header), "Popup panel's header should be visible.");
+ assertTrue(selenium.isVisible(controls), "Popup panel's controls should be visible.");
+ assertTrue(selenium.isVisible(scroller), "Popup panel's scroller should be visible.");
+ assertTrue(selenium.isVisible(shadow), "Popup panel's shadow should be visible.");
+ assertTrue(selenium.isVisible(resizerE), "Popup panel's right resizer should be visible.");
+ assertTrue(selenium.isVisible(resizerN), "Popup panel's top resizer should be visible.");
+ assertTrue(selenium.isVisible(resizerS), "Popup panel's bottom resizer should be visible.");
+ assertTrue(selenium.isVisible(resizerW), "Popup panel's left resizer should be visible.");
+ assertTrue(selenium.isVisible(resizerNE), "Popup panel's top-right resizer should be visible.");
+ assertTrue(selenium.isVisible(resizerNW), "Popup panel's top-left resizer should be visible.");
+ assertTrue(selenium.isVisible(resizerSE), "Popup panel's bottom-right resizer should be visible.");
+ assertTrue(selenium.isVisible(resizerSW), "Popup panel's bottom-left resizer should be visible.");
+ }
+
+ @Test
+ public void testPanelMove() {
+ selenium.click(openButton);
+ int panelLeft = selenium.getElementPositionLeft(panelContainer);
+ int shadowLeft = selenium.getElementPositionLeft(shadow);
+
+ assertEquals(selenium.getStyle(header, new CssProperty("cursor")), "move", "Cursor used when mouse is over panel's header.");
+ selenium.dragAndDrop(header, new Offset(200, -100));
+
+ assertEquals(selenium.getElementPositionLeft(panelContainer), panelLeft + 200, "Panel's position after move to the right (200px).");
+ assertEquals(selenium.getElementPositionLeft(shadow), shadowLeft + 200, "Shadow's position after move to the right (200px).");
+ }
+
+ @Test
+ public void testPanelResizeHorizontal() {
+ selenium.click(openButton);
+ int panelWidth = selenium.getElementWidth(panelContainer);
+ int panelHeight = selenium.getElementHeight(panelContainer);
+ int shadowWidth = selenium.getElementWidth(shadow);
+ int shadowHeight = selenium.getElementHeight(shadow);
+
+ assertEquals(selenium.getStyle(resizerW, new CssProperty("cursor")), "w-resize", "Cursor used when mouse is over panel's left resizer.");
+ assertEquals(selenium.getStyle(resizerE, new CssProperty("cursor")), "e-resize", "Cursor used when mouse is over panel's right resizer.");
+
+ selenium.dragAndDrop(resizerW, new Offset(100, 0));
+
+ assertEquals(selenium.getElementWidth(panelContainer), panelWidth - 100, "Panel's width after resizing horizontally (-100px).");
+ assertEquals(selenium.getElementHeight(panelContainer), panelHeight, "Panel's height after resizing horizontally.");
+ assertEquals(selenium.getElementWidth(shadow), shadowWidth - 100, "Shadow's width after resizing horizontally (-100px).");
+ assertEquals(selenium.getElementHeight(shadow), shadowHeight, "Shadow's height after resizing horizontally.");
+
+ selenium.dragAndDrop(resizerE, new Offset(100, 0));
+
+ assertEquals(selenium.getElementWidth(panelContainer), panelWidth, "Panel's width after resizing horizontally (100px).");
+ assertEquals(selenium.getElementHeight(panelContainer), panelHeight, "Panel's height after resizing horizontally.");
+ assertEquals(selenium.getElementWidth(shadow), shadowWidth, "Shadow's width after resizing horizontally (100px).");
+ assertEquals(selenium.getElementHeight(shadow), shadowHeight, "Shadow's height after resizing horizontally.");
+ }
+
+ @Test
+ public void testPanelHeight() {
+ selenium.click(openButton);
+ waitGui.failWith("Panel was not opened.").until(isDisplayed.locator(panel));
+ assertEquals(selenium.getStyle(panelContainer, CssProperty.HEIGHT), "345px", "Height of the panel");
+ }
+
+ @Test
+ public void testPanelLeft() {
+ selenium.click(openButton);
+ waitGui.failWith("Panel was not opened.").until(isDisplayed.locator(panel));
+ assertEquals(selenium.getElementPositionLeft(panelContainer), 77, "Left margin of the panel");
+ }
+
+ @Test
+ public void testPanelTop() {
+ selenium.click(openButton);
+ waitGui.failWith("Panel was not opened.").until(isDisplayed.locator(panel));
+ assertEquals(selenium.getElementPositionTop(panelContainer), 22, "Top margin of the panel");
+ }
+
+ @Test
+ public void testPanelWidth() {
+ selenium.click(openButton);
+ waitGui.failWith("Panel was not opened.").until(isDisplayed.locator(panel));
+ assertEquals(selenium.getStyle(panelContainer, CssProperty.WIDTH), "543px", "Width of the panel");
+ }
+}
Property changes on: modules/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/richHashParam/TestRichHashParam.java
___________________________________________________________________
Name: svn:keywords
+ Revision
13 years, 11 months
JBoss Rich Faces SVN: r21368 - trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2011-02-01 11:20:31 -0500 (Tue, 01 Feb 2011)
New Revision: 21368
Modified:
trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/ExtendedDataTableRenderer.java
Log:
RF-8685 implement set of event handlers onrow* (onrowmouseover, onrowclick and so on..) for dataTAble and ExtendedDataTable
- added instanceof checking.
Modified: trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/ExtendedDataTableRenderer.java
===================================================================
--- trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/ExtendedDataTableRenderer.java 2011-02-01 16:07:35 UTC (rev 21367)
+++ trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/ExtendedDataTableRenderer.java 2011-02-01 16:20:31 UTC (rev 21368)
@@ -765,7 +765,9 @@
UIDataTableBase table = state.getRow();
writer.startElement(HtmlConstants.TR_ELEMENT, table);
- renderRowHandlers(facesContext, (UIDataTableBase)rowHolder.getRow());
+ if (rowHolder.getRow() instanceof UIDataTableBase) {
+ renderRowHandlers(facesContext, (UIDataTableBase)rowHolder.getRow());
+ }
String rowClass = getRowClass(rowHolder);
if (!"".equals(rowClass)) {
13 years, 11 months
JBoss Rich Faces SVN: r21367 - trunk/ui/output/ui/src/main/java/org/richfaces/renderkit/html.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2011-02-01 11:07:35 -0500 (Tue, 01 Feb 2011)
New Revision: 21367
Modified:
trunk/ui/output/ui/src/main/java/org/richfaces/renderkit/html/TabPanelRenderer.java
Log:
RF-10165
Modified: trunk/ui/output/ui/src/main/java/org/richfaces/renderkit/html/TabPanelRenderer.java
===================================================================
--- trunk/ui/output/ui/src/main/java/org/richfaces/renderkit/html/TabPanelRenderer.java 2011-02-01 16:05:33 UTC (rev 21366)
+++ trunk/ui/output/ui/src/main/java/org/richfaces/renderkit/html/TabPanelRenderer.java 2011-02-01 16:07:35 UTC (rev 21367)
@@ -75,7 +75,6 @@
@Override
protected void doEncodeBegin(ResponseWriter w, FacesContext context, UIComponent component) throws IOException {
super.doEncodeBegin(w, context, component);
- writeJavaScript(w, context, component);
writeTabsLine(w, context, component);
writeTabsLineSeparator(w);
13 years, 11 months
JBoss Rich Faces SVN: r21366 - trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2011-02-01 11:05:33 -0500 (Tue, 01 Feb 2011)
New Revision: 21366
Modified:
trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/AbstractTableBaseRenderer.java
Log:
RF-8685 implement set of event handlers onrow* (onrowmouseover, onrowclick and so on..) for dataTAble and ExtendedDataTable
- added instanceof checking.
Modified: trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/AbstractTableBaseRenderer.java
===================================================================
--- trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/AbstractTableBaseRenderer.java 2011-02-01 15:59:18 UTC (rev 21365)
+++ trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/AbstractTableBaseRenderer.java 2011-02-01 16:05:33 UTC (rev 21366)
@@ -80,7 +80,9 @@
} else {
encodeRowStart(writer, context, parentId, currentRow, component);
}
- renderRowHandlers(context, (UIDataTableBase)rowHolder.getRow());
+ if (rowHolder.getRow() instanceof UIDataTableBase) {
+ renderRowHandlers(context, (UIDataTableBase)rowHolder.getRow());
+ }
rowHolder.setRowStart(false);
}
13 years, 11 months
JBoss Rich Faces SVN: r21365 - trunk/ui/output/ui/src/main/java/org/richfaces/component.
by richfaces-svn-commits@lists.jboss.org
Author: artdaw
Date: 2011-02-01 10:59:18 -0500 (Tue, 01 Feb 2011)
New Revision: 21365
Modified:
trunk/ui/output/ui/src/main/java/org/richfaces/component/AbstractPanelMenuGroup.java
Log:
RF-10318: leftIcon and rightIcon attributes were removed from PanelMenuGroup
Modified: trunk/ui/output/ui/src/main/java/org/richfaces/component/AbstractPanelMenuGroup.java
===================================================================
--- trunk/ui/output/ui/src/main/java/org/richfaces/component/AbstractPanelMenuGroup.java 2011-02-01 15:57:01 UTC (rev 21364)
+++ trunk/ui/output/ui/src/main/java/org/richfaces/component/AbstractPanelMenuGroup.java 2011-02-01 15:59:18 UTC (rev 21365)
@@ -271,6 +271,12 @@
public abstract String getStyle();
+ @Attribute(hidden = true)
+ public abstract String getLeftIcon();
+
+ @Attribute(hidden = true)
+ public abstract String getRightIcon();
+
@Attribute(generate = false)
public String getStyleClass() {
return (String) getStateHelper().eval(Properties.styleClass,
13 years, 11 months
JBoss Rich Faces SVN: r21364 - trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2011-02-01 10:57:01 -0500 (Tue, 01 Feb 2011)
New Revision: 21364
Modified:
trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/AbstractRowsRenderer.java
Log:
RF-10380 rich:extendedDataTable - @rowClass doesn't work
Modified: trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/AbstractRowsRenderer.java
===================================================================
--- trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/AbstractRowsRenderer.java 2011-02-01 15:49:12 UTC (rev 21363)
+++ trunk/ui/iteration/ui/src/main/java/org/richfaces/renderkit/AbstractRowsRenderer.java 2011-02-01 15:57:01 UTC (rev 21364)
@@ -173,6 +173,14 @@
return styleClass;
}
+ protected String getRowClassAttribute(RowHolderBase rowHolder) {
+ String rowClass = "";
+ if (rowHolder.getRow() instanceof UIDataTableBase) {
+ rowClass = ((UIDataTableBase)rowHolder.getRow()).getRowClass();
+ }
+ return rowClass;
+ }
+
protected String getRowClass(RowHolderBase rowHolder) {
String styleClass = "";
String[] rowClasses = getRowClasses(rowHolder);
@@ -180,6 +188,6 @@
int styleIndex = rowHolder.getCurrentRow() % rowClasses.length;
styleClass = rowClasses[styleIndex];
}
- return styleClass;
+ return concatClasses(getRowClassAttribute(rowHolder), styleClass);
}
}
13 years, 11 months