myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lof...@apache.org
Subject svn commit: r1583581 - in /myfaces/tobago/branches/tobago-3.0.x: tobago-core/src/main/java/org/apache/myfaces/tobago/context/ tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/ tobago-core/src/main/java/org/apache/myfaces/tobago/in...
Date Tue, 01 Apr 2014 09:23:47 GMT
Author: lofwyr
Date: Tue Apr  1 09:23:46 2014
New Revision: 1583581

URL: http://svn.apache.org/r1583581
Log:
access client properties

Modified:
    myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/context/ClientProperties.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIGridLayout.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/context/ClientPropertiesKey.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/LayoutComponentRendererBase.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/TobagoRenderKit.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/css/Classes.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/VariableResolverUtils.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-addressbook/src/main/java/org/apache/myfaces/tobago/example/addressbook/web/Controller.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-demo/src/main/java/org/apache/myfaces/tobago/example/demo/clientConfig/ClientConfigController.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/ClientConfigController.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/PageRenderer.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SeparatorRenderer.java
    myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/TreeMenuNodeRenderer.java

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/context/ClientProperties.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/context/ClientProperties.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/context/ClientProperties.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/context/ClientProperties.java
Tue Apr  1 09:23:46 2014
@@ -38,7 +38,7 @@ import java.util.Locale;
  * <p/>
  * The managed bean name which is Tobago using for the instance is {@link #MANAGED_BEAN_NAME}.
  * <p/>
- * Please use {@link org.apache.myfaces.tobago.util.VariableResolverUtils#resolveClientProperties(FacesContext)}
+ * Please use {@link ClientProperties#getInstance(javax.faces.context.FacesContext)}
  * to access to the users client properties.
  */
 
@@ -101,6 +101,9 @@ public class ClientProperties implements
     reset();
   }
 
+  /**
+   * Static method to access to the ClientProperties managed bean.
+   */
   public static ClientProperties getInstance(final FacesContext facesContext) {
     return (ClientProperties) VariableResolverUtils.resolveVariable(facesContext, MANAGED_BEAN_NAME);
   }

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIGridLayout.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIGridLayout.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIGridLayout.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIGridLayout.java
Tue Apr  1 09:23:46 2014
@@ -41,7 +41,6 @@ import org.apache.myfaces.tobago.layout.
 import org.apache.myfaces.tobago.layout.Orientation;
 import org.apache.myfaces.tobago.layout.PixelLayoutToken;
 import org.apache.myfaces.tobago.layout.RelativeLayoutToken;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -280,8 +279,7 @@ public abstract class AbstractUIGridLayo
         available = available.subtractNotNegative(LayoutUtils.getBorderEnd(orientation, container));
 
         if (grid.isOverflow(orientation.other())) {
-          final ClientProperties client
-              = VariableResolverUtils.resolveClientProperties(FacesContext.getCurrentInstance());
+          final ClientProperties client = ClientProperties.getInstance(FacesContext.getCurrentInstance());
           final Measure scrollbar = orientation
               == Orientation.HORIZONTAL ? client.getVerticalScrollbarWeight() : client.getHorizontalScrollbarWeight();
           available = available.subtractNotNegative(scrollbar);

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/context/ClientPropertiesKey.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/context/ClientPropertiesKey.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/context/ClientPropertiesKey.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/context/ClientPropertiesKey.java
Tue Apr  1 09:23:46 2014
@@ -22,7 +22,6 @@ package org.apache.myfaces.tobago.intern
 import org.apache.myfaces.tobago.context.ClientProperties;
 import org.apache.myfaces.tobago.context.Theme;
 import org.apache.myfaces.tobago.context.UserAgent;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 
 import javax.faces.component.UIViewRoot;
 import javax.faces.context.FacesContext;
@@ -45,7 +44,7 @@ public final class ClientPropertiesKey i
     final Map<Object, Object> attributes = facesContext.getAttributes();
     ClientPropertiesKey key = (ClientPropertiesKey) attributes.get(KEY_IN_FACES_CONTEXT);
     if (key == null) {
-      final ClientProperties clientProperties = VariableResolverUtils.resolveClientProperties(facesContext);
+      final ClientProperties clientProperties = ClientProperties.getInstance(facesContext);
       key = new ClientPropertiesKey(clientProperties, facesContext.getViewRoot());
       attributes.put(KEY_IN_FACES_CONTEXT, key);
     }

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/LayoutComponentRendererBase.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/LayoutComponentRendererBase.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/LayoutComponentRendererBase.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/LayoutComponentRendererBase.java
Tue Apr  1 09:23:46 2014
@@ -23,7 +23,6 @@ import org.apache.myfaces.tobago.compone
 import org.apache.myfaces.tobago.config.Configurable;
 import org.apache.myfaces.tobago.context.ClientProperties;
 import org.apache.myfaces.tobago.layout.Measure;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 
 import javax.faces.context.FacesContext;
 
@@ -116,7 +115,7 @@ public abstract class LayoutComponentRen
   /** @deprecated since Tobago 3.0 */
   @Deprecated
   public Measure getVerticalScrollbarWeight(final FacesContext facesContext, final Configurable
component) {
-    final ClientProperties clientProperties = VariableResolverUtils.resolveClientProperties(facesContext);
+    final ClientProperties clientProperties = ClientProperties.getInstance(facesContext);
     final Measure weight = clientProperties.getVerticalScrollbarWeight();
     if (weight != null) {
       return weight;

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/TobagoRenderKit.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/TobagoRenderKit.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/TobagoRenderKit.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/TobagoRenderKit.java
Tue Apr  1 09:23:46 2014
@@ -23,11 +23,11 @@ import org.apache.myfaces.tobago.ajax.Aj
 import org.apache.myfaces.tobago.application.ProjectStage;
 import org.apache.myfaces.tobago.config.TobagoConfig;
 import org.apache.myfaces.tobago.context.Capability;
+import org.apache.myfaces.tobago.context.ClientProperties;
 import org.apache.myfaces.tobago.internal.webapp.DebugResponseWriterWrapper;
 import org.apache.myfaces.tobago.internal.webapp.HtmlResponseWriter;
 import org.apache.myfaces.tobago.internal.webapp.JsonResponseWriter;
 import org.apache.myfaces.tobago.internal.webapp.XmlResponseWriter;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 import org.apache.myfaces.tobago.webapp.TobagoResponseWriter;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -124,7 +124,7 @@ public class TobagoRenderKit extends Ren
     }
 
     // content type xhtml is not supported in every browser... e. g. IE 6, 7, 8
-    if (!VariableResolverUtils.resolveClientProperties(FacesContext.getCurrentInstance())
+    if (!ClientProperties.getInstance(FacesContext.getCurrentInstance())
         .getUserAgent().hasCapability(Capability.CONTENT_TYPE_XHTML)) {
       contentType = "text/html";
     }

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/css/Classes.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/css/Classes.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/css/Classes.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/renderkit/css/Classes.java
Tue Apr  1 09:23:46 2014
@@ -22,11 +22,11 @@ package org.apache.myfaces.tobago.render
 import org.apache.commons.collections.map.MultiKeyMap;
 import org.apache.myfaces.tobago.component.SupportsCss;
 import org.apache.myfaces.tobago.component.SupportsMarkup;
+import org.apache.myfaces.tobago.context.ClientProperties;
 import org.apache.myfaces.tobago.context.Markup;
 import org.apache.myfaces.tobago.context.Theme;
 import org.apache.myfaces.tobago.internal.util.Deprecation;
 import org.apache.myfaces.tobago.internal.util.StringUtils;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -112,7 +112,7 @@ public final class Classes {
       builder.append(sub);
     }
     if (markup != null) {
-      final Theme theme = VariableResolverUtils.resolveClientProperties(FacesContext.getCurrentInstance()).getTheme();
+      final Theme theme = ClientProperties.getInstance(FacesContext.getCurrentInstance()).getTheme();
       for (final String markupString : markup) {
         if (ignoreMarkupCheck || theme.getRenderersConfig().isMarkupSupported(rendererName,
markupString)) {
           builder.append(' ');

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/VariableResolverUtils.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/VariableResolverUtils.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/VariableResolverUtils.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/VariableResolverUtils.java
Tue Apr  1 09:23:46 2014
@@ -40,9 +40,13 @@ public final class VariableResolverUtils
 
   /**
    * Returns the ClientProperties object configured in the faces-config.
+   *
+   * @deprecated Since 2.0.0. Please use
+   * {@link org.apache.myfaces.tobago.context.ClientProperties#getInstance(javax.faces.context.FacesContext)}
    */
+  @Deprecated
   public static ClientProperties resolveClientProperties(final FacesContext facesContext)
{
-    return (ClientProperties) resolveVariable(facesContext, ClientProperties.MANAGED_BEAN_NAME);
+    return ClientProperties.getInstance(facesContext);
   }
   
   /**

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-addressbook/src/main/java/org/apache/myfaces/tobago/example/addressbook/web/Controller.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-addressbook/src/main/java/org/apache/myfaces/tobago/example/addressbook/web/Controller.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-addressbook/src/main/java/org/apache/myfaces/tobago/example/addressbook/web/Controller.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-addressbook/src/main/java/org/apache/myfaces/tobago/example/addressbook/web/Controller.java
Tue Apr  1 09:23:46 2014
@@ -32,7 +32,6 @@ import org.apache.myfaces.tobago.example
 import org.apache.myfaces.tobago.example.addressbook.Picture;
 import org.apache.myfaces.tobago.model.SelectItem;
 import org.apache.myfaces.tobago.model.SheetState;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -121,7 +120,7 @@ public class Controller implements Seria
       themeItems.add(new SelectItem(theme, theme.getDisplayName()));
     }
 
-    final ClientProperties client = VariableResolverUtils.resolveClientProperties(facesContext);
+    final ClientProperties client = ClientProperties.getInstance(facesContext);
     theme = client.getTheme();
     currentAddressList = addressDao.findAddresses(searchCriterion);
   }
@@ -216,7 +215,7 @@ public class Controller implements Seria
 
   public String themeChanged() {
     final FacesContext facesContext = FacesContext.getCurrentInstance();
-    final ClientProperties client = VariableResolverUtils.resolveClientProperties(facesContext);
+    final ClientProperties client = ClientProperties.getInstance(facesContext);
     client.setTheme(theme);
     return null;
   }

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-demo/src/main/java/org/apache/myfaces/tobago/example/demo/clientConfig/ClientConfigController.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-demo/src/main/java/org/apache/myfaces/tobago/example/demo/clientConfig/ClientConfigController.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-demo/src/main/java/org/apache/myfaces/tobago/example/demo/clientConfig/ClientConfigController.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-demo/src/main/java/org/apache/myfaces/tobago/example/demo/clientConfig/ClientConfigController.java
Tue Apr  1 09:23:46 2014
@@ -93,12 +93,12 @@ public class ClientConfigController {
 // ///////////////////////////////////////////// logic
 
   public void storeInClientProperties() {
-    final ClientProperties client = VariableResolverUtils.resolveClientProperties(FacesContext.getCurrentInstance());
+    final ClientProperties client = ClientProperties.getInstance(FacesContext.getCurrentInstance());
     client.setTheme(theme);
   }
 
   public void loadFromClientProperties() {
-    final ClientProperties client = VariableResolverUtils.resolveClientProperties(FacesContext.getCurrentInstance());
+    final ClientProperties client = ClientProperties.getInstance(FacesContext.getCurrentInstance());
     theme = client.getTheme();
   }
 

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/ClientConfigController.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/ClientConfigController.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/ClientConfigController.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-example/tobago-example-test/src/main/java/org/apache/myfaces/tobago/example/test/ClientConfigController.java
Tue Apr  1 09:23:46 2014
@@ -23,7 +23,6 @@ import org.apache.myfaces.tobago.config.
 import org.apache.myfaces.tobago.context.ClientProperties;
 import org.apache.myfaces.tobago.context.Theme;
 import org.apache.myfaces.tobago.internal.util.ObjectUtils;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 
 import javax.faces.application.Application;
 import javax.faces.context.FacesContext;
@@ -74,12 +73,12 @@ public class ClientConfigController {
 // ///////////////////////////////////////////// logic
 
   public void storeInClientProperties() {
-    final ClientProperties client = VariableResolverUtils.resolveClientProperties(FacesContext.getCurrentInstance());
+    final ClientProperties client = ClientProperties.getInstance(FacesContext.getCurrentInstance());
     client.setTheme(theme);
   }
 
   public void loadFromClientProperties() {
-    final ClientProperties client = VariableResolverUtils.resolveClientProperties(FacesContext.getCurrentInstance());
+    final ClientProperties client = ClientProperties.getInstance(FacesContext.getCurrentInstance());
     theme = client.getTheme();
   }
 

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/PageRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/PageRenderer.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/PageRenderer.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/PageRenderer.java
Tue Apr  1 09:23:46 2014
@@ -52,7 +52,6 @@ import org.apache.myfaces.tobago.renderk
 import org.apache.myfaces.tobago.renderkit.util.EncodeUtils;
 import org.apache.myfaces.tobago.renderkit.util.RenderUtils;
 import org.apache.myfaces.tobago.util.ComponentUtils;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 import org.apache.myfaces.tobago.webapp.Secret;
 import org.apache.myfaces.tobago.webapp.TobagoResponseWriter;
 import org.slf4j.Logger;
@@ -141,7 +140,7 @@ public class PageRenderer extends PageRe
     final String contentType = writer.getContentTypeWithCharSet();
     ResponseUtils.ensureContentTypeHeader(facesContext, contentType);
     final String clientId = page.getClientId(facesContext);
-    final ClientProperties client = VariableResolverUtils.resolveClientProperties(facesContext);
+    final ClientProperties client = ClientProperties.getInstance(facesContext);
     final boolean productionMode = tobagoConfig.getProjectStage() == ProjectStage.Production;
     final boolean preventFrameAttacks = tobagoConfig.isPreventFrameAttacks();
 
@@ -412,9 +411,10 @@ public class PageRenderer extends PageRe
     }
 
     final String clientId = page.getClientId(facesContext);
+    final ClientProperties clientProperties = ClientProperties.getInstance(facesContext);
 
     // avoid submit page in ie if the form contains only one input and you press the enter
key in the input
-    if (VariableResolverUtils.resolveClientProperties(facesContext).getUserAgent().isMsie())
{
+    if (clientProperties.getUserAgent().isMsie()) {
       writer.startElement(HtmlElements.INPUT, null);
       writer.writeAttribute(HtmlAttributes.TYPE, HtmlInputTypes.TEXT, false);
       writer.writeAttribute(HtmlAttributes.NAME, "tobago.dummy", false);

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SeparatorRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SeparatorRenderer.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SeparatorRenderer.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/SeparatorRenderer.java
Tue Apr  1 09:23:46 2014
@@ -23,6 +23,7 @@ import org.apache.myfaces.tobago.compone
 import org.apache.myfaces.tobago.component.UILabel;
 import org.apache.myfaces.tobago.component.UISeparator;
 import org.apache.myfaces.tobago.config.Configurable;
+import org.apache.myfaces.tobago.context.ClientProperties;
 import org.apache.myfaces.tobago.internal.util.Deprecation;
 import org.apache.myfaces.tobago.internal.util.StringUtils;
 import org.apache.myfaces.tobago.layout.Measure;
@@ -34,7 +35,6 @@ import org.apache.myfaces.tobago.renderk
 import org.apache.myfaces.tobago.renderkit.html.HtmlElements;
 import org.apache.myfaces.tobago.renderkit.html.HtmlRoleValues;
 import org.apache.myfaces.tobago.renderkit.html.util.HtmlRendererUtils;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 import org.apache.myfaces.tobago.webapp.TobagoResponseWriter;
 
 import javax.faces.component.UIComponent;
@@ -51,7 +51,7 @@ public class SeparatorRenderer extends L
     String label = getLabel(separator);
 
     if (label != null) {
-      if (VariableResolverUtils.resolveClientProperties(facesContext).getUserAgent().isMsie())
{
+      if (ClientProperties.getInstance(facesContext).getUserAgent().isMsie()) {
         label = StringUtils.replace(label, " ", HtmlUtils.CHAR_NON_BEAKING_SPACE);
       }
 

Modified: myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/TreeMenuNodeRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/TreeMenuNodeRenderer.java?rev=1583581&r1=1583580&r2=1583581&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/TreeMenuNodeRenderer.java
(original)
+++ myfaces/tobago/branches/tobago-3.0.x/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/standard/standard/tag/TreeMenuNodeRenderer.java
Tue Apr  1 09:23:46 2014
@@ -20,6 +20,7 @@
 package org.apache.myfaces.tobago.renderkit.html.standard.standard.tag;
 
 import org.apache.myfaces.tobago.component.UITreeNode;
+import org.apache.myfaces.tobago.context.ClientProperties;
 import org.apache.myfaces.tobago.context.ResourceManagerUtils;
 import org.apache.myfaces.tobago.context.UserAgent;
 import org.apache.myfaces.tobago.internal.component.AbstractUIData;
@@ -32,7 +33,6 @@ import org.apache.myfaces.tobago.renderk
 import org.apache.myfaces.tobago.renderkit.html.HtmlElements;
 import org.apache.myfaces.tobago.renderkit.html.util.HtmlRendererUtils;
 import org.apache.myfaces.tobago.util.ComponentUtils;
-import org.apache.myfaces.tobago.util.VariableResolverUtils;
 import org.apache.myfaces.tobago.webapp.TobagoResponseWriter;
 
 import javax.faces.component.UIComponent;
@@ -50,8 +50,7 @@ public class TreeMenuNodeRenderer extend
     final boolean dataRendersRowContainer = data.isRendersRowContainer();
     final boolean folder = node.isFolder();
     final String clientId = node.getClientId(facesContext);
-    final boolean ie6
-        = VariableResolverUtils.resolveClientProperties(facesContext).getUserAgent().equals(UserAgent.MSIE_6_0);
+    final boolean ie6 = ClientProperties.getInstance(facesContext).getUserAgent().equals(UserAgent.MSIE_6_0);
     final String parentId = data.getRowParentClientId();
     final boolean visible = data.isRowVisible();
 



Mime
View raw message