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/10/27 15:13:57 UTC

svn commit: r1766842 - in /myfaces/tobago/trunk: tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/ tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/component/ tobago-core/src/test/java/org/apache/myfaces/tobago/component/...

Author: lofwyr
Date: Thu Oct 27 15:13:57 2016
New Revision: 1766842

URL: http://svn.apache.org/viewvc?rev=1766842&view=rev
Log:
TOBAGO-1485 Label support of the tc-library, so the tx-tibrary will be unnecessary (and removed)
-> TOBAGO-1613 remove tx-library

Removed:
    myfaces/tobago/trunk/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/component/ExtensionPanelDeclaration.java
Modified:
    myfaces/tobago/trunk/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/GridLayoutConstraintHandler.java
    myfaces/tobago/trunk/tobago-core/src/test/java/org/apache/myfaces/tobago/component/MethodOverwritingOfGeneratedUIComponentsUnitTest.java
    myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SegmentLayoutRenderer.java
    myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/CheckstyleConfigGenerator.java
    myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/TaglibGenerator.java

Modified: myfaces/tobago/trunk/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/GridLayoutConstraintHandler.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/GridLayoutConstraintHandler.java?rev=1766842&r1=1766841&r2=1766842&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/GridLayoutConstraintHandler.java (original)
+++ myfaces/tobago/trunk/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/GridLayoutConstraintHandler.java Thu Oct 27 15:13:57 2016
@@ -20,7 +20,6 @@
 package org.apache.myfaces.tobago.facelets;
 
 import org.apache.myfaces.tobago.component.Attributes;
-import org.apache.myfaces.tobago.component.UIExtensionPanel;
 
 import javax.faces.component.UIComponent;
 import javax.faces.view.facelets.FaceletContext;
@@ -48,12 +47,6 @@ public class GridLayoutConstraintHandler
   @Override
   public void apply(final FaceletContext faceletContext, UIComponent parent) throws IOException {
     final Map<String, Object> attributes = parent.getAttributes();
-    if (parent.getParent() != null && parent.getParent() instanceof UIExtensionPanel) {
-      parent = parent.getParent();
-    } else if (attributes.get("tobago.panel") != null
-        && attributes.get("tobago.panel") instanceof UIExtensionPanel) {
-      parent = (UIComponent) attributes.get("tobago.panel");
-    }
 
     if (columnSpan != null) {
       if (columnSpan.isLiteral()) {

Modified: myfaces/tobago/trunk/tobago-core/src/test/java/org/apache/myfaces/tobago/component/MethodOverwritingOfGeneratedUIComponentsUnitTest.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-core/src/test/java/org/apache/myfaces/tobago/component/MethodOverwritingOfGeneratedUIComponentsUnitTest.java?rev=1766842&r1=1766841&r2=1766842&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-core/src/test/java/org/apache/myfaces/tobago/component/MethodOverwritingOfGeneratedUIComponentsUnitTest.java (original)
+++ myfaces/tobago/trunk/tobago-core/src/test/java/org/apache/myfaces/tobago/component/MethodOverwritingOfGeneratedUIComponentsUnitTest.java Thu Oct 27 15:13:57 2016
@@ -39,7 +39,6 @@ public class MethodOverwritingOfGenerate
 
   private static final List<String> IGNORED_METHODS = Arrays.asList("getFamily", "saveState", "restoreState");
   private static final List<String> IGNORED_COMPONENTS = Arrays.asList(
-      UIExtensionPanel.class.getSimpleName(),
       UIMenuSelectOne.class.getSimpleName());
   private static final MethodOfComponentList IGNORED_METHODS_PER_COMPONENT = new MethodOfComponentList();
 

Modified: myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SegmentLayoutRenderer.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/SegmentLayoutRenderer.java?rev=1766842&r1=1766841&r2=1766842&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SegmentLayoutRenderer.java (original)
+++ myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SegmentLayoutRenderer.java Thu Oct 27 15:13:57 2016
@@ -21,7 +21,6 @@ package org.apache.myfaces.tobago.render
 
 import org.apache.myfaces.tobago.component.LabelLayout;
 import org.apache.myfaces.tobago.component.SupportsLabelLayout;
-import org.apache.myfaces.tobago.component.UIExtensionPanel;
 import org.apache.myfaces.tobago.component.UISegmentLayout;
 import org.apache.myfaces.tobago.internal.component.AbstractUISegmentLayout;
 import org.apache.myfaces.tobago.renderkit.RendererBase;
@@ -79,13 +78,7 @@ public class SegmentLayoutRenderer exten
         segmentLayout.getLarge());
     for (UIComponent child : children) {
       if (child.isRendered()) {
-        if (child instanceof UIExtensionPanel) {
-          for (UIComponent subChild : child.getChildren()) {
-            encodeChild(facesContext, writer, generator, subChild);
-          }
-        } else {
-          encodeChild(facesContext, writer, generator, child);
-        }
+        encodeChild(facesContext, writer, generator, child);
       }
     }
   }

Modified: myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/CheckstyleConfigGenerator.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/CheckstyleConfigGenerator.java?rev=1766842&r1=1766841&r2=1766842&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/CheckstyleConfigGenerator.java (original)
+++ myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/CheckstyleConfigGenerator.java Thu Oct 27 15:13:57 2016
@@ -23,7 +23,6 @@ package org.apache.myfaces.tobago.apt.pr
 import org.apache.commons.io.IOUtils;
 import org.apache.commons.lang.StringUtils;
 import org.apache.myfaces.tobago.apt.AnnotationUtils;
-import org.apache.myfaces.tobago.apt.annotation.ExtensionTag;
 import org.apache.myfaces.tobago.apt.annotation.SimpleTag;
 import org.apache.myfaces.tobago.apt.annotation.Tag;
 import org.apache.myfaces.tobago.apt.annotation.TagAttribute;
@@ -151,8 +150,6 @@ public class CheckstyleConfigGenerator e
       final String className;
       if (typeElement.getAnnotation(SimpleTag.class) != null || typeElement.getAnnotation(ValidatorTag.class) != null) {
         className = AnnotationUtils.generatedTagName(typeElement);
-      } else if (typeElement.getAnnotation(ExtensionTag.class) != null) {
-        className = typeElement.getQualifiedName().toString();
       } else if (typeElement.getAnnotation(UIComponentTag.class) != null) {
         className = "org.apache.myfaces.tobago.internal.taglib." + StringUtils.capitalize(annotationTag.name())
             + "Tag";

Modified: myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/TaglibGenerator.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/TaglibGenerator.java?rev=1766842&r1=1766841&r2=1766842&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/TaglibGenerator.java (original)
+++ myfaces/tobago/trunk/tobago-tool/tobago-tool-apt/src/main/java/org/apache/myfaces/tobago/apt/processor/TaglibGenerator.java Thu Oct 27 15:13:57 2016
@@ -22,7 +22,6 @@ package org.apache.myfaces.tobago.apt.pr
 import org.apache.commons.io.IOUtils;
 import org.apache.commons.lang.StringUtils;
 import org.apache.myfaces.tobago.apt.AnnotationUtils;
-import org.apache.myfaces.tobago.apt.annotation.ExtensionTag;
 import org.apache.myfaces.tobago.apt.annotation.Facet;
 import org.apache.myfaces.tobago.apt.annotation.Preliminary;
 import org.apache.myfaces.tobago.apt.annotation.SimpleTag;
@@ -301,21 +300,6 @@ public class TaglibGenerator extends Abs
             .append("</code>");
       }
     }
-    final ExtensionTag extensionTag = typeElement.getAnnotation(ExtensionTag.class);
-    if (extensionTag != null) {
-      final String baseName = extensionTag.baseClassName();
-      description.append("<p><b>Extended tag: </b>");
-      description.append(baseName);
-      description.append("</p>");
-
-      final TypeElement declaration = getInterfaceDeclaration(baseName + "Declaration");
-      if (declaration != null) {
-        final UIComponentTag baseComponentTag = declaration.getAnnotation(UIComponentTag.class);
-        if (baseComponentTag != null) {
-          description.append(createDescription(baseComponentTag));
-        }
-      }
-    }
     if (description.length() > 0) {
       addLeafCDATAElement(description.toString(), "description", element, document);
     }
@@ -486,15 +470,6 @@ public class TaglibGenerator extends Abs
       addLeafTextElement(componentTag.faceletHandler(), "handler-class", componentElement, document);
     }
 
-    final ExtensionTag extensionTag = typeElement.getAnnotation(ExtensionTag.class);
-    if (extensionTag != null) {
-      final Element componentElement = document.createElement("component");
-      tagElement.appendChild(componentElement);
-      addLeafTextElement(extensionTag.componentType(), "component-type", componentElement, document);
-      addLeafTextElement(extensionTag.rendererType(), "renderer-type", componentElement, document);
-      addLeafTextElement(extensionTag.faceletHandler(), "handler-class", componentElement, document);
-    }
-
     final SimpleTag simpleTag = typeElement.getAnnotation(SimpleTag.class);
     if (simpleTag != null) {
       addLeafTextElement(simpleTag.faceletHandler(), "handler-class", tagElement, document);