You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by de...@apache.org on 2017/09/17 12:30:03 UTC
[myfaces-trinidad] 05/07: TRINIDAD-1041
This is an automated email from the ASF dual-hosted git repository.
deki pushed a commit to branch 1.2.12.5.0-branch
in repository https://gitbox.apache.org/repos/asf/myfaces-trinidad.git
commit 81eb2d4568dc5477cfd7ccc87b72275543e1834d
Author: Scott Bryan <so...@apache.org>
AuthorDate: Wed Jan 18 20:56:20 2012 +0000
TRINIDAD-1041
---
src/site/xdoc/devguide/skinning.xml | 20 ++++++-
.../src/main/webapp/WEB-INF/trinidad-skins.xml | 8 +++
.../src/main/webapp/demos/panelPageSkinDemo.jspx | 3 +-
.../skin/SkinCSSDocumentHandler.java | 64 +++++++++++++++++-----
.../trinidadinternal/skin/SkinStyleSheetNode.java | 23 ++++++--
.../skin/SkinStyleSheetParserUtils.java | 2 +-
.../style/xml/parse/StyleSheetNode.java | 5 +-
.../style/xml/parse/StyleSheetNodeParser.java | 35 +++---------
.../style/xml/parse/StyleSheetNodeEqualsTest.java | 30 ++--------
9 files changed, 113 insertions(+), 77 deletions(-)
diff --git a/src/site/xdoc/devguide/skinning.xml b/src/site/xdoc/devguide/skinning.xml
index 184adce..9efd892 100644
--- a/src/site/xdoc/devguide/skinning.xml
+++ b/src/site/xdoc/devguide/skinning.xml
@@ -897,6 +897,11 @@ public class SkinTranslationMapDemo
This is to define styles only for a particular accessibility profile. See the <a href="configuration.html#accessibility-profile">Configuring Apache Trinidad</a> chapter for information on setting the accessibility profile.
</li>
<li>
+ <strong>@locale</strong> {/skin definitions go here/} - >
+ A certain locale must be specified, either only the language or both the language and the country.
+ This is to define styles only for a particular language and country.
+ </li>
+ <li>
<strong>:rtl</strong> - > pseudo-class to create a style or icon definition when the browser
is in a right-to-left language. The best example is that of images that are not symmetric.
If you set a skin selector that uses a asymmetrical image, when you set your browser to
@@ -904,7 +909,7 @@ public class SkinTranslationMapDemo
you use the :rtl pseudo-class at the end of your selector and point it to a flipped-looking image.
</li>
<li>
- :lang or @locale - > Not yet implemented in Trinidad.
+ :lang - > Not yet implemented in Trinidad.
</li>
</ul>
@@ -934,11 +939,22 @@ public class SkinTranslationMapDemo
}
/* for Firefox 3 (gecko 1.9) use a smaller margin.*/
- @agent gecko (version: 1.9)
+ @agent gecko and (version: 1.9)
{
af|someComponent {margin: 4px;}
}
+ @locale en, de {
+ af|commandButton {
+ color: red;
+ }
+ }
+ @locale ro-RO {
+ af|commandButton {
+ color: blue;
+ }
+ }
+
/* The following selectors are for all platforms and all browsers */
/* rounded corners on the top-start and top-end */
diff --git a/trinidad-examples/trinidad-demo/src/main/webapp/WEB-INF/trinidad-skins.xml b/trinidad-examples/trinidad-demo/src/main/webapp/WEB-INF/trinidad-skins.xml
index 7d97123..35e3dc7 100644
--- a/trinidad-examples/trinidad-demo/src/main/webapp/WEB-INF/trinidad-skins.xml
+++ b/trinidad-examples/trinidad-demo/src/main/webapp/WEB-INF/trinidad-skins.xml
@@ -124,4 +124,12 @@
<style-sheet-name>skins/accdemo/accdemo.css</style-sheet-name>
</skin>
+ <!-- A skin which demonstrates locale features,
+ eg. @locale -->
+ <skin>
+ <id>localedemo.desktop</id>
+ <family>localeDemo</family>
+ <render-kit-id>org.apache.myfaces.trinidad.desktop</render-kit-id>
+ <style-sheet-name>skins/localedemo/localedemo.css</style-sheet-name>
+ </skin>
</skins>
diff --git a/trinidad-examples/trinidad-demo/src/main/webapp/demos/panelPageSkinDemo.jspx b/trinidad-examples/trinidad-demo/src/main/webapp/demos/panelPageSkinDemo.jspx
index c5c118f..ad6632b 100644
--- a/trinidad-examples/trinidad-demo/src/main/webapp/demos/panelPageSkinDemo.jspx
+++ b/trinidad-examples/trinidad-demo/src/main/webapp/demos/panelPageSkinDemo.jspx
@@ -86,6 +86,7 @@
<tr:selectItem label="purpleBigFont" value="purpleBigFont"/>
<tr:selectItem label="beach" value="beach"/>
<tr:selectItem label="suede" value="suede"/>
+ <tr:selectItem label="locale" value="localeDemo"/>
</tr:selectOneChoice>
<tr:commandButton text="Go"/>
<tr:goLink id="goLinkId" text="EmailablePageMode"
@@ -156,7 +157,7 @@
</tr:showDetailItem>
<tr:showDetailItem text="Tab 2" disclosed="true">
<tr:panelHeader text="PanelTabbed details">
- <tr:outputText value="Everything in Camping is on sale! Enjoy huge savings on our most popular tents and sleeping bags. We even have dried food and mattresses"
+ <tr:outputText value="In Locale Skin, commandButton text is red in en and de locales and blue in ro-RO. Test it out!"
styleClass="mainContentText"/>
<tr:panelGroupLayout layout="horizontal">
<tr:goButton text="Sorry, Disabled" disabled="true"/>
diff --git a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinCSSDocumentHandler.java b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinCSSDocumentHandler.java
index 060c4ae..828a744 100644
--- a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinCSSDocumentHandler.java
+++ b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinCSSDocumentHandler.java
@@ -19,15 +19,17 @@
package org.apache.myfaces.trinidadinternal.skin;
import java.io.StringReader;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.LinkedList;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+import java.util.Collections;
import java.util.List;
import java.util.Map;
+import java.util.ArrayList;
+import java.util.Locale;
import java.util.Set;
-import java.util.regex.Matcher;
-import java.util.regex.Pattern;
+import java.util.HashSet;
+import java.util.HashMap;
+import java.util.LinkedList;
import org.apache.myfaces.trinidad.context.Version;
import org.apache.myfaces.trinidad.logging.TrinidadLogger;
@@ -112,6 +114,7 @@ public class SkinCSSDocumentHandler
CompleteSelectorNode node =
_createCompleteSelectorNode(selector,
_propertyNodeList,
+ _locales,
_selectorAgents,
_selectorPlatforms,
_getSelectorAccProperties());
@@ -189,6 +192,10 @@ public class SkinCSSDocumentHandler
{
_parseCustomAtRule(_AT_PLATFORM, atRule);
}
+ else if (atRule.startsWith(_AT_LOCALE))
+ {
+ _parseCustomAtRule(_AT_LOCALE, atRule);
+ }
else if (atRule.startsWith(_AT_ACC_PROFILE))
{
_parseCustomAtRule(_AT_ACC_PROFILE, atRule);
@@ -204,8 +211,8 @@ public class SkinCSSDocumentHandler
*/
private void _parseCustomAtRule(String type, String atRule)
{
- // get the @agent agents, they are deliminated by commas
- // parse out the content
+ // get the @agent agents, @platform platforms or the @locale locales
+ // they are deliminated by commas parse out the content
// save the atRule type, so the document handler code can get to it.
// run this through parser again
String content = _getAtRuleContent(atRule);
@@ -228,6 +235,8 @@ public class SkinCSSDocumentHandler
_selectorAgents = null;
else if (_AT_PLATFORM.equals(type))
_selectorPlatforms = null;
+ else if (_AT_LOCALE.equals(type))
+ _locales = null;
else if (_AT_ACC_PROFILE.equals(type))
{
assert(!_selectorAccPropertiesStack.isEmpty());
@@ -242,6 +251,7 @@ public class SkinCSSDocumentHandler
private CompleteSelectorNode _createCompleteSelectorNode(
String selector,
List<PropertyNode> propertyNodeList,
+ Set<Locale> locales,
Map<Integer, Set<Version>> selectorAgentVersions,
int[] selectorPlatforms,
Set<String> selectorAccProperties)
@@ -268,6 +278,7 @@ public class SkinCSSDocumentHandler
new CompleteSelectorNode(
selector,
propertyNodeList,
+ locales,
direction,
selectorAgentVersions,
selectorPlatforms,
@@ -295,6 +306,7 @@ public class SkinCSSDocumentHandler
int direction = completeSelectorNode.getDirection();
Map<Integer, Set<Version>> agentVersions = completeSelectorNode.getAgentVersions();
int[] platforms = completeSelectorNode.getPlatforms();
+ Set<Locale> locales = completeSelectorNode.getLocales();
Set<String> accProperties = completeSelectorNode.getAccessibilityProperties();
// loop through the skinStyleSheetNodeList to find a match
@@ -306,7 +318,7 @@ public class SkinCSSDocumentHandler
for (int i = skinStyleSheetNodes.size() - 1; i >= 0 && !match; --i)
{
SkinStyleSheetNode ssNode = skinStyleSheetNodes.get(i);
- match = ssNode.matches(direction, agentVersions, platforms, accProperties);
+ match = ssNode.matches(direction, agentVersions, platforms, locales, accProperties);
if (match)
ssNode.add(completeSelectorNode.getSkinSelectorPropertiesNode());
}
@@ -315,7 +327,7 @@ public class SkinCSSDocumentHandler
{
// no matching stylesheet node found, so create a new one
SkinStyleSheetNode ssNode =
- new SkinStyleSheetNode(namespaceMap, direction, agentVersions, platforms, accProperties);
+ new SkinStyleSheetNode(namespaceMap, direction, locales, agentVersions, platforms, accProperties);
ssNode.add(completeSelectorNode.getSkinSelectorPropertiesNode());
skinStyleSheetNodes.add(ssNode);
}
@@ -326,7 +338,7 @@ public class SkinCSSDocumentHandler
/**
* Initialized at rule target types.
*
- * @param type type of the at rule. _AT_AGENT, _AT_PLATFORM, or _AT_ACC_PROFILE
+ * @param type type of the at rule. _AT_AGENT, _AT_PLATFORM, _AT_ACC_PROFILE or _AT_LOCALE
* @param atRule - the atRule string
*/
private void _initAtRuleTargetTypes(
@@ -402,6 +414,15 @@ public class SkinCSSDocumentHandler
_selectorPlatforms = _getIntArray(list);
}
+ else if (_AT_LOCALE.equals(type))
+ {
+ _locales = new HashSet<Locale>();
+ for (int i = 0; i < typeArray.length; i++)
+ {
+ Locale locale = LocaleUtils.getLocaleForIANAString(typeArray[i].replace('_', '-').trim());
+ _locales.add(locale);
+ }
+ }
else if (_AT_ACC_PROFILE.equals(type))
{
// The number of profile properties is always going to be
@@ -544,6 +565,7 @@ public class SkinCSSDocumentHandler
public CompleteSelectorNode(
String selectorName,
List<PropertyNode> propertyNodes,
+ Set<Locale> locales,
int direction,
Map<Integer, Set<Version>> agentVersions,
int[] platforms,
@@ -554,11 +576,13 @@ public class SkinCSSDocumentHandler
_direction = direction;
// copy the agents and platforms because these get nulled out
// at the end of the @rule parsing.
- _agentVersions = agentVersions != null ?
+ _agentVersions = (agentVersions != null) ?
new HashMap<Integer, Set<Version>>(agentVersions) :
new HashMap<Integer, Set<Version>>();
_platforms = _copyIntArray(platforms);
+ _locales = ((locales != null) ? new HashSet<Locale>(locales)
+ :Collections.<Locale>emptySet());
if (accProperties != null)
{
@@ -592,6 +616,11 @@ public class SkinCSSDocumentHandler
return _platforms;
}
+ public Set<Locale> getLocales()
+ {
+ return _locales;
+ }
+
public Set<String> getAccessibilityProperties()
{
return _accProperties;
@@ -613,12 +642,14 @@ public class SkinCSSDocumentHandler
private int _direction; // the reading direction
private Map<Integer, Set<Version>> _agentVersions;
private int[] _platforms;
+ private Set<Locale> _locales;
private Set<String> _accProperties;
}
- private static String _AT_AGENT = "@agent";
- private static String _AT_PLATFORM = "@platform";
- private static String _AT_ACC_PROFILE = "@accessibility-profile";
+ private static final String _AT_AGENT = "@agent";
+ private static final String _AT_PLATFORM = "@platform";
+ private static final String _AT_LOCALE = "@locale";
+ private static final String _AT_ACC_PROFILE = "@accessibility-profile";
// below are properties that we set and reset
// as the methods of this documentHandler get called.
@@ -636,6 +667,9 @@ public class SkinCSSDocumentHandler
// we store a map of agents and their version sets
private Map<Integer, Set<Version>> _selectorAgents = null;
+ // the locales of the selectors parsed in this document.
+ private Set<Locale> _locales = null;
+
// Stack of accessibility property sets. While java.util.Stack has the
// push/pop API that we want, we don't need the synchronization, so we
// just use a LinkedList instead and pretend its a stack.
diff --git a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinStyleSheetNode.java b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinStyleSheetNode.java
index c715209..1bd945d 100644
--- a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinStyleSheetNode.java
+++ b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinStyleSheetNode.java
@@ -21,6 +21,7 @@ package org.apache.myfaces.trinidadinternal.skin;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
+import java.util.Locale;
import java.util.Map;
import java.util.Set;
@@ -43,11 +44,13 @@ class SkinStyleSheetNode
List<SkinSelectorPropertiesNode> skinSelectorNodeList,
Map<String, String> namespaceMap,
int direction,
+ Set<Locale> locales,
Map<Integer, Set<Version>> agentVersions,
Set<String> accProperties)
{
_skinSelectorNodeList = skinSelectorNodeList;
_namespaceMap = namespaceMap;
+ _locales = locales;
_direction = direction;
_agentVersions = agentVersions;
_accProperties = accProperties;
@@ -56,12 +59,14 @@ class SkinStyleSheetNode
SkinStyleSheetNode(
Map<String, String> namespaceMap,
int direction,
+ Set<Locale> locales,
Map<Integer, Set<Version>> agentVersions,
int[] platforms,
Set<String> accProperties)
{
_namespaceMap = namespaceMap;
_direction = direction;
+ _locales = locales;
_agentVersions = agentVersions;
_platforms = platforms;
_accProperties = accProperties;
@@ -114,6 +119,11 @@ class SkinStyleSheetNode
return _platforms;
}
+ public Set<Locale> getLocales()
+ {
+ return _locales;
+ }
+
public Set<String> getAcessibilityProperties()
{
return _accProperties;
@@ -123,6 +133,7 @@ class SkinStyleSheetNode
int direction,
Map<Integer, Set<Version>> agentVersions,
int[] platforms,
+ Set<Locale> locales,
Set<String> accProperties)
{
if (direction == _direction)
@@ -134,10 +145,13 @@ class SkinStyleSheetNode
boolean platformsMatch = _intArraysEqual(platforms, _platforms);
if (platformsMatch)
{
- boolean accMatch = _setsEqual(accProperties, _accProperties);
-
- if (accMatch)
- return true;
+ boolean localeMatch = _setsEqual(locales, _locales);
+ if (localeMatch)
+ {
+ boolean accMatch = _setsEqual(accProperties, _accProperties);
+ if (accMatch)
+ return true;
+ }
}
}
}
@@ -166,6 +180,7 @@ class SkinStyleSheetNode
private Map<String, String> _namespaceMap;
private List<SkinSelectorPropertiesNode> _skinSelectorNodeList;
private int _direction; // reading direction
+ private Set<Locale> _locales;
private Map<Integer, Set<Version>> _agentVersions;
private int[] _platforms;
private Set<String> _accProperties;
diff --git a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinStyleSheetParserUtils.java b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinStyleSheetParserUtils.java
index 9902f21..3efe719 100644
--- a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinStyleSheetParserUtils.java
+++ b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/skin/SkinStyleSheetParserUtils.java
@@ -273,7 +273,7 @@ class SkinStyleSheetParserUtils
StyleSheetNode ssNode =
new StyleSheetNode(styleNodeArray,
iconNodeList,
- null,/*locales, not yet supported*/
+ skinSSNode.getLocales(),
skinSSNode.getDirection(),
skinSSNode.getAgentVersions(),
skinSSNode.getPlatforms(),
diff --git a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNode.java b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNode.java
index 81456b9..2cae0e2 100644
--- a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNode.java
+++ b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNode.java
@@ -55,7 +55,7 @@ public class StyleSheetNode
public StyleSheetNode(
StyleNode[] styles,
Collection<IconNode> icons,
- Locale[] locales,
+ Set<Locale> locales,
int direction,
Map<Integer, Set<Version>> agentVersions,
int[] platforms,
@@ -77,8 +77,7 @@ public class StyleSheetNode
// locales, browsers, versions, platforms order does not matter, so these are Sets.
if (locales != null)
{
- Set<Locale> localesSet = _copyLocaleArrayToSet(locales);
- _locales = Collections.unmodifiableSet(localesSet);
+ _locales = Collections.unmodifiableSet(locales);
}
else
_locales = Collections.emptySet();
diff --git a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNodeParser.java b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNodeParser.java
index 4240bda..a887483 100644
--- a/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNodeParser.java
+++ b/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNodeParser.java
@@ -19,6 +19,7 @@
package org.apache.myfaces.trinidadinternal.style.xml.parse;
import java.util.Arrays;
+import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Iterator;
@@ -37,6 +38,7 @@ import org.apache.myfaces.trinidadinternal.share.xml.XMLUtils;
import org.apache.myfaces.trinidadinternal.style.StyleConstants;
import org.apache.myfaces.trinidadinternal.style.util.NameUtils;
import org.apache.myfaces.trinidadinternal.style.xml.XMLConstants;
+import org.apache.myfaces.trinidadinternal.util.nls.LocaleUtils;
import org.xml.sax.Attributes;
import org.xml.sax.SAXParseException;
@@ -152,23 +154,6 @@ public class StyleSheetNodeParser extends BaseNodeParser
}
}
- // Converts a string to a locale
- private Locale _getLocale(String str)
- {
- // Language only
- int length = str.length();
- if (length == 2)
- return new Locale(str, "");
-
- // Locale and country
- if ((length == 5) && (str.charAt(2) == '_'))
- return new Locale(str.substring(0, 2), str.substring(3, 5));
-
- // We don't handle variants at the moment...
-
- return null;
- }
-
// Initialize locales
private void _initLocales(String localeAttr)
{
@@ -177,20 +162,16 @@ public class StyleSheetNodeParser extends BaseNodeParser
// -= Simon Lessard =-
// TODO: Check if synchronization is really needed.
- Vector<Locale> locales = new Vector<Locale>();
+ _locales = Collections.synchronizedSet(new HashSet<Locale>());
Iterator<String> tokens = _getTokens(localeAttr);
while (tokens.hasNext())
{
- Locale locale = _getLocale(tokens.next());
+ String localeString = tokens.next();
+ // TODO: check if the replace of _ with - is really necessary. Also see RequestContextImpl.getFormattingLocale()
+ Locale locale = LocaleUtils.getLocaleForIANAString(localeString.replace('_', '-').trim());
if (locale != null)
- locales.addElement(locale);
- }
-
- if (locales != null)
- {
- _locales = new Locale[locales.size()];
- locales.copyInto(_locales);
+ _locales.add(locale);
}
}
@@ -320,7 +301,7 @@ public class StyleSheetNodeParser extends BaseNodeParser
// -= Simon Lessard =-
// TODO: Check if synchronization is really needed.
private Vector<StyleNode> _styles;
- private Locale[] _locales;
+ private Set<Locale> _locales;
private int _direction;
private int _mode;
private int[] _browsers;
diff --git a/trinidad-impl/src/test/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNodeEqualsTest.java b/trinidad-impl/src/test/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNodeEqualsTest.java
index 4f8ca4e..b5f3767 100644
--- a/trinidad-impl/src/test/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNodeEqualsTest.java
+++ b/trinidad-impl/src/test/java/org/apache/myfaces/trinidadinternal/style/xml/parse/StyleSheetNodeEqualsTest.java
@@ -128,9 +128,8 @@ public class StyleSheetNodeEqualsTest extends TestCase
List<IconNode> anotherIconNodes = _getIconNodes();
// create locales arrays
- Locale[] localesArray = getLocalesArray();
- Locale[] anotherLocalesArray = getAnotherLocalesArray();
- Locale[] diffOrderLocalesArray = getDiffOrderLocalesArray();
+ Set<Locale> localeSet = getLocalesSet();
+ Set<Locale> diffOrderLocalesSet = getDiffOrderLocalesSet();
// create a browsers map
Map<Integer, Set<Version>> browsers = new HashMap<Integer, Set<Version>>();
@@ -165,7 +164,7 @@ public class StyleSheetNodeEqualsTest extends TestCase
StyleSheetNode styleSheetNode =
new StyleSheetNode(styleSheetOneNodes,
iconNodes,
- localesArray,
+ localeSet,
0,
browsers,
platforms,
@@ -174,7 +173,7 @@ public class StyleSheetNodeEqualsTest extends TestCase
StyleSheetNode anotherStyleSheetNode =
new StyleSheetNode(anotherStyleSheetOneNodes,
anotherIconNodes,
- anotherLocalesArray,
+ localeSet,
0,
anotherBrowsersDiffOrder,
anotherPlatforms,
@@ -183,7 +182,7 @@ public class StyleSheetNodeEqualsTest extends TestCase
StyleSheetNode sameDiffOrderStyleSheetNode =
new StyleSheetNode(anotherStyleSheetOneNodes,
anotherIconNodes,
- diffOrderLocalesArray,
+ diffOrderLocalesSet,
0,
anotherBrowsersDiffOrder,
differentOrderPlatforms,
@@ -207,7 +206,7 @@ public class StyleSheetNodeEqualsTest extends TestCase
// these should be false
assertEquals(styleSheetNode.equals(null), false);
- assertEquals(styleSheetNode.equals(localesArray), false);
+ assertEquals(styleSheetNode.equals(localeSet), false);
/* Test styleSheetNode's toString */
/*
@@ -303,23 +302,6 @@ public class StyleSheetNodeEqualsTest extends TestCase
return set;
}
- // same as above
- private Locale[] getLocalesArray()
- {
- return new Locale[] {new Locale("tw", "TW"), new Locale("zh", "CN")};
- }
-
- private Locale[] getAnotherLocalesArray()
- {
- return new Locale[] {new Locale("tw", "TW"), new Locale("zh", "CN")};
- }
-
- // same as above, different order
- private Locale[] getDiffOrderLocalesArray()
- {
- return new Locale[] {new Locale("zh", "CN"), new Locale("tw", "TW")};
- }
-
private List<IconNode> _getIconNodes()
{
List<IconNode> iconNodes = new ArrayList<IconNode>(2);
--
To stop receiving notification emails like this one, please contact
"commits@myfaces.apache.org" <co...@myfaces.apache.org>.