You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lo...@apache.org on 2016/07/07 09:24:13 UTC
svn commit: r1751765 -
/myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SheetRenderer.java
Author: lofwyr
Date: Thu Jul 7 09:24:13 2016
New Revision: 1751765
URL: http://svn.apache.org/viewvc?rev=1751765&view=rev
Log:
simplify code
Modified:
myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SheetRenderer.java
Modified: myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SheetRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SheetRenderer.java?rev=1751765&r1=1751764&r2=1751765&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SheetRenderer.java (original)
+++ myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SheetRenderer.java Thu Jul 7 09:24:13 2016
@@ -1149,17 +1149,15 @@ public class SheetRenderer extends Rende
final UISheet sheet, final FacesContext facesContext, final TobagoResponseWriter writer) throws IOException {
CommandMap commandMap = null;
for (final UIComponent child : sheet.getChildren()) {
- if (child instanceof UIColumnEvent) {
+ if (child instanceof UIColumnEvent && child.isRendered()) {
final UIColumnEvent columnEvent = (UIColumnEvent) child;
- if (columnEvent.isRendered()) {
- final UIComponent selectionChild = child.getChildren().get(0);
- if (selectionChild != null && selectionChild instanceof AbstractUICommand && selectionChild.isRendered()) {
- final UICommand action = (UICommand) selectionChild;
- if (commandMap == null) {
- commandMap = new CommandMap();
- }
- commandMap.addCommand(columnEvent.getEvent(), new Command(facesContext, action, (String) null));
+ final UIComponent selectionChild = child.getChildren().get(0);
+ if (selectionChild != null && selectionChild instanceof AbstractUICommand && selectionChild.isRendered()) {
+ final UICommand action = (UICommand) selectionChild;
+ if (commandMap == null) {
+ commandMap = new CommandMap();
}
+ commandMap.addCommand(columnEvent.getEvent(), new Command(facesContext, action, (String) null));
}
}
}