[jboss-cvs] jboss-seam/src/main/org/jboss/seam/theme ...
Gavin King
gavin.king at jboss.com
Tue Jan 23 17:35:48 EST 2007
User: gavin
Date: 07/01/23 17:35:48
Modified: src/main/org/jboss/seam/theme ThemeSelector.java
Log:
fix JBSEAM-670
Revision Changes Path
1.12 +5 -1 jboss-seam/src/main/org/jboss/seam/theme/ThemeSelector.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: ThemeSelector.java
===================================================================
RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/theme/ThemeSelector.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -b -r1.11 -r1.12
--- ThemeSelector.java 21 Dec 2006 02:38:28 -0000 1.11
+++ ThemeSelector.java 23 Jan 2007 22:35:48 -0000 1.12
@@ -4,6 +4,7 @@
import static org.jboss.seam.annotations.Install.BUILT_IN;
import java.util.ArrayList;
+import java.util.Arrays;
import java.util.List;
import java.util.MissingResourceException;
import java.util.ResourceBundle;
@@ -50,7 +51,10 @@
public void initDefaultTheme()
{
String themeName = getCookieValue();
- if (themeName!=null) setTheme(themeName);
+ if ( themeName!=null && Arrays.asList(availableThemes).contains(themeName) )
+ {
+ setTheme(themeName);
+ }
if (theme==null)
{
More information about the jboss-cvs-commits
mailing list