You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by we...@apache.org on 2020/12/11 07:54:15 UTC

[myfaces-tobago] branch TOBAGO-1999_Select2 updated (49a4dd4 -> 723c29f)

This is an automated email from the ASF dual-hosted git repository.

weber pushed a change to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git.


    from 49a4dd4  TOBAGO-2052 - <tc:toolBarCommand> doesn't support markup-attribute
     new b01df37  add a Jenkinsfile
     new bc0561d  update ant because of CVE-2020-1945
     new 597a2ed  there is no tomcat profile
     new 9012969  Tobago 2 officially supports Java 5, but Java 11 compiles no target for Java 5
     new a9211fc  update dependency-check
     new fad377d  check if tools.jar is needed with JDK 1.8 (and higher)
     new a15f649  docs
     new 29e5345  check if tools.jar is needed with JDK 1.8 (and higher)
     new 23cc13e  e-mail notifications sync structure of file with master
     new 2539e05  fix rat check
     new c8b5dd1  fix rat check
     new b5d78d0  fix CVE
     new cdb9ac6  TOBAGO-2054 - tc:object: sandbox attribute
     new 62f2b05  Tobago-1999: fix NPE
     new d938985  TOBAGO-703 - sheet paging should adjust scroll position
     new 5cfaa12  TOBAGO-703 - sheet paging should adjust scroll position
     new 87eb52e  fix NPE after TOBAGO-703 - sheet paging should adjust scroll position
     new 5d5503a  fix CVE: update ant to 1.10.9
     new 66d96a3  Jenkins properties has been renamed on ci-builds.apache.org
     new c062a7c  Update Myfaces to 2.3.7 after its release
     new 83918be  Update batik dependency from 1.9 to 1.13, because of CVE-2019-17566
     new 723c29f  TOBAGO-2061: Window Scope broken

The 22 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 Jenkinsfile                                        | 151 +++++
 pom.xml                                            |  12 +-
 readme.txt                                         |   2 +-
 tobago-core/pom.xml                                |  17 -
 .../myfaces/tobago/facelets/SelectManyBoxRule.java |  13 +-
 .../extension/TobagoLabelExtensionHandler.java     |   5 +
 .../component/AbstractUISelectManyBox.java         |   6 +-
 .../tobago/internal/component/AbstractUISheet.java |  11 +-
 .../taglib/component/ObjectTagDeclaration.java     |   7 +
 .../extension/SelectManyBoxExtensionTag.java       | 507 ++++++++++------
 .../internal/util/UISelect2ComponentUtil.java      |   5 +-
 .../tobago/renderkit/html/HtmlAttributes.java      |   1 +
 .../tobago-example-addressbook-cdi/pom.xml         |   4 +-
 tobago-example/tobago-example-demo/pom.xml         |   4 +-
 tobago-example/tobago-example-test/pom.xml         |   6 +-
 tobago-extension/tobago-fileupload/pom.xml         |   6 -
 tobago-extension/tobago-sandbox/pom.xml            |  17 -
 tobago-theme/tobago-theme-charlotteville/pom.xml   |   6 -
 tobago-theme/tobago-theme-richmond/pom.xml         |   6 -
 tobago-theme/tobago-theme-scarborough/pom.xml      |   6 -
 tobago-theme/tobago-theme-speyside/pom.xml         |   6 -
 tobago-theme/tobago-theme-standard/pom.xml         |   8 +-
 .../html/standard/standard/tag/ObjectRenderer.java |   5 +
 .../src/main/resources/META-INF/tobago-config.xml  |   1 +
 .../standard/standard/script/tobago-deltaspike.js  | 671 +++++++++++++++++++++
 .../html/standard/standard/script/tobago.js        |  46 --
 tobago-tool/tobago-tool-annotation/pom.xml         |  20 -
 tobago-tool/tobago-tool-apt/pom.xml                |  31 +-
 28 files changed, 1223 insertions(+), 357 deletions(-)
 create mode 100644 Jenkinsfile
 create mode 100644 tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-deltaspike.js


[myfaces-tobago] 13/22: TOBAGO-2054 - tc:object: sandbox attribute

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit cdb9ac6adbb621c28dae2a4a6d0ce8dcae7e53b0
Author: Volker Weber <v....@inexso.de>
AuthorDate: Tue Sep 15 09:08:06 2020 +0200

    TOBAGO-2054 - tc:object: sandbox attribute
---
 .../tobago/internal/taglib/component/ObjectTagDeclaration.java     | 7 +++++++
 .../org/apache/myfaces/tobago/renderkit/html/HtmlAttributes.java   | 1 +
 .../renderkit/html/standard/standard/tag/ObjectRenderer.java       | 5 +++++
 3 files changed, 13 insertions(+)

diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/component/ObjectTagDeclaration.java b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/component/ObjectTagDeclaration.java
index b8488d7..d47be20 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/component/ObjectTagDeclaration.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/component/ObjectTagDeclaration.java
@@ -61,4 +61,11 @@ public interface ObjectTagDeclaration extends HasIdBindingAndRendered, IsGridLay
   @TagAttribute
   @UIComponentTagAttribute
   void setName(String name);
+
+  /**
+   * Value of the iframe sandbox attribute.
+   */
+  @TagAttribute
+  @UIComponentTagAttribute
+  void setSandbox(String sandbox);
 }
diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/html/HtmlAttributes.java b/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/html/HtmlAttributes.java
index 73a2e4f..7d6a041 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/html/HtmlAttributes.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/html/HtmlAttributes.java
@@ -95,6 +95,7 @@ public final class HtmlAttributes {
   public static final String ROLE = "role";
   public static final String ROWS = "rows";
   public static final String ROWSPAN = "rowspan";
+  public static final String SANDBOX = "sandbox";
   public static final String SCROLL = "scroll";
   public static final String SELECTED = "selected";
   public static final String SIZE = "size";
diff --git a/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/ObjectRenderer.java b/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/ObjectRenderer.java
index 0c4aaef..305e9ba 100644
--- a/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/ObjectRenderer.java
+++ b/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/ObjectRenderer.java
@@ -58,6 +58,11 @@ public class ObjectRenderer extends LayoutComponentRendererBase {
     final Style style = new Style(facesContext, object);
     writer.writeStyleAttribute(style);
 
+    String sandbox = object.getSandbox();
+    if (sandbox != null) {
+      writer.writeAttribute(HtmlAttributes.SANDBOX, sandbox, false);
+    }
+
     String noframes = ResourceManagerUtils.getPropertyNotNull(
         facesContext, "tobago", "browser.noframe.message.prefix");
     writer.writeText(noframes);


[myfaces-tobago] 05/22: update dependency-check

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit a9211fc834bb4eacea7d744ff86da47e7ec8fb40
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Wed Aug 26 19:51:48 2020 +0200

    update dependency-check
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index f1a50ce..3f9a88c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -1029,7 +1029,7 @@
         <plugin>
           <groupId>org.owasp</groupId>
           <artifactId>dependency-check-maven</artifactId>
-          <version>5.2.2</version>
+          <version>5.2.4</version>
           <configuration>
             <failBuildOnCVSS>0</failBuildOnCVSS>
             <suppressionFile>tobago/dependency-check-suppression-for-tobago-2.x.xml</suppressionFile>


[myfaces-tobago] 18/22: fix CVE: update ant to 1.10.9

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 5d5503ad3985ab184c7d5133d6c32938caf11d7b
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Thu Oct 15 11:55:42 2020 +0200

    fix CVE: update ant to 1.10.9
    
    ant-1.10.8.jar: CVE-2020-11979
---
 tobago-tool/tobago-tool-apt/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tobago-tool/tobago-tool-apt/pom.xml b/tobago-tool/tobago-tool-apt/pom.xml
index de39320..2827ed7 100644
--- a/tobago-tool/tobago-tool-apt/pom.xml
+++ b/tobago-tool/tobago-tool-apt/pom.xml
@@ -57,7 +57,7 @@
     <dependency>
       <groupId>org.apache.ant</groupId>
       <artifactId>ant</artifactId>
-      <version>1.10.8</version>
+      <version>1.10.9</version>
       <scope>compile</scope>
       <exclusions>
         <exclusion>


[myfaces-tobago] 17/22: fix NPE after TOBAGO-703 - sheet paging should adjust scroll position

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 87eb52e25c669de0944d3b2f0391dc7e948ba0aa
Author: Volker Weber <v....@inexso.de>
AuthorDate: Wed Oct 7 09:45:30 2020 +0200

    fix NPE after TOBAGO-703 - sheet paging should adjust scroll position
---
 .../org/apache/myfaces/tobago/internal/component/AbstractUISheet.java  | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISheet.java b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISheet.java
index 10cbd40..9a2291d 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISheet.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISheet.java
@@ -541,6 +541,9 @@ public abstract class AbstractUISheet extends AbstractUIData
     }
 
     Integer[] scrollPosition = getScrollPosition();
+    if (scrollPosition == null) {
+      scrollPosition = new Integer[] {0, 0};
+    }
     scrollPosition[1] = 0;
     switch (pageEvent.getAction()) {
       case FIRST:


[myfaces-tobago] 12/22: fix CVE

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit b5d78d00e81d7a08bd3702c2db213e0168c4cae8
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Thu Aug 27 09:49:45 2020 +0200

    fix CVE
    
    upgrade deltaspike (needs upgrade of owb)
    upgrade log4j
---
 pom.xml                                               | 2 +-
 tobago-example/tobago-example-addressbook-cdi/pom.xml | 4 ++--
 tobago-example/tobago-example-demo/pom.xml            | 4 ++--
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/pom.xml b/pom.xml
index 468ea98..0cd41ff 100644
--- a/pom.xml
+++ b/pom.xml
@@ -44,7 +44,7 @@
     <mojarra22.version>2.2.16</mojarra22.version>
     <slf4j.version>1.7.30</slf4j.version>
     <logback.version>1.2.3</logback.version>
-    <log4j.version>2.13.0</log4j.version>
+    <log4j.version>2.13.3</log4j.version>
     <commons-io.version>2.4</commons-io.version>
     <commons-lang.version>2.6</commons-lang.version>
     <commons-logging.version>1.1.1</commons-logging.version>
diff --git a/tobago-example/tobago-example-addressbook-cdi/pom.xml b/tobago-example/tobago-example-addressbook-cdi/pom.xml
index 4ebed0f..e013f8a 100644
--- a/tobago-example/tobago-example-addressbook-cdi/pom.xml
+++ b/tobago-example/tobago-example-addressbook-cdi/pom.xml
@@ -29,8 +29,8 @@
 
   <properties>
     <openjpa.version>1.2.3</openjpa.version>
-    <openwebbeans.version>1.1.7</openwebbeans.version>
-    <deltaspike.version>1.3.0</deltaspike.version>
+    <openwebbeans.version>1.2.8</openwebbeans.version>
+    <deltaspike.version>1.9.4</deltaspike.version>
     <tobago.basedir>${project.basedir}/../..</tobago.basedir>
   </properties>
   <build>
diff --git a/tobago-example/tobago-example-demo/pom.xml b/tobago-example/tobago-example-demo/pom.xml
index dff56ed..dc28c09 100644
--- a/tobago-example/tobago-example-demo/pom.xml
+++ b/tobago-example/tobago-example-demo/pom.xml
@@ -28,8 +28,8 @@
   <description>Demonstration and documentation application.</description>
 
   <properties>
-    <openwebbeans.version>1.1.7</openwebbeans.version>
-    <deltaspike.version>1.5.2</deltaspike.version>
+    <openwebbeans.version>1.2.8</openwebbeans.version>
+    <deltaspike.version>1.9.4</deltaspike.version>
     <tobago.basedir>${project.basedir}/../..</tobago.basedir>
   </properties>
   <build>


[myfaces-tobago] 01/22: add a Jenkinsfile

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit b01df3738a45ae6cba03e261fa5c5d5741eb338d
Author: Dennis Kieselhorst <ma...@dekies.de>
AuthorDate: Sun Aug 16 21:08:44 2020 +0200

    add a Jenkinsfile
    
    (cherry picked from commit fd0f531741a1e9cc4d5a1e3980d892fefe0420d0)
---
 Jenkinsfile | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 72 insertions(+)

diff --git a/Jenkinsfile b/Jenkinsfile
new file mode 100644
index 0000000..b02bef2
--- /dev/null
+++ b/Jenkinsfile
@@ -0,0 +1,72 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+pipeline {
+    agent {
+        label 'ubuntu'
+    }
+
+    options {
+        disableConcurrentBuilds()
+        buildDiscarder(logRotator(numToKeepStr: '5'))
+        timeout(time: 2, unit: 'HOURS')
+        timestamps()
+        quietPeriod(30)
+    }
+
+    triggers {
+        cron('@daily')
+        pollSCM('@hourly')
+    }
+
+    stages {
+        stage('Prepare') {
+            matrix {
+                agent {
+                  label 'ubuntu'
+                }
+                axes {
+                    axis {
+                        name 'JAVA_VERSION'
+                        values 'JDK 1.8 (latest)', 'JDK 11 (latest)'
+                    }
+                }
+
+                tools {
+                    maven "Maven (latest)"
+                    jdk "${JAVA_VERSION}"
+                }
+
+                stages {
+                    stage('BuildAndTest') {
+                        steps {
+                            sh "mvn clean deploy checkstyle:check apache-rat:check animal-sniffer:check dependency-check:check  -Pgenerate-assembly -Ptomcat"
+                        }
+                        post {
+                            always {
+                               junit(testResults: '**/surefire-reports/*.xml', allowEmptyResults: true)
+                               junit(testResults: '**/failsafe-reports/*.xml', allowEmptyResults: true)
+                               archiveArtifacts '**/target/*.jar'
+                            }
+                        }
+                    }
+                }
+            }
+        }
+    }
+}
\ No newline at end of file


[myfaces-tobago] 03/22: there is no tomcat profile

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 597a2ed96e689014e265a4d10716ab0990725c76
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Wed Aug 26 18:57:54 2020 +0200

    there is no tomcat profile
---
 Jenkinsfile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index b02bef2..8929f7f 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -55,7 +55,7 @@ pipeline {
                 stages {
                     stage('BuildAndTest') {
                         steps {
-                            sh "mvn clean deploy checkstyle:check apache-rat:check animal-sniffer:check dependency-check:check  -Pgenerate-assembly -Ptomcat"
+                            sh "mvn clean deploy checkstyle:check apache-rat:check animal-sniffer:check dependency-check:check -Pgenerate-assembly"
                         }
                         post {
                             always {


[myfaces-tobago] 14/22: Tobago-1999: fix NPE

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 62f2b05c3bf13b2f0b47dd6d643d95783cb25b41
Author: Volker Weber <v....@inexso.de>
AuthorDate: Tue Sep 15 10:48:14 2020 +0200

    Tobago-1999: fix NPE
---
 .../apache/myfaces/tobago/internal/util/UISelect2ComponentUtil.java  | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/util/UISelect2ComponentUtil.java b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/util/UISelect2ComponentUtil.java
index de43bd7..8e69752 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/util/UISelect2ComponentUtil.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/util/UISelect2ComponentUtil.java
@@ -144,10 +144,11 @@ public class UISelect2ComponentUtil {
     Map<String, javax.faces.model.SelectItem> optionValues = new HashMap<String, javax.faces.model.SelectItem>();
     for (javax.faces.model.SelectItem item : items) {
       itemsToRender.add(item);
+      Object itemValue = item.getValue();
       if (converter != null) {
-        optionValues.put(converter.getAsString(facesContext, component, item.getValue()), item);
+        optionValues.put(converter.getAsString(facesContext, component, itemValue), item);
       } else {
-        optionValues.put(item.getValue().toString(), item);
+        optionValues.put(itemValue != null ? itemValue.toString() : null, item);
       }
     }
 


[myfaces-tobago] 19/22: Jenkins properties has been renamed on ci-builds.apache.org

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 66d96a31bd1b2e9ac73c952f6e018defa9459727
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Wed Oct 21 12:00:04 2020 +0200

    Jenkins properties has been renamed on ci-builds.apache.org
    
    (cherry picked from commit b0c2e5a893d13ee95dd0ed73179220d0989d4e1f)
---
 Jenkinsfile | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index 204daa9..0bcb980 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -43,12 +43,12 @@ pipeline {
                 axes {
                     axis {
                         name 'JAVA_VERSION'
-                        values 'JDK 1.8 (latest)'  /*, 'JDK 11 (latest)'  Tobago 2 officially supports Java 5, but Java 11 compiles no target for Java 5  */
+                        values 'jdk_1.8_latest'  /*, 'JDK 11 (latest)'  Tobago 2 officially supports Java 5, but Java 11 compiles no target for Java 5  */
                     }
                 }
 
                 tools {
-                    maven "Maven (latest)"
+                    maven "maven_latest"
                     jdk "${JAVA_VERSION}"
                 }
 
@@ -70,8 +70,8 @@ pipeline {
         }
         stage('Deploy') {
             tools {
-                maven "Maven (latest)"
-                jdk "JDK 1.8 (latest)"
+                maven "maven_latest"
+                jdk "jdk_1.8_latest"
             }
             steps {
                 sh "mvn clean deploy -Pgenerate-assembly"
@@ -147,5 +147,5 @@ Director of Continuous Integration
         )
       }
     }
-    }
+  }
 }
\ No newline at end of file


[myfaces-tobago] 04/22: Tobago 2 officially supports Java 5, but Java 11 compiles no target for Java 5

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 901296910e8c46c4e02d488109c958e77a42bb97
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Wed Aug 26 19:06:44 2020 +0200

    Tobago 2 officially supports Java 5, but Java 11 compiles no target for Java 5
---
 Jenkinsfile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index 8929f7f..bce0602 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -43,7 +43,7 @@ pipeline {
                 axes {
                     axis {
                         name 'JAVA_VERSION'
-                        values 'JDK 1.8 (latest)', 'JDK 11 (latest)'
+                        values 'JDK 1.8 (latest)'  /*, 'JDK 11 (latest)'  Tobago 2 officially supports Java 5, but Java 11 compiles no target for Java 5  */
                     }
                 }
 


[myfaces-tobago] 15/22: TOBAGO-703 - sheet paging should adjust scroll position

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit d938985c72bb47916065a9a45acd3d0f87140508
Author: Volker Weber <v....@inexso.de>
AuthorDate: Tue Sep 15 14:27:16 2020 +0200

    TOBAGO-703 - sheet paging should adjust scroll position
---
 .../apache/myfaces/tobago/internal/component/AbstractUISheet.java | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISheet.java b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISheet.java
index 5c34b9c..10cbd40 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISheet.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISheet.java
@@ -540,6 +540,8 @@ public abstract class AbstractUISheet extends AbstractUIData
       LOG.debug("action = '" + pageEvent.getAction().name() + "'");
     }
 
+    Integer[] scrollPosition = getScrollPosition();
+    scrollPosition[1] = 0;
     switch (pageEvent.getAction()) {
       case FIRST:
         first = 0;
@@ -547,6 +549,7 @@ public abstract class AbstractUISheet extends AbstractUIData
       case PREV:
         first = getFirst() - getRows();
         first = first < 0 ? 0 : first;
+        scrollPosition[1] = Integer.MAX_VALUE;
         break;
       case NEXT:
         if (hasRowCount()) {
@@ -592,7 +595,10 @@ public abstract class AbstractUISheet extends AbstractUIData
       setFirst(first);
     }
 
-    getState().setFirst(first);
+    SheetState sheetState = getState();
+    sheetState.setFirst(first);
+    getAttributes().put(Attributes.SCROLL_POSITION, scrollPosition);
+    sheetState.setScrollPosition(scrollPosition);
 //      sheet.queueEvent(new SheetStateChangeEvent(sheet));
   }
 


[myfaces-tobago] 02/22: update ant because of CVE-2020-1945

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit bc0561d1cdde6369ddd04218b204e34c26b2127f
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Wed Aug 26 18:22:37 2020 +0200

    update ant because of CVE-2020-1945
---
 tobago-tool/tobago-tool-apt/pom.xml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tobago-tool/tobago-tool-apt/pom.xml b/tobago-tool/tobago-tool-apt/pom.xml
index 4fac30f..972b302 100644
--- a/tobago-tool/tobago-tool-apt/pom.xml
+++ b/tobago-tool/tobago-tool-apt/pom.xml
@@ -55,9 +55,9 @@
       <scope>provided</scope>
     </dependency>
     <dependency>
-      <groupId>ant</groupId>
+      <groupId>org.apache.ant</groupId>
       <artifactId>ant</artifactId>
-      <version>1.6.2</version>
+      <version>1.10.8</version>
       <scope>compile</scope>
     </dependency>
     <dependency>


[myfaces-tobago] 11/22: fix rat check

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit c8b5dd11410bf2d769fd5b85a31278fda4a34a94
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Thu Aug 27 08:53:13 2020 +0200

    fix rat check
---
 pom.xml | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/pom.xml b/pom.xml
index c964965..468ea98 100644
--- a/pom.xml
+++ b/pom.xml
@@ -995,6 +995,9 @@
 
               <!-- pixelmator -->
               <exclude>**/*.pxm</exclude>
+
+              <!-- jetty key store for testing -->
+              <exclude>**/jettykeystore</exclude>
             </excludes>
           </configuration>
         </plugin>


[myfaces-tobago] 20/22: Update Myfaces to 2.3.7 after its release

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit c062a7c201e9f4c0b29a422d10b5b0afff4306ee
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Mon Nov 9 17:33:31 2020 +0100

    Update Myfaces to 2.3.7 after its release
    
    (cherry picked from commit 9736b8d38aa7d4ce428633e2d29bda370cba85a2)
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index 0cd41ff..0a10200 100644
--- a/pom.xml
+++ b/pom.xml
@@ -38,7 +38,7 @@
     <myfaces20.version>2.0.24</myfaces20.version>
     <myfaces21.version>2.1.18</myfaces21.version>
     <myfaces22.version>2.2.13</myfaces22.version>
-    <myfaces23.version>2.3.6</myfaces23.version>
+    <myfaces23.version>2.3.7</myfaces23.version>
     <mojarra20.version>2.0.11-04</mojarra20.version>
     <mojarra21.version>2.1.29-08</mojarra21.version>
     <mojarra22.version>2.2.16</mojarra22.version>


[myfaces-tobago] 08/22: check if tools.jar is needed with JDK 1.8 (and higher)

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 29e5345e083dcd9079b2696d325a2c3a2e952cf1
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Wed Aug 26 20:54:08 2020 +0200

    check if tools.jar is needed with JDK 1.8 (and higher)
---
 tobago-tool/tobago-tool-apt/pom.xml | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/tobago-tool/tobago-tool-apt/pom.xml b/tobago-tool/tobago-tool-apt/pom.xml
index 7bbc4ac..de39320 100644
--- a/tobago-tool/tobago-tool-apt/pom.xml
+++ b/tobago-tool/tobago-tool-apt/pom.xml
@@ -59,6 +59,12 @@
       <artifactId>ant</artifactId>
       <version>1.10.8</version>
       <scope>compile</scope>
+      <exclusions>
+        <exclusion>
+          <groupId>com.sun</groupId>
+          <artifactId>tools</artifactId>
+        </exclusion>
+      </exclusions>
     </dependency>
     <dependency>
       <groupId>commons-io</groupId>


[myfaces-tobago] 22/22: TOBAGO-2061: Window Scope broken

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 723c29ff0a6d717aaf969847dd7076c29ef97f3c
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Fri Dec 4 17:33:06 2020 +0100

    TOBAGO-2061: Window Scope broken
    
    * migrating the script part
---
 tobago-theme/tobago-theme-standard/pom.xml         |   2 +-
 .../src/main/resources/META-INF/tobago-config.xml  |   1 +
 .../standard/standard/script/tobago-deltaspike.js  | 671 +++++++++++++++++++++
 .../html/standard/standard/script/tobago.js        |  46 --
 4 files changed, 673 insertions(+), 47 deletions(-)

diff --git a/tobago-theme/tobago-theme-standard/pom.xml b/tobago-theme/tobago-theme-standard/pom.xml
index 7871f60..b2ca041 100644
--- a/tobago-theme/tobago-theme-standard/pom.xml
+++ b/tobago-theme/tobago-theme-standard/pom.xml
@@ -41,7 +41,7 @@
               <target>
                 <concat destfile="${project.build.directory}/javascript-min/standard/script/tobago.min.js" force="no">
                   <filelist dir="${basedir}/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script"
-                            files="tobago.js,tobago-calendar.js,tobago-converter.js,tobago-in.js,tobago-menu.js,tobago-overlay.js,tobago-popup.js,tobago-select2.js,tobago-sheet.js,tobago-suggest.js,tobago-tab.js,tobago-tree.js,tobago-utils.js,tobago-file.js" />
+                            files="tobago.js,tobago-calendar.js,tobago-converter.js,tobago-deltaspike.js,tobago-in.js,tobago-menu.js,tobago-overlay.js,tobago-popup.js,tobago-select2.js,tobago-sheet.js,tobago-suggest.js,tobago-tab.js,tobago-tree.js,tobago-utils.js,tobago-file.js" />
                 </concat>
                 <concat destfile="${project.build.directory}/javascript-min/msie_6_0/script/tobago.min.js" force="no">
                   <filelist dir="${basedir}/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/msie_6_0/script" files="tobago.js" />
diff --git a/tobago-theme/tobago-theme-standard/src/main/resources/META-INF/tobago-config.xml b/tobago-theme/tobago-theme-standard/src/main/resources/META-INF/tobago-config.xml
index 4e875e7..bb1a62f 100644
--- a/tobago-theme/tobago-theme-standard/src/main/resources/META-INF/tobago-config.xml
+++ b/tobago-theme/tobago-theme-standard/src/main/resources/META-INF/tobago-config.xml
@@ -420,6 +420,7 @@
         <script priority="50" name="script/tobago-calendar.js"/>
         <script priority="60" name="script/tobago-console.js"/>
         <script priority="70" name="script/tobago-converter.js"/>
+        <script priority="75" name="script/tobago-deltaspike.js"/>
         <script priority="80" name="script/tobago-file.js"/>
         <script priority="90" name="script/tobago-in.js"/>
         <script priority="100" name="script/tobago-menu.js"/>
diff --git a/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-deltaspike.js b/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-deltaspike.js
new file mode 100644
index 0000000..876a3c3
--- /dev/null
+++ b/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-deltaspike.js
@@ -0,0 +1,671 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+jQuery(document).ready(function() {
+  var dswid = location.search.replace(/.*dswid=(\-?[0-9]+).*/, "$1");
+  if (dswid) {
+    dswh.init(dswid, 'LAZY', 10, {
+      'tokenizedRedirect': false,
+      'storeWindowTreeOnLinkClick': true,
+      'storeWindowTreeOnButtonClick': false
+    });
+  }
+});
+
+// taken from deltaspike 1.9.4
+
+window.dswh = window.dswh || {
+
+      DEBUG_MODE : false,
+      TEMP_WINDOW_NAME : 'tempWindowId',
+      MANAGED_WINDOW_NAME_PREFIX : 'ds-',
+
+      initialized: false,
+      windowId : null,
+      clientWindowRenderMode : null,
+      maxWindowIdLength : 10,
+      cfg : null,
+
+      init : function(windowId, clientWindowRenderMode, maxWindowIdLength, cfg) {
+
+        if (dswh.initialized === true)
+        {
+            return;
+        }
+
+        dswh.initialized = true;
+
+        dswh.utils.log('------- DeltaSpike windowhandler.js -------');
+        dswh.utils.log('--- #init(\'' + windowId + '\', \'' + clientWindowRenderMode + '\',' + maxWindowIdLength + ',' + dswh.utils.stringify(cfg) + ')');
+        dswh.utils.log('window.name: ' + window.name);
+
+        this.windowId = windowId;
+        this.clientWindowRenderMode = clientWindowRenderMode;
+        this.maxWindowIdLength = maxWindowIdLength;
+        if (cfg) {
+          this.cfg = cfg;
+        } else {
+          this.cfg = {};
+        }
+
+        var targetStrategy = this.strategy[clientWindowRenderMode];
+        if (targetStrategy) {
+          dswh.utils.log('--- #validate');
+
+          targetStrategy.validate();
+
+          // early init
+          // this is required if e.g. the onload attr is defined on the body tag and our onload handler won't be called
+          // ATTENTION: the ds:windowId component must be placed as last body tag
+          dswh.utils.log('--- #init(false)');
+          targetStrategy.init(false);
+
+          // XXX jsf.ajax not used in Tobago
+          // JSF ajax callback
+          // jsf.ajax.addOnEvent(function(event) {
+          //   if (event.status === "success") {
+          //     dswh.utils.log('--- #init(true)');
+          //     targetStrategy.init(true);
+          //   }
+          // });
+
+
+          // PF ajax callback
+          if (window.$ && window.PrimeFaces) {
+            $(document).on('pfAjaxComplete', function () {
+              dswh.utils.log('--- #init(true)');
+              targetStrategy.init(true);
+            });
+          }
+
+          // init via onload
+          // just as fallback if ds:windowId is not placed at last body tag
+          var oldWindowOnLoad = window.onload;
+          window.onload = function(evt) {
+            try {
+              (oldWindowOnLoad) ? oldWindowOnLoad(evt) : null;
+            } finally {
+              dswh.utils.log('--- #init(false)');
+              targetStrategy.init(false);
+            }
+          };
+        }
+      },
+
+      strategy : {
+
+        'CLIENTWINDOW' : {
+
+          validate : function() {
+            this.cleanupCookies();
+            this.assertWindowId();
+          },
+
+          init : function(ajax) {
+            this.overwriteLinkOnClickEvents();
+            this.overwriteButtonOnClickEvents();
+
+            dswh.utils.appendHiddenWindowIdToForms();
+          },
+
+          assertWindowId : function() {
+            dswh.utils.log('--- #assertWindowId');
+
+            // ensure that windowIds get checked even if no windowhandler.html is used
+            if (!dswh.utils.isWindowNameDefined() || !dswh.utils.isManagedWindowName()) {
+              dswh.utils.log('window name not defined or unmanaged - request new windowId');
+              dswh.utils.requestNewWindowId();
+            }
+          },
+
+          overwriteLinkOnClickEvents : function() {
+
+            var tokenizedRedirectEnabled = dswh.cfg.tokenizedRedirect;
+            var storeWindowTreeEnabled = dswh.utils.isHtml5() && dswh.cfg.storeWindowTreeOnLinkClick;
+
+            dswh.utils.log('--- #overwriteLinkOnClickEvents');
+            dswh.utils.log('tokenizedRedirect: ' + dswh.cfg.tokenizedRedirect);
+            dswh.utils.log('storeWindowTreeOnLinkClick: ' + dswh.cfg.storeWindowTreeOnLinkClick);
+
+            if (tokenizedRedirectEnabled || storeWindowTreeEnabled) {
+              var links = document.getElementsByTagName("a");
+              for (var i = 0; i < links.length; i++) {
+                var link = links[i];
+
+                var target = link.getAttribute('target');
+
+                if (dswh.strategy.CLIENTWINDOW.isHrefDefined(link) === true && (!target || target === '_self')) {
+                  if (!link.onclick) {
+                    link.onclick = function(evt) {
+                      // IE handling added
+                      evt = evt || window.event;
+
+                      // skip open in new tab
+                      if (!evt.ctrlKey) {
+                        if (storeWindowTreeEnabled) {
+                          dswh.strategy.CLIENTWINDOW.storeWindowTree();
+                        }
+                        if (tokenizedRedirectEnabled) {
+                          dswh.strategy.CLIENTWINDOW.tokenizedRedirect(this);
+                          return false;
+                        }
+
+                        return true;
+                      }
+                    };
+                  } else {
+                    // prevent double decoration
+                    if (!("" + link.onclick).match(".*storeWindowTree().*")) {
+                      //the function wrapper is important otherwise the
+                      //last onclick handler would be assigned to oldonclick
+                      (function storeEvent() {
+                        var oldonclick = link.onclick;
+                        link.onclick = function(evt) {
+                          // IE handling added
+                          evt = evt || window.event;
+
+                          var proceed = oldonclick.bind(this)(evt);
+                          if (typeof proceed === 'undefined' || proceed === true) {
+
+                            // skip open in new tab
+                            if (!evt.ctrlKey) {
+                              if (storeWindowTreeEnabled) {
+                                dswh.strategy.CLIENTWINDOW.storeWindowTree();
+                              }
+
+                              if (tokenizedRedirectEnabled) {
+                                dswh.strategy.CLIENTWINDOW.tokenizedRedirect(this);
+                                return false;
+                              }
+                            }
+                          }
+                          return proceed;
+                        };
+                      })();
+                    }
+                  }
+                }
+              }
+            }
+          },
+
+          overwriteButtonOnClickEvents : function() {
+
+            var storeWindowTreeEnabled = dswh.utils.isHtml5() && dswh.cfg.storeWindowTreeOnButtonClick;
+
+            dswh.utils.log('--- #overwriteButtonOnClickEvents');
+            dswh.utils.log('storeWindowTreeOnButtonClick: ' + dswh.cfg.storeWindowTreeOnButtonClick);
+
+            if (storeWindowTreeEnabled) {
+              var inputs = document.getElementsByTagName("input");
+              for (var i = 0; i < inputs.length; i++) {
+                var input = inputs[i];
+                if (input.getAttribute("type") === "submit" || input.getAttribute("type") === "button") {
+                  if (!input.onclick) {
+                    input.onclick = function() {
+                      dswh.strategy.CLIENTWINDOW.storeWindowTree();
+                      return true;
+                    };
+                  } else {
+                    // prevent double decoration
+                    if (!("" + input.onclick).match(".*storeWindowTree().*")) {
+                      //the function wrapper is important otherwise the
+                      //last onclick handler would be assigned to oldonclick
+                      (function storeEvent() {
+                        var oldonclick = input.onclick;
+                        input.onclick = function(evt) {
+                          //ie handling added
+                          evt = evt || window.event;
+
+                          dswh.strategy.CLIENTWINDOW.storeWindowTree();
+
+                          return oldonclick.bind(this)(evt);
+                        };
+                      })();
+                    }
+                  }
+                }
+              }
+            }
+          },
+
+          isHrefDefined : function(link) {
+
+            var href = link.getAttribute("href");
+
+            if (!href || href === null) {
+              return false;
+            }
+
+            // trim
+            href = href.replace(/^\s+|\s+$/g, '');
+
+            if (href === '') {
+              return false;
+            }
+
+            if (href.indexOf('#') === 0) {
+              return false;
+            }
+
+            if (href.lastIndexOf('javascript:', 0) === 0) {
+              return false;
+            }
+
+            return true;
+          },
+
+          tokenizedRedirect : function(link) {
+
+            dswh.utils.log('--- #tokenizedRedirect');
+
+            var requestToken = dswh.utils.generateNewRequestToken();
+            dswh.utils.storeCookie('dsrwid-' + requestToken, dswh.windowId, 3);
+            window.location = dswh.utils.setUrlParam(link.href, 'dsrid', requestToken);
+          },
+
+          /**
+           * store the current body in the html5 localstorage
+           */
+          storeWindowTree : function() {
+
+            dswh.utils.log('--- #storeWindowTree');
+
+            // first we store all CSS we also need on the intermediate page
+            var headNodes = document.getElementsByTagName("head")[0].childNodes;
+            var oldSS = new Array();
+            var j = 0;
+            for (var i = 0; i < headNodes.length; i++) {
+              var tagName = headNodes[i].tagName;
+              if (tagName
+                  && dswh.utils.equalsIgnoreCase(tagName, "link")
+                  && dswh.utils.equalsIgnoreCase(headNodes[i].getAttribute("type"), "text/css")) {
+
+                // sort out media="print" and stuff
+                var media = headNodes[i].getAttribute("media");
+                if (!media
+                    || dswh.utils.equalsIgnoreCase(media, "all")
+                    || dswh.utils.equalsIgnoreCase(media, 'screen')) {
+                  oldSS[j++] = headNodes[i].getAttribute("href");
+                }
+              }
+            }
+            localStorage.setItem(window.name + '_css', dswh.utils.stringify(oldSS));
+
+            var body = document.getElementsByTagName("body")[0];
+            localStorage.setItem(window.name + '_body', body.innerHTML);
+
+            var attributes = {};
+            for (var i = 0; i < body.attributes.length; i++) {
+              var attribute = body.attributes[i];
+              attributes[attribute.name] = attribute.value;
+            }
+            localStorage.setItem(window.name + '_bodyAttributes', dswh.utils.stringify(attributes));
+
+            var scrollTop = (window.pageYOffset || document.documentElement.scrollTop) - (document.documentElement.clientTop || 0);
+            localStorage.setItem(window.name + '_scrollTop', scrollTop);
+
+            var scrollLeft = (window.pageXOffset || document.documentElement.scrollLeft) - (document.documentElement.clientLeft || 0);
+            localStorage.setItem(window.name + '_scrollLeft', scrollLeft);
+          },
+
+          cleanupCookies : function() {
+            dswh.utils.log('--- #cleanupCookies');
+
+            var dsrid = dswh.utils.getUrlParameter(window.location.href, 'dsrid');
+            if (dsrid) {
+              dswh.utils.expireCookie('dsrwid-' + dsrid);
+            }
+          }
+        },
+
+        'LAZY' : {
+
+          validate : function() {
+            this.cleanupCookies();
+            this.assertWindowId();
+          },
+
+          init : function(ajax) {
+            dswh.utils.appendHiddenWindowIdToForms();
+          },
+
+          assertWindowId : function() {
+            var dswid = dswh.utils.getUrlParameter(window.location.href, 'dswid');
+
+            dswh.utils.log('--- #assertWindowId');
+            dswh.utils.log('dswid: ' + dswid);
+
+            // window name is defined -> existing tab
+            if (dswh.utils.isWindowNameDefined()) {
+
+              // is the current window name a already managed by DS?
+              if (dswh.utils.isManagedWindowName()) {
+
+                var windowId = dswh.utils.getWindowIdFromWindowName();
+
+                // we triggered the windowId recreation last request
+                if (windowId === dswh.TEMP_WINDOW_NAME) {
+                  // enabled initial redirect
+                  // -> use the new windowId from the url
+                  if (dswid) {
+                    dswh.utils.log('assign window name from request parameter');
+
+                    dswh.utils.setWindowIdAsWindowName(dswid);
+                  }
+                  // disabled initial redirect
+                  // -> use the new windowId from the rendered config as no url param is available
+                  else {
+                    dswh.utils.log('assign window name from server windowId');
+
+                    dswh.utils.setWindowIdAsWindowName(dswh.windowId);
+                  }
+                }
+                // security check like on the server side
+                else if (windowId.length > dswh.maxWindowIdLength) {
+                  dswh.utils.log('window id from window name exeeds maxWindowIdLength - request new windowId');
+
+                  dswh.utils.requestNewWindowId();
+                }
+                // window name doesn't match requested windowId
+                // -> redirect to the same view with current windowId from the window name
+                else if (windowId !== dswid) {
+                  dswh.utils.log('reload url with window name');
+
+                  window.location = dswh.utils.setUrlParam(window.location.href, 'dswid', windowId);
+                }
+              }
+              else {
+                dswh.utils.log('window name is unmanaged - request new windowId');
+
+                dswh.utils.requestNewWindowId();
+              }
+            }
+            // window name is undefined -> "open in new tab/window" was used
+            else {
+              // url param available?
+              if (dswid) {
+                // initial redirect
+                // -> the windowId is valid - we don't need to a second request
+                if (dswh.cfg.initialRedirectWindowId && dswid === dswh.cfg.initialRedirectWindowId) {
+                  dswh.utils.log('assign window name from initialRedirectWindowId');
+
+                  dswh.utils.setWindowIdAsWindowName(dswh.cfg.initialRedirectWindowId);
+                }
+                // != initial redirect
+                // -> request a new windowId to avoid multiple tabs with the same windowId
+                else {
+                  dswh.utils.log('request new windowId');
+
+                  dswh.utils.requestNewWindowId();
+                }
+              }
+              // as no url parameter is available, the request is a new tab with disabled initial redirect
+              // -> just use the windowId from the renderer
+              else if (dswh.windowId) {
+                dswh.utils.log('assign window name from server windowId');
+
+                dswh.utils.setWindowIdAsWindowName(dswh.windowId);
+              }
+            }
+          },
+
+          cleanupCookies : function() {
+            dswh.utils.log('--- #cleanupCookies');
+
+            var dswid = dswh.utils.getUrlParameter(window.location.href, 'dswid');
+            if (dswid) {
+              dswh.utils.expireCookie('dsrwid-' + dswid);
+            }
+          }
+        }
+      },
+
+      utils : {
+
+        findRootWindow: function() {
+            var w = window;
+            while(w.frameElement) {
+                var parent = w.parent;
+                if (parent === undefined) {
+                    break;
+                }
+                w = parent;
+            };
+
+            return w;
+        },
+
+        isWindowNameDefined : function() {
+            var w = dswh.utils.findRootWindow();
+            return w.name && w.name.length > 0;
+        },
+
+        isManagedWindowName : function() {
+            var w = dswh.utils.findRootWindow();
+            if (!w.name) {
+            return false;
+          }
+
+            return w.name.indexOf(dswh.MANAGED_WINDOW_NAME_PREFIX) === 0;
+        },
+
+        getWindowIdFromWindowName : function() {
+            return dswh.utils.findRootWindow().name.substring(dswh.MANAGED_WINDOW_NAME_PREFIX.length);
+        },
+
+        setWindowIdAsWindowName : function(windowId) {
+            dswh.utils.findRootWindow().name = dswh.MANAGED_WINDOW_NAME_PREFIX + windowId;
+        },
+
+        requestNewWindowId : function() {
+          // set temp window name to remember the current state
+          dswh.utils.setWindowIdAsWindowName(dswh.TEMP_WINDOW_NAME);
+
+          // we remove the dswid if available and redirect to the same url again to create a new windowId
+          window.location = dswh.utils.setUrlParam(window.location.href, 'dswid', null);
+
+          // set temp window name to remember the current state (again - sometimes required for IE!?)
+            dswh.utils.setWindowIdAsWindowName(dswh.TEMP_WINDOW_NAME);
+        },
+
+        isHtml5 : function() {
+          try {
+            return !!localStorage.getItem;
+          } catch(e) {
+            return false;
+          }
+        },
+
+        stringify : function(someArray) {
+          // some browsers don't understand JSON - guess which one ... :(
+          if (JSON) {
+            return JSON.stringify(someArray);
+          }
+          return someArray.join("|||");
+        },
+
+        unstringify : function(serialized) {
+          if (JSON) {
+            return JSON.parse(serialized);
+          }
+
+          return serialized.split("|||");
+        },
+
+        equalsIgnoreCase : function(source, destination) {
+          //either both are not set or null
+          if (!source && !destination) {
+            return true;
+          }
+          //source or dest is set while the other is not
+          if (!source || !destination) return false;
+
+          //in any other case we do a strong string comparison
+          return source.toLowerCase() === destination.toLowerCase();
+        },
+
+        getUrlParameter : function(uri, name) {
+          // create an anchor object with the uri and let the browser parse it
+          var a = document.createElement('a');
+          a.href = uri;
+
+          // check if a query string is available
+          var queryString = a.search;
+          if (queryString && queryString.length > 0) {
+            // create an array of query parameters - substring(1) removes the ? at the beginning of the query
+            var queryParameters = queryString.substring(1).split("&");
+            for (var i = 0; i < queryParameters.length; i++) {
+              var queryParameter = queryParameters[i].split("=");
+              if (queryParameter[0] === name) {
+                return queryParameter.length > 1 ? decodeURIComponent(queryParameter[1]) : "";
+              }
+            }
+          }
+
+          return null;
+        },
+
+        setUrlParam : function(uri, parameterName, parameterValue) {
+          var a = document.createElement('a');
+          a.href = uri;
+
+          // set empty string as value if not defined or empty
+          if (!parameterValue || parameterValue.replace(/^\s+|\s+$/g, '').length === 0) {
+            parameterValue = '';
+          }
+
+          // check if value is empty
+          if (parameterValue.length === 0) {
+
+            // both value and query string is empty (or doesn't contain the param), don't touch the url
+            if (a.search.length === 0 || a.search.indexOf(parameterName + "=") === -1) {
+              return a.href;
+            }
+          }
+
+          // query string is empty, just append our new parameter
+          if (a.search.length === 0) {
+            a.search = '?' + encodeURIComponent(parameterName) + "=" + encodeURIComponent(parameterValue);
+
+            return a.href;
+          }
+
+          var oldParameters = a.search.substring(1).split('&');
+          var newParameters = [];
+          newParameters.push(parameterName + "=" + encodeURIComponent(parameterValue));
+
+          // loop old parameters, remove empty ones and remove the parameter with the same name as the new one
+          for (var i = 0; i < oldParameters.length; i++) {
+            var oldParameterPair = oldParameters[i];
+
+            if (oldParameterPair.length > 0) {
+              var oldParameterName = oldParameterPair.split('=')[0];
+              var oldParameterValue = oldParameterPair.split('=')[1];
+
+              // don't add empty parameters again
+              if (oldParameterValue && oldParameterValue.replace(/^\s+|\s+$/g, '').length > 0) {
+                // skip the the old parameter if it's the same as the new parameter
+                if (oldParameterName !== parameterName) {
+                  newParameters.push(oldParameterName + "=" + oldParameterValue);
+                }
+              }
+            }
+          }
+
+          // join new parameters
+          a.search = '?' + newParameters.join('&');
+
+          return a.href;
+        },
+
+        appendHiddenWindowIdToForms : function() {
+          var forms = document.getElementsByTagName("form");
+          for (var i = 0; i < forms.length; i++) {
+            var form = forms[i];
+            var dspwid = form.elements["dspwid"];
+            if (!dspwid) {
+              dspwid = document.createElement("INPUT");
+              dspwid.setAttribute("name", "dspwid");
+              dspwid.setAttribute("type", "hidden");
+              form.appendChild(dspwid);
+            }
+
+            dspwid.setAttribute("value", dswh.windowId);
+          }
+        },
+
+        expireCookie : function(cookieName) {
+          var date = new Date();
+          date.setTime(date.getTime()-(10*24*60*60*1000)); // - 10 day
+          var expires = ";max-age=0;expires=" + date.toGMTString();
+
+          document.cookie = cookieName + "=" + expires + "; path=/";
+        },
+
+        generateNewRequestToken : function() {
+          return "" + Math.floor(Math.random() * 999);
+        },
+
+        generateNewWindowId : function() {
+          return "" + Math.floor((Math.random() * (9999 - 1000)) + 1000);
+        },
+
+        storeCookie : function(name, value, seconds) {
+          var expiresDate = new Date();
+          expiresDate.setTime(expiresDate.getTime() + (seconds * 1000));
+          var expires = "; expires=" + expiresDate.toGMTString();
+
+          document.cookie = name + '=' + value + expires + "; path=/";
+        },
+
+        log : function(message) {
+          if (dswh.DEBUG_MODE === true) {
+            console.log(message);
+          }
+        }
+      }
+    };
+
+// required for IE8
+if (!Function.prototype.bind) {
+  Function.prototype.bind = function (oThis) {
+    if (typeof this !== 'function') {
+      // closest thing possible to the ECMAScript 5
+      // internal IsCallable function
+      throw new TypeError('Function.prototype.bind - what is trying to be bound is not callable');
+    }
+
+    var aArgs = Array.prototype.slice.call(arguments, 1),
+        fToBind = this,
+        fNOP = function () {
+        },
+        fBound = function () {
+          return fToBind.apply(this instanceof fNOP && oThis
+                  ? this
+                  : oThis,
+              aArgs.concat(Array.prototype.slice.call(arguments)));
+        };
+
+    fNOP.prototype = this.prototype;
+    fBound.prototype = new fNOP();
+
+    return fBound;
+  };
+}
\ No newline at end of file
diff --git a/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js b/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js
index c6489b5..a33ca4d 100644
--- a/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js
+++ b/tobago-theme/tobago-theme-standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago.js
@@ -2783,52 +2783,6 @@ Tobago.registerListener(Tobago.SelectManyCheckbox.init, Tobago.Phase.AFTER_UPDAT
 
 // ////////////////////////////////////////////////////////////////////////////////////////////////////////////////
 
-Tobago.Codi = {};
-
-/**
- * If the window has no name set we set the name and request a new view with unset windowId, so that the
- * server will generate a new one for us.
- */
-Tobago.Codi.init = function() {
-
-  var form = document.forms[0];
-  var windowIdEnabled = Tobago.Codi.hasUrlWindowId(form.action);
-  if (windowIdEnabled && window.name == "") {
-    form.action = Tobago.Codi.urlWithoutWindowId(form.action);
-    window.name = "window";
-    Tobago.submitAction();
-  }
-};
-
-Tobago.Codi.hasUrlWindowId = function(base) {
-  return base.indexOf("?windowId=") > -1 || base.indexOf("&windowId=") > -1;
-};
-
-/**
- * taken from myfaces-extcdi (Codi)
- */
-Tobago.Codi.urlWithoutWindowId = function(base) {
-    var query = base;
-    var vars = query.split(/&|\?/g);
-    var newQuery = "";
-    var iParam = 0;
-    for (var i=0; vars != null && i < vars.length; i++) {
-        var pair = vars[i].split("=");
-        if (pair.length == 1) {
-            newQuery = pair[0];
-        }
-        else {
-            if (pair[0] != "windowId") {
-                var amp = iParam++ > 0 ? "&" : "?";
-                newQuery =  newQuery + amp + pair[0] + "=" + pair[1];
-            }
-        }
-    }
-    return newQuery;
-};
-
-Tobago.registerListener(Tobago.Codi.init, Tobago.Phase.DOCUMENT_READY);
-
 Tobago.SplitLayout = {
   init: function(elements) {
     Tobago.Utils.selectWithJQuery(elements, "[data-tobago-split-layout]").each(Tobago.SplitLayout.initLayout);


[myfaces-tobago] 07/22: docs

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit a15f649c89017100634aa08838eb214d15fdc841
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Wed Aug 26 20:19:22 2020 +0200

    docs
---
 readme.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/readme.txt b/readme.txt
index e138ecb..7afb4d3 100644
--- a/readme.txt
+++ b/readme.txt
@@ -1,6 +1,6 @@
 Building
 --------
-You need Maven 3 (at least 3.0.4) Java 6, 7 or 8 to build Tobago.
+You need Maven 3 (at least 3.0.4) Java 8 to build Tobago 2.
 
 In the main directory you can use
 


[myfaces-tobago] 06/22: check if tools.jar is needed with JDK 1.8 (and higher)

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit fad377d6004e3c62b3509564380b47c34fcbf2d9
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Wed Aug 26 20:04:21 2020 +0200

    check if tools.jar is needed with JDK 1.8 (and higher)
---
 tobago-core/pom.xml                              | 17 -----------------
 tobago-extension/tobago-fileupload/pom.xml       |  6 ------
 tobago-extension/tobago-sandbox/pom.xml          | 17 -----------------
 tobago-theme/tobago-theme-charlotteville/pom.xml |  6 ------
 tobago-theme/tobago-theme-richmond/pom.xml       |  6 ------
 tobago-theme/tobago-theme-scarborough/pom.xml    |  6 ------
 tobago-theme/tobago-theme-speyside/pom.xml       |  6 ------
 tobago-theme/tobago-theme-standard/pom.xml       |  6 ------
 tobago-tool/tobago-tool-annotation/pom.xml       | 20 --------------------
 tobago-tool/tobago-tool-apt/pom.xml              | 21 ---------------------
 10 files changed, 111 deletions(-)

diff --git a/tobago-core/pom.xml b/tobago-core/pom.xml
index 6193b72..ecc77f4 100644
--- a/tobago-core/pom.xml
+++ b/tobago-core/pom.xml
@@ -205,23 +205,6 @@
   </dependencies>
 
   <profiles>
-    <!-- Apples JDK (until 1.6) has not a tools.jar -->
-    <profile>
-      <id>tools.jar</id>
-      <activation>
-        <os><family>!mac</family></os>
-        <jdk>1.7</jdk>
-      </activation>
-      <dependencies>
-        <dependency>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-          <version>1.5.0</version>
-          <scope>system</scope>
-          <systemPath>${java.home}/../lib/tools.jar</systemPath>
-        </dependency>
-      </dependencies>
-    </profile>
     <profile>
       <id>codegen-old-jdk</id>
       <activation>
diff --git a/tobago-extension/tobago-fileupload/pom.xml b/tobago-extension/tobago-fileupload/pom.xml
index 2c42caa..5c4a266 100644
--- a/tobago-extension/tobago-fileupload/pom.xml
+++ b/tobago-extension/tobago-fileupload/pom.xml
@@ -32,12 +32,6 @@
       <artifactId>tobago-core</artifactId>
       <version>${project.version}</version>
       <scope>compile</scope>
-      <exclusions>
-        <exclusion>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-        </exclusion>
-      </exclusions>
     </dependency>
   </dependencies>
 
diff --git a/tobago-extension/tobago-sandbox/pom.xml b/tobago-extension/tobago-sandbox/pom.xml
index 8e52b8c..6ab6d4f 100644
--- a/tobago-extension/tobago-sandbox/pom.xml
+++ b/tobago-extension/tobago-sandbox/pom.xml
@@ -245,23 +245,6 @@
   </dependencies>
 
   <profiles>
-    <!-- Apples JDK (until 1.6) has not a tools.jar -->
-    <profile>
-      <id>tools.jar</id>
-      <activation>
-        <os><family>!mac</family></os>
-        <jdk>1.7</jdk>
-      </activation>
-      <dependencies>
-        <dependency>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-          <version>1.5.0</version>
-          <scope>system</scope>
-          <systemPath>${java.home}/../lib/tools.jar</systemPath>
-        </dependency>
-      </dependencies>
-    </profile>
     <profile>
       <id>generate-assembly</id>
       <build>
diff --git a/tobago-theme/tobago-theme-charlotteville/pom.xml b/tobago-theme/tobago-theme-charlotteville/pom.xml
index 4d9f80f..b1acae7 100644
--- a/tobago-theme/tobago-theme-charlotteville/pom.xml
+++ b/tobago-theme/tobago-theme-charlotteville/pom.xml
@@ -56,12 +56,6 @@
       <groupId>org.apache.myfaces.tobago</groupId>
       <artifactId>tobago-core</artifactId>
       <version>${project.version}</version>
-      <exclusions>
-        <exclusion>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-        </exclusion>
-      </exclusions>
     </dependency>
   </dependencies>
   <properties>
diff --git a/tobago-theme/tobago-theme-richmond/pom.xml b/tobago-theme/tobago-theme-richmond/pom.xml
index 939cc5b..68b81a4 100644
--- a/tobago-theme/tobago-theme-richmond/pom.xml
+++ b/tobago-theme/tobago-theme-richmond/pom.xml
@@ -58,12 +58,6 @@
       <groupId>org.apache.myfaces.tobago</groupId>
       <artifactId>tobago-core</artifactId>
       <version>${project.version}</version>
-      <exclusions>
-        <exclusion>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-        </exclusion>
-      </exclusions>
     </dependency>
   </dependencies>
   <properties>
diff --git a/tobago-theme/tobago-theme-scarborough/pom.xml b/tobago-theme/tobago-theme-scarborough/pom.xml
index 71b21b2..d9b9e62 100644
--- a/tobago-theme/tobago-theme-scarborough/pom.xml
+++ b/tobago-theme/tobago-theme-scarborough/pom.xml
@@ -133,12 +133,6 @@
       <groupId>org.apache.myfaces.tobago</groupId>
       <artifactId>tobago-core</artifactId>
       <version>${project.version}</version>
-      <exclusions>
-        <exclusion>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-        </exclusion>
-      </exclusions>
     </dependency>
     <dependency>
       <groupId>org.apache.geronimo.specs</groupId>
diff --git a/tobago-theme/tobago-theme-speyside/pom.xml b/tobago-theme/tobago-theme-speyside/pom.xml
index 43c5149..193200c 100644
--- a/tobago-theme/tobago-theme-speyside/pom.xml
+++ b/tobago-theme/tobago-theme-speyside/pom.xml
@@ -36,12 +36,6 @@
       <groupId>org.apache.myfaces.tobago</groupId>
       <artifactId>tobago-core</artifactId>
       <version>${project.version}</version>
-      <exclusions>
-        <exclusion>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-        </exclusion>
-      </exclusions>
     </dependency>
   </dependencies>
 
diff --git a/tobago-theme/tobago-theme-standard/pom.xml b/tobago-theme/tobago-theme-standard/pom.xml
index 299a3ed..7871f60 100644
--- a/tobago-theme/tobago-theme-standard/pom.xml
+++ b/tobago-theme/tobago-theme-standard/pom.xml
@@ -141,12 +141,6 @@
       <groupId>org.apache.myfaces.tobago</groupId>
       <artifactId>tobago-core</artifactId>
       <version>${project.version}</version>
-      <exclusions>
-        <exclusion>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-        </exclusion>
-      </exclusions>
     </dependency>
     <dependency>
       <groupId>org.apache.myfaces.test</groupId>
diff --git a/tobago-tool/tobago-tool-annotation/pom.xml b/tobago-tool/tobago-tool-annotation/pom.xml
index 5647619..e094ed8 100644
--- a/tobago-tool/tobago-tool-annotation/pom.xml
+++ b/tobago-tool/tobago-tool-annotation/pom.xml
@@ -26,24 +26,4 @@
   <packaging>jar</packaging>
   <name>Tobago Tool Annotation</name>
 
-  <profiles>
-    <!-- Apples JDK (until 1.6) has not a tools.jar -->
-    <profile>
-      <id>tools.jar</id>
-      <activation>
-        <os><family>!mac</family></os>
-        <jdk>1.7</jdk>
-      </activation>
-      <dependencies>
-        <dependency>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-          <version>1.5.0</version>
-          <scope>system</scope>
-          <systemPath>${java.home}/../lib/tools.jar</systemPath>
-        </dependency>
-      </dependencies>
-    </profile>
-
-  </profiles>
 </project>
diff --git a/tobago-tool/tobago-tool-apt/pom.xml b/tobago-tool/tobago-tool-apt/pom.xml
index 972b302..7bbc4ac 100644
--- a/tobago-tool/tobago-tool-apt/pom.xml
+++ b/tobago-tool/tobago-tool-apt/pom.xml
@@ -117,27 +117,6 @@
     </dependency>
   </dependencies>
 
-  <profiles>
-    <!-- Apples JDK (until 1.6) has not a tools.jar -->
-    <profile>
-      <id>tools.jar</id>
-      <activation>
-        <os><family>!mac</family></os>
-        <jdk>1.7</jdk>
-      </activation>
-      <dependencies>
-        <dependency>
-          <groupId>sun.jdk</groupId>
-          <artifactId>tools</artifactId>
-          <version>1.5.0</version>
-          <scope>system</scope>
-          <systemPath>${java.home}/../lib/tools.jar</systemPath>
-        </dependency>
-      </dependencies>
-    </profile>
-
-  </profiles>
-
   <properties>
     <tobago.basedir>${project.basedir}/../..</tobago.basedir>
   </properties>


[myfaces-tobago] 10/22: fix rat check

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 2539e05539dfd0979a05f1dbe1f94a30fe61a709
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Thu Aug 27 08:45:15 2020 +0200

    fix rat check
---
 pom.xml | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/pom.xml b/pom.xml
index 3f9a88c..c964965 100644
--- a/pom.xml
+++ b/pom.xml
@@ -992,6 +992,9 @@
 
               <!-- photo shop -->
               <exclude>**/*.psd</exclude>
+
+              <!-- pixelmator -->
+              <exclude>**/*.pxm</exclude>
             </excludes>
           </configuration>
         </plugin>


[myfaces-tobago] 21/22: Update batik dependency from 1.9 to 1.13, because of CVE-2019-17566

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 83918bef7bb78be5138b37bb1f28426625185660
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Fri Nov 20 07:50:41 2020 +0100

    Update batik dependency from 1.9 to 1.13, because of CVE-2019-17566
---
 tobago-example/tobago-example-test/pom.xml | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/tobago-example/tobago-example-test/pom.xml b/tobago-example/tobago-example-test/pom.xml
index a399338..c294eee 100644
--- a/tobago-example/tobago-example-test/pom.xml
+++ b/tobago-example/tobago-example-test/pom.xml
@@ -148,17 +148,17 @@
     <dependency>
       <groupId>org.apache.xmlgraphics</groupId>
       <artifactId>batik-awt-util</artifactId>
-      <version>1.9</version>
+      <version>1.13</version>
     </dependency>
     <dependency>
       <groupId>org.apache.xmlgraphics</groupId>
       <artifactId>batik-gui-util</artifactId>
-      <version>1.9</version>
+      <version>1.13</version>
     </dependency>
     <dependency>
       <groupId>org.apache.xmlgraphics</groupId>
       <artifactId>batik-util</artifactId>
-      <version>1.9</version>
+      <version>1.13</version>
     </dependency>
     <!-- overrides the tomahawk version -->
     <dependency>


[myfaces-tobago] 09/22: e-mail notifications sync structure of file with master

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 23cc13ea45a21532f0ac01b3b0ac57920e5d00bf
Author: Udo Schnurpfeil <ud...@irian.eu>
AuthorDate: Wed Aug 26 20:56:00 2020 +0200

    e-mail notifications
    sync structure of file with master
---
 Jenkinsfile | 81 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 80 insertions(+), 1 deletion(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index bce0602..204daa9 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -55,7 +55,7 @@ pipeline {
                 stages {
                     stage('BuildAndTest') {
                         steps {
-                            sh "mvn clean deploy checkstyle:check apache-rat:check animal-sniffer:check dependency-check:check -Pgenerate-assembly"
+                            sh "mvn clean package checkstyle:check apache-rat:check animal-sniffer:check dependency-check:check -Pgenerate-assembly"
                         }
                         post {
                             always {
@@ -68,5 +68,84 @@ pipeline {
                 }
             }
         }
+        stage('Deploy') {
+            tools {
+                maven "Maven (latest)"
+                jdk "JDK 1.8 (latest)"
+            }
+            steps {
+                sh "mvn clean deploy -Pgenerate-assembly"
+            }
+        }
+    }
+  post {
+    // If this build failed, send an email to the list.
+    failure {
+      script {
+        emailext(
+            to: "notifications@myfaces.apache.org",
+            recipientProviders: [[$class: 'DevelopersRecipientProvider']],
+            from: "Mr. Jenkins <je...@builds.apache.org>",
+            subject: "Jenkins job ${env.JOB_NAME}#${env.BUILD_NUMBER} failed",
+            body: """
+There is a build failure in ${env.JOB_NAME}.
+
+Build: ${env.BUILD_URL}
+Logs: ${env.BUILD_URL}console
+Changes: ${env.BUILD_URL}changes
+
+--
+Mr. Jenkins
+Director of Continuous Integration
+"""
+        )
+      }
+    }
+
+    // If this build didn't fail, but there were failing tests, send an email to the list.
+    unstable {
+      script {
+        emailext(
+            to: "notifications@myfaces.apache.org",
+            recipientProviders: [[$class: 'DevelopersRecipientProvider']],
+            from: "Mr. Jenkins <je...@builds.apache.org>",
+            subject: "Jenkins job ${env.JOB_NAME}#${env.BUILD_NUMBER} unstable",
+            body: """
+Some tests have failed in ${env.JOB_NAME}.
+
+Build: ${env.BUILD_URL}
+Logs: ${env.BUILD_URL}console
+Changes: ${env.BUILD_URL}changes
+
+--
+Mr. Jenkins
+Director of Continuous Integration
+"""
+        )
+      }
+    }
+
+    // Send an email, if the last build was not successful and this one is.
+    fixed {
+      script {
+        emailext(
+            to: "notifications@myfaces.apache.org",
+            recipientProviders: [[$class: 'DevelopersRecipientProvider']],
+            from: 'Mr. Jenkins <je...@builds.apache.org>',
+            subject: "Jenkins job ${env.JOB_NAME}#${env.BUILD_NUMBER} back to normal",
+            body: """
+The build for ${env.JOB_NAME} completed successfully and is back to normal.
+
+Build: ${env.BUILD_URL}
+Logs: ${env.BUILD_URL}console
+Changes: ${env.BUILD_URL}changes
+
+--
+Mr. Jenkins
+Director of Continuous Integration
+"""
+        )
+      }
+    }
     }
 }
\ No newline at end of file


[myfaces-tobago] 16/22: TOBAGO-703 - sheet paging should adjust scroll position

Posted by we...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

weber pushed a commit to branch TOBAGO-1999_Select2
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git

commit 5cfaa12e74295ac2852f45b1c4e69e37955b5b8c
Author: Volker Weber <v....@inexso.de>
AuthorDate: Wed Sep 16 10:43:46 2020 +0200

    TOBAGO-703 - sheet paging should adjust scroll position
---
 .../myfaces/tobago/facelets/SelectManyBoxRule.java |  13 +-
 .../extension/TobagoLabelExtensionHandler.java     |   5 +
 .../component/AbstractUISelectManyBox.java         |   6 +-
 .../extension/SelectManyBoxExtensionTag.java       | 507 ++++++++++++++-------
 4 files changed, 348 insertions(+), 183 deletions(-)

diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/SelectManyBoxRule.java b/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/SelectManyBoxRule.java
index 0e413a3..c1e1427 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/SelectManyBoxRule.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/SelectManyBoxRule.java
@@ -1,9 +1,6 @@
 package org.apache.myfaces.tobago.facelets;
 
-import org.apache.myfaces.tobago.component.Attributes;
-import org.apache.myfaces.tobago.component.SupportsRenderedPartially;
 import org.apache.myfaces.tobago.internal.component.AbstractUISelectManyBox;
-import org.apache.myfaces.tobago.util.ComponentUtils;
 
 import javax.el.ValueExpression;
 import javax.faces.component.UIComponent;
@@ -22,24 +19,24 @@ public class SelectManyBoxRule extends MetaRule {
   public Metadata applyRule(String name, TagAttribute attribute, MetadataTarget metadataTarget) {
     if (metadataTarget.isTargetInstanceOf(AbstractUISelectManyBox.class)) {
       if (TOKEN_SEPARATORS.equals(name)) {
-        return new SelectManyBoxRule.SelectManyBoxMapper(attribute);
+        return new SelectManyBoxRule.TokenSeparatorsMapper(attribute);
       }
     }
     return null;
   }
 
-  static final class SelectManyBoxMapper extends Metadata {
+  static final class TokenSeparatorsMapper extends Metadata {
 
     private final TagAttribute attribute;
 
-    public SelectManyBoxMapper(TagAttribute attribute) {
+    public TokenSeparatorsMapper(TagAttribute attribute) {
       this.attribute = attribute;
     }
 
     public void applyMetadata(FaceletContext faceletContext, Object instance) {
       if (attribute.isLiteral()) {
-        final String[] components = AbstractUISelectManyBox.parseTokenSeparators(attribute.getValue());
-        ((AbstractUISelectManyBox) instance).setTokenSeparators(components);
+        final String[] tokenSeparators = AbstractUISelectManyBox.parseTokenSeparators(attribute.getValue());
+        ((AbstractUISelectManyBox) instance).setTokenSeparators(tokenSeparators);
       } else {
         final ValueExpression expression = attribute.getValueExpression(faceletContext, Object.class);
         ((UIComponent) instance).setValueExpression(TOKEN_SEPARATORS, expression);
diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/extension/TobagoLabelExtensionHandler.java b/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/extension/TobagoLabelExtensionHandler.java
index 7c5e753..cbd2ca3 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/extension/TobagoLabelExtensionHandler.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/facelets/extension/TobagoLabelExtensionHandler.java
@@ -30,9 +30,11 @@ import org.apache.myfaces.tobago.component.UIGridLayout;
 import org.apache.myfaces.tobago.component.UILabel;
 import org.apache.myfaces.tobago.component.UIPanel;
 import org.apache.myfaces.tobago.context.Markup;
+import org.apache.myfaces.tobago.facelets.SelectManyBoxRule;
 import org.apache.myfaces.tobago.facelets.SuggestMethodRule;
 import org.apache.myfaces.tobago.facelets.SupportsMarkupRule;
 import org.apache.myfaces.tobago.facelets.TobagoComponentHandler;
+import org.apache.myfaces.tobago.internal.component.AbstractUISelectManyBox;
 import org.apache.myfaces.tobago.internal.layout.LayoutUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -260,6 +262,9 @@ public abstract class TobagoLabelExtensionHandler extends ComponentHandler {
     if (InputSuggest.class.isAssignableFrom(aClass)) {
       metaRuleset.addRule(SuggestMethodRule.INSTANCE);
     }
+    if (AbstractUISelectManyBox.class.isAssignableFrom(aClass)) {
+      metaRuleset.addRule(SelectManyBoxRule.INSTANCE);
+    }
     return metaRuleset;
   }
 
diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISelectManyBox.java b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISelectManyBox.java
index f6ecc6b..d365469 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISelectManyBox.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUISelectManyBox.java
@@ -191,11 +191,11 @@ public abstract class AbstractUISelectManyBox extends AbstractUISelectMany imple
   }
 
   public static String[] parseTokenSeparators(String tokenSeparators) {
-    Set<String> tokens = new HashSet<String>();
+    String[] tokens = new String[tokenSeparators.length()];
     for (int i = 0; i < tokenSeparators.length(); i++) {
-      tokens.add(tokenSeparators.substring(i, i + 1));
+      tokens[i] = tokenSeparators.substring(i, i + 1);
     }
-    return tokens.toArray(new String[0]);
+    return tokens;
   }
 
   public boolean isTokenSeparatorsSet() {
diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/extension/SelectManyBoxExtensionTag.java b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/extension/SelectManyBoxExtensionTag.java
index d23448f..51a0931 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/extension/SelectManyBoxExtensionTag.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/taglib/extension/SelectManyBoxExtensionTag.java
@@ -24,7 +24,7 @@ import org.apache.myfaces.tobago.apt.annotation.ExtensionTag;
 import org.apache.myfaces.tobago.apt.annotation.Tag;
 import org.apache.myfaces.tobago.apt.annotation.TagAttribute;
 import org.apache.myfaces.tobago.apt.annotation.UIComponentTagAttribute;
-import org.apache.myfaces.tobago.internal.taglib.SelectManyListboxTag;
+import org.apache.myfaces.tobago.internal.taglib.SelectManyBoxTag;
 
 import javax.el.MethodExpression;
 import javax.el.ValueExpression;
@@ -39,30 +39,40 @@ import javax.servlet.jsp.JspException;
     faceletHandler = "org.apache.myfaces.tobago.facelets.extension.SelectManyBoxExtensionHandler")
 public class SelectManyBoxExtensionTag extends TobagoExtensionBodyTagSupport {
 
-  private ValueExpression required;
-  private ValueExpression value;
-  private MethodExpression valueChangeListener;
-  private ValueExpression disabled;
-  private ValueExpression readonly;
-  private ValueExpression onchange;
-  private ValueExpression label;
   private ValueExpression accessKey;
-  private ValueExpression rendered;
+  private ValueExpression allowClear;
+  private ValueExpression allowCustom;
   private ValueExpression binding;
-  private ValueExpression tip;
   private ValueExpression converter;
-  private MethodExpression validator;
+  private ValueExpression converterMessage;
+  private ValueExpression disabled;
+  private ValueExpression focus;
+  private ValueExpression hideDropdown;
+  private ValueExpression label;
   private ValueExpression labelWidth;
   private ValueExpression markup;
+  private ValueExpression  matcher;
+  private ValueExpression  maximumInputLength;
+  private ValueExpression  maximumSelectionLength;
+  private ValueExpression  minimumInputLength;
+  private ValueExpression onchange;
+  private ValueExpression placeholder;
+  private ValueExpression readonly;
+  private ValueExpression rendered;
+  private ValueExpression required;
+  private ValueExpression requiredMessage;
   private ValueExpression tabIndex;
-  private ValueExpression focus;
+  private ValueExpression tip;
+  private ValueExpression tokenizer;
+  private ValueExpression tokenSeparators;
+  private MethodExpression validator;
   private ValueExpression validatorMessage;
-  private ValueExpression converterMessage;
-  private ValueExpression requiredMessage;
+  private ValueExpression value;
+  private MethodExpression valueChangeListener;
   private String fieldId;
 
   private LabelExtensionTag labelTag;
-  private SelectManyListboxTag selectManyListboxTag;
+  private SelectManyBoxTag selectManyBoxTag;
 
   @Override
   public int doStartTag() throws JspException {
@@ -95,69 +105,104 @@ public class SelectManyBoxExtensionTag extends TobagoExtensionBodyTagSupport {
     labelTag.setJspId(nextJspId());
     labelTag.doStartTag();
 
-    selectManyListboxTag = new SelectManyListboxTag();
-    selectManyListboxTag.setPageContext(pageContext);
-    if (value != null) {
-      selectManyListboxTag.setValue(value);
+    selectManyBoxTag = new SelectManyBoxTag();
+    selectManyBoxTag.setPageContext(pageContext);
+    if (allowClear != null) {
+      selectManyBoxTag.setAllowClear(allowClear);
     }
-    if (valueChangeListener != null) {
-      selectManyListboxTag.setValueChangeListener(valueChangeListener);
+    if (allowCustom != null) {
+      selectManyBoxTag.setAllowCustom(allowCustom);
     }
     if (binding != null) {
-      selectManyListboxTag.setBinding(binding);
-    }
-    if (onchange != null) {
-      selectManyListboxTag.setOnchange(onchange);
-    }
-    if (validator != null) {
-      selectManyListboxTag.setValidator(validator);
+      selectManyBoxTag.setBinding(binding);
     }
     if (converter != null) {
-      selectManyListboxTag.setConverter(converter);
+      selectManyBoxTag.setConverter(converter);
+    }
+    if (converterMessage != null) {
+      selectManyBoxTag.setConverterMessage(converterMessage);
     }
     if (disabled != null) {
-      selectManyListboxTag.setDisabled(disabled);
+      selectManyBoxTag.setDisabled(disabled);
+    }
+    if (fieldId != null) {
+      selectManyBoxTag.setId(fieldId);
     }
     if (focus != null) {
-      selectManyListboxTag.setFocus(focus);
+      selectManyBoxTag.setFocus(focus);
     }
-    if (fieldId != null) {
-      selectManyListboxTag.setId(fieldId);
+    if (hideDropdown != null) {
+      selectManyBoxTag.setHideDropdown(hideDropdown);
     }
     if (label != null) {
-      selectManyListboxTag.setLabel(label);
+      selectManyBoxTag.setLabel(label);
+    }
+    if (markup != null) {
+      selectManyBoxTag.setMarkup(markup);
+    }
+    if (matcher != null) {
+      selectManyBoxTag.setMatcher(matcher);
+    }
+    if (maximumInputLength != null) {
+      selectManyBoxTag.setMaximumInputLength(maximumInputLength);
+    }
+    if (maximumSelectionLength != null) {
+      selectManyBoxTag.setMaximumSelectionLength(maximumSelectionLength);
+    }
+    if (minimumInputLength != null) {
+      selectManyBoxTag.setMinimumInputLength(minimumInputLength);
+    }
+    if (onchange != null) {
+      selectManyBoxTag.setOnchange(onchange);
+    }
+    if (placeholder != null) {
+      selectManyBoxTag.setPlaceholder(placeholder);
     }
     if (readonly != null) {
-      selectManyListboxTag.setReadonly(readonly);
+      selectManyBoxTag.setReadonly(readonly);
     }
     if (required != null) {
-      selectManyListboxTag.setRequired(required);
+      selectManyBoxTag.setRequired(required);
     }
-    if (markup != null) {
-      selectManyListboxTag.setMarkup(markup);
+    if (requiredMessage != null) {
+      selectManyBoxTag.setRequiredMessage(requiredMessage);
     }
     if (tabIndex != null) {
-      selectManyListboxTag.setTabIndex(tabIndex);
+      selectManyBoxTag.setTabIndex(tabIndex);
+    }
+    if (tokenizer != null) {
+      selectManyBoxTag.setTokenizer(tokenizer);
+    }
+    if (tokenSeparators != null) {
+      if (!tokenSeparators.isLiteralText()) {
+        selectManyBoxTag.setTokenSeparators(tokenSeparators);
+      } else {
+        selectManyBoxTag.setTokenSeparators(tokenSeparators);
+      }
+    }
+    if (validator != null) {
+      selectManyBoxTag.setValidator(validator);
     }
     if (validatorMessage != null) {
-      selectManyListboxTag.setValidatorMessage(validatorMessage);
+      selectManyBoxTag.setValidatorMessage(validatorMessage);
     }
-    if (converterMessage != null) {
-      selectManyListboxTag.setConverterMessage(converterMessage);
+    if (value != null) {
+      selectManyBoxTag.setValue(value);
     }
-    if (requiredMessage != null) {
-      selectManyListboxTag.setRequiredMessage(requiredMessage);
+    if (valueChangeListener != null) {
+      selectManyBoxTag.setValueChangeListener(valueChangeListener);
     }
-    selectManyListboxTag.setParent(labelTag);
-    selectManyListboxTag.setJspId(nextJspId());
-    selectManyListboxTag.doStartTag();
+
+    selectManyBoxTag.setParent(labelTag);
+    selectManyBoxTag.setJspId(nextJspId());
+    selectManyBoxTag.doStartTag();
 
     return super.doStartTag();
   }
 
   @Override
   public int doEndTag() throws JspException {
-    selectManyListboxTag.doEndTag();
+    selectManyBoxTag.doEndTag();
     labelTag.doEndTag();
     return super.doEndTag();
   }
@@ -165,66 +210,106 @@ public class SelectManyBoxExtensionTag extends TobagoExtensionBodyTagSupport {
   @Override
   public void release() {
     super.release();
+    accessKey = null;
+    allowClear = null;
+    allowCustom = null;
     binding = null;
-    onchange = null;
+    converter = null;
+    converterMessage = null;
     disabled = null;
+    fieldId = null;
+    focus = null;
+    hideDropdown = null;
     label = null;
-    accessKey = null;
+    labelTag = null;
     labelWidth = null;
+    markup = null;
+    matcher = null;
+    maximumInputLength = null;
+    maximumSelectionLength = null;
+    minimumInputLength = null;
+    onchange = null;
+    placeholder = null;
     readonly = null;
     rendered = null;
-    converter = null;
-    validator = null;
     required = null;
-    tip = null;
-    value = null;
-    valueChangeListener = null;
-    markup = null;
+    requiredMessage = null;
+    selectManyBoxTag = null;
     tabIndex = null;
-    selectManyListboxTag = null;
-    labelTag = null;
-    focus = null;
+    tip = null;
+    tokenizer = null;
+    tokenSeparators = null;
+    validator = null;
     validatorMessage = null;
-    converterMessage = null;
-    requiredMessage = null;
-    fieldId = null;
+    valueChangeListener = null;
+    value = null;
+
   }
 
   /**
-   * Flag indicating that a value is required.
-   * If the value is an empty string a
-   * ValidationError occurs and a Error Message is rendered.
+   * The accessKey of this component.
    */
   @TagAttribute
-  @UIComponentTagAttribute(type = "boolean", defaultValue = "false")
-  public void setRequired(final ValueExpression required) {
-    this.required = required;
+  @UIComponentTagAttribute(type = "java.lang.Character")
+  public void setAccessKey(final ValueExpression accessKey) {
+    this.accessKey = accessKey;
   }
 
   /**
-   * The current value of this component.
+   * Flag indicating that this select provides support for clearable selections.
+   *
+   * This is a select2 feature and will force select2=true
    */
-  @TagAttribute
-  @UIComponentTagAttribute(type = "java.lang.Object")
-  public void setValue(final ValueExpression value) {
-    this.value = value;
+  @TagAttribute()
+  @UIComponentTagAttribute(type = "boolean", defaultValue = "false", generate = false)
+  public void setAllowClear(ValueExpression allowClear) {
+    this.allowClear = allowClear;
   }
 
   /**
-   * MethodBinding representing a value change listener method
-   * that will be notified when a new value has been set for this input component.
-   * The expression must evaluate to a public method that takes a ValueChangeEvent
-   * parameter, with a return type of void.
+   * Flag indicating that this select enables free text responses.
    *
-   * @param valueChangeListener
+   * This is a select2 feature and will force select2=true
+   */
+  @TagAttribute()
+  @UIComponentTagAttribute(type = "boolean", defaultValue = "false", generate = false)
+  public void setAllowCustom(ValueExpression allowCustom) {
+    this.allowCustom = allowCustom;
+  }
+
+  /**
+   * The value binding expression linking this
+   * component to a property in a backing bean.
    */
   @TagAttribute
-  @UIComponentTagAttribute(
-          type = {},
-          expression = DynamicExpression.METHOD_EXPRESSION_REQUIRED,
-          methodSignature = "javax.faces.event.ValueChangeEvent")
-  public void setValueChangeListener(final MethodExpression valueChangeListener) {
-    this.valueChangeListener = valueChangeListener;
+  @UIComponentTagAttribute(type = "javax.faces.component.UIComponent")
+  public void setBinding(final ValueExpression binding) {
+    this.binding = binding;
+  }
+
+  /**
+   * An expression that specifies the Converter for this component.
+   * If the value binding expression is a String,
+   * the String is used as an ID to look up a Converter.
+   * If the value binding expression is a Converter,
+   * uses that instance as the converter.
+   * The value can either be a static value (ID case only)
+   * or an EL expression.
+   */
+  @TagAttribute
+  @UIComponentTagAttribute(type = "javax.faces.convert.Converter",
+      expression = DynamicExpression.VALUE_EXPRESSION)
+  public void setConverter(final ValueExpression converter) {
+    this.converter = converter;
+  }
+
+  /**
+   * An expression that specifies the converter message
+   */
+  @TagAttribute
+  @UIComponentTagAttribute()
+  public void setConverterMessage(final ValueExpression converterMessage) {
+    this.converterMessage = converterMessage;
   }
 
   /**
@@ -237,21 +322,43 @@ public class SelectManyBoxExtensionTag extends TobagoExtensionBodyTagSupport {
   }
 
   /**
-   * Flag indicating that this component will prohibit changes by the user.
+   * The component identifier for the input field component inside of the container.
+   * This value must be unique within the closest parent component that is a naming container.
+   */
+  @TagAttribute(rtexprvalue = true)
+  @UIComponentTagAttribute
+  public void setFieldId(final String fieldId) {
+    this.fieldId = fieldId;
+  }
+
+  /**
+   * Flag indicating this component should receive the focus.
    */
   @TagAttribute
   @UIComponentTagAttribute(type = "boolean", defaultValue = "false")
-  public void setReadonly(final ValueExpression readonly) {
-    this.readonly = readonly;
+  public void setFocus(final ValueExpression focus) {
+    this.focus = focus;
   }
 
   /**
-   * Clientside script function to add to this component's onchange handler.
+   * Hide the dropdown, this is only useful with allowCustom=true
    */
-  @TagAttribute
-  @UIComponentTagAttribute()
-  public void setOnchange(final ValueExpression onchange) {
-    this.onchange = onchange;
+  @TagAttribute()
+  @UIComponentTagAttribute(type = "boolean", defaultValue = "false", generate = false)
+  public void setHideDropdown(ValueExpression hideDropdown) {
+    this.hideDropdown = hideDropdown;
+  }
+
+  /**
+   * The component identifier for this component.
+   * This value must be unique within the closest parent component that is a naming container.
+   * For tx components the id will be set to the container (e. g. the panel).
+   * To set the id of the input field, you have to use the attribute "fieldId".
+   */
+  @TagAttribute(rtexprvalue = true)
+  @UIComponentTagAttribute
+  public void setId(final String id) {
+    super.setId(id);
   }
 
   /**
@@ -265,92 +372,130 @@ public class SelectManyBoxExtensionTag extends TobagoExtensionBodyTagSupport {
   }
 
   /**
-   * The accessKey of this component.
+   * The width for the label component. Default: 'auto'.
+   * This value is used in the gridLayouts columns attribute.
+   * See gridLayout tag for valid values.
    */
   @TagAttribute
-  @UIComponentTagAttribute(type = "java.lang.Character")
-  public void setAccessKey(final ValueExpression accessKey) {
-    this.accessKey = accessKey;
+  @UIComponentTagAttribute()
+  public void setLabelWidth(final ValueExpression labelWidth) {
+    this.labelWidth = labelWidth;
   }
 
   /**
-   * A method binding EL expression,
-   * accepting FacesContext, UIComponent,
-   * and Object parameters, and returning void, that validates
-   * the component's local value.
+   * Indicate markup of this component.
+   * Possible value is 'none'. But this can be overridden in the theme.
    */
   @TagAttribute
-  @UIComponentTagAttribute(type = {},
-      expression = DynamicExpression.METHOD_EXPRESSION,
-      methodSignature = { "javax.faces.context.FacesContext", "javax.faces.component.UIComponent", "java.lang.Object" })
-  public void setValidator(final MethodExpression validator) {
-    this.validator = validator;
+  @UIComponentTagAttribute(defaultValue = "none", type = "java.lang.String[]")
+  public void setMarkup(final ValueExpression markup) {
+    this.markup = markup;
   }
 
   /**
-   * An expression that specifies the Converter for this component.
-   * If the value binding expression is a String,
-   * the String is used as an ID to look up a Converter.
-   * If the value binding expression is a Converter,
-   * uses that instance as the converter.
-   * The value can either be a static value (ID case only)
-   * or an EL expression.
+   * Javascript callback to handle custom search matching
+   *
+   * This is a select2 feature and will force select2=true
+   */
+  @TagAttribute()
+  @UIComponentTagAttribute(generate = false)
+  public void setMatcher(ValueExpression matcher) {
+    this.matcher = matcher;
+  }
+
+  /**
+   * Maximum number of characters that may be provided for a search term.
+   *
+   * This is a select2 feature and will force select2=true
+   */
+  @TagAttribute()
+  @UIComponentTagAttribute(type = "int", defaultValue = "0", generate = false)
+  public void setMaximumInputLength(ValueExpression maximumInputLength) {
+    this.maximumInputLength = maximumInputLength;
+  }
+
+  /**
+   * The maximum number of items that may be selected in a multi-select control.
+   * If the value of this option is less than 1, the number of selected items will not be limited.
+   *
+   * This is a select2 feature and will force select2=true
+   */
+  @TagAttribute()
+  @UIComponentTagAttribute(type = "int", defaultValue = "0", generate = false)
+  public void setMaximumSelectionLength(ValueExpression maximumSelectionLength) {
+    this.maximumSelectionLength = maximumSelectionLength;
+  }
+
+  /**
+   * Minimum number of characters required to start a search.
+   *
+   * This is a select2 feature and will force select2=true
+   */
+  @TagAttribute()
+  @UIComponentTagAttribute(type = "int", defaultValue = "0", generate = false)
+  public void setMinimumInputLength(ValueExpression minimumInputLength) {
+    this.minimumInputLength = minimumInputLength;
+  }
+
+  /**
+   * Clientside script function to add to this component's onchange handler.
    */
   @TagAttribute
-  @UIComponentTagAttribute(type = "javax.faces.convert.Converter",
-      expression = DynamicExpression.VALUE_EXPRESSION)
-  public void setConverter(final ValueExpression converter) {
-    this.converter = converter;
+  @UIComponentTagAttribute()
+  public void setOnchange(final ValueExpression onchange) {
+    this.onchange = onchange;
   }
 
   /**
-   * Flag indicating whether or not this component should be rendered
-   * (during Render Response Phase), or processed on any subsequent form submit.
+   * Displays a short text in the input field, that describes the meaning of this field.
+   * This is part of HTML 5, the theme should emulate the behaviour, when the browser doesn't support it.
+   * <p/>
+   * The text will not be displayed, when the input field is readonly or disabled.
+   * @param placeholder The text to display
    */
   @TagAttribute
-  @UIComponentTagAttribute(type = "boolean", defaultValue = "true")
-  public void setRendered(final ValueExpression rendered) {
-    this.rendered = rendered;
+  @UIComponentTagAttribute
+  public void setPlaceholder(ValueExpression placeholder) {
+    this.placeholder = placeholder;
   }
 
   /**
-   * The value binding expression linking this
-   * component to a property in a backing bean.
+   * Flag indicating that this component will prohibit changes by the user.
    */
   @TagAttribute
-  @UIComponentTagAttribute(type = "javax.faces.component.UIComponent")
-  public void setBinding(final ValueExpression binding) {
-    this.binding = binding;
+  @UIComponentTagAttribute(type = "boolean", defaultValue = "false")
+  public void setReadonly(final ValueExpression readonly) {
+    this.readonly = readonly;
   }
 
   /**
-   * Text value to display as tooltip.
+   * Flag indicating whether or not this component should be rendered
+   * (during Render Response Phase), or processed on any subsequent form submit.
    */
   @TagAttribute
-  @UIComponentTagAttribute()
-  public void setTip(final ValueExpression tip) {
-    this.tip = tip;
+  @UIComponentTagAttribute(type = "boolean", defaultValue = "true")
+  public void setRendered(final ValueExpression rendered) {
+    this.rendered = rendered;
   }
 
   /**
-   * The width for the label component. Default: 'auto'.
-   * This value is used in the gridLayouts columns attribute.
-   * See gridLayout tag for valid values.
+   * Flag indicating that a value is required.
+   * If the value is an empty string a
+   * ValidationError occurs and a Error Message is rendered.
    */
   @TagAttribute
-  @UIComponentTagAttribute()
-  public void setLabelWidth(final ValueExpression labelWidth) {
-    this.labelWidth = labelWidth;
+  @UIComponentTagAttribute(type = "boolean", defaultValue = "false")
+  public void setRequired(final ValueExpression required) {
+    this.required = required;
   }
 
   /**
-   * Indicate markup of this component.
-   * Possible value is 'none'. But this can be overridden in the theme.
+   * An expression that specifies the required message
    */
   @TagAttribute
-  @UIComponentTagAttribute(defaultValue = "none", type = "java.lang.String[]")
-  public void setMarkup(final ValueExpression markup) {
-    this.markup = markup;
+  @UIComponentTagAttribute()
+  public void setRequiredMessage(final ValueExpression requiredMessage) {
+    this.requiredMessage = requiredMessage;
   }
 
   @TagAttribute
@@ -360,60 +505,78 @@ public class SelectManyBoxExtensionTag extends TobagoExtensionBodyTagSupport {
   }
 
   /**
-   * Flag indicating this component should receive the focus.
+   * Text value to display as tooltip.
    */
   @TagAttribute
-  @UIComponentTagAttribute(type = "boolean", defaultValue = "false")
-  public void setFocus(final ValueExpression focus) {
-    this.focus = focus;
+  @UIComponentTagAttribute()
+  public void setTip(final ValueExpression tip) {
+    this.tip = tip;
   }
 
   /**
-   * An expression that specifies the validator message
+   * A javascript callback that handles automatic tokenization of free-text entry.
    */
-  @TagAttribute
-  @UIComponentTagAttribute()
-  public void setValidatorMessage(final ValueExpression validatorMessage) {
-    this.validatorMessage = validatorMessage;
+  @TagAttribute()
+  @UIComponentTagAttribute(generate = false)
+  public void setTokenizer(ValueExpression tokenizer) {
+    this.tokenizer = tokenizer;
   }
 
   /**
-   * An expression that specifies the converter message
+   * The list of characters that should be used as token separators.
+   */
+  @TagAttribute()
+  @UIComponentTagAttribute(type = "java.lang.String[]", generate = false)
+  public void setTokenSeparators(ValueExpression tokenSeparators) {
+    this.tokenSeparators = tokenSeparators;
+  }
+
+  /**
+   * A method binding EL expression,
+   * accepting FacesContext, UIComponent,
+   * and Object parameters, and returning void, that validates
+   * the component's local value.
    */
   @TagAttribute
-  @UIComponentTagAttribute()
-  public void setConverterMessage(final ValueExpression converterMessage) {
-    this.converterMessage = converterMessage;
+  @UIComponentTagAttribute(type = {},
+      expression = DynamicExpression.METHOD_EXPRESSION,
+      methodSignature = { "javax.faces.context.FacesContext", "javax.faces.component.UIComponent", "java.lang.Object" })
+  public void setValidator(final MethodExpression validator) {
+    this.validator = validator;
   }
 
   /**
-   * An expression that specifies the required message
+   * An expression that specifies the validator message
    */
   @TagAttribute
   @UIComponentTagAttribute()
-  public void setRequiredMessage(final ValueExpression requiredMessage) {
-    this.requiredMessage = requiredMessage;
+  public void setValidatorMessage(final ValueExpression validatorMessage) {
+    this.validatorMessage = validatorMessage;
   }
-  
+
   /**
-   * The component identifier for the input field component inside of the container.
-   * This value must be unique within the closest parent component that is a naming container.
+   * The current value of this component.
    */
-  @TagAttribute(rtexprvalue = true)
-  @UIComponentTagAttribute
-  public void setFieldId(final String fieldId) {
-    this.fieldId = fieldId;
+  @TagAttribute
+  @UIComponentTagAttribute(type = {"java.lang.Object[]", "java.util.List"})
+  public void setValue(final ValueExpression value) {
+    this.value = value;
   }
 
   /**
-   * The component identifier for this component.
-   * This value must be unique within the closest parent component that is a naming container.
-   * For tx components the id will be set to the container (e. g. the panel).
-   * To set the id of the input field, you have to use the attribute "fieldId".
+   * MethodBinding representing a value change listener method
+   * that will be notified when a new value has been set for this input component.
+   * The expression must evaluate to a public method that takes a ValueChangeEvent
+   * parameter, with a return type of void.
+   *
+   * @param valueChangeListener
    */
-  @TagAttribute(rtexprvalue = true)
-  @UIComponentTagAttribute
-  public void setId(final String id) {
-    super.setId(id);
+  @TagAttribute
+  @UIComponentTagAttribute(
+      type = {},
+      expression = DynamicExpression.METHOD_EXPRESSION_REQUIRED,
+      methodSignature = "javax.faces.event.ValueChangeEvent")
+  public void setValueChangeListener(final MethodExpression valueChangeListener) {
+    this.valueChangeListener = valueChangeListener;
   }
 }