2007-02-19 Everaldo Canuto <everaldo@simios.org>
[mono.git] / mcs / class / Managed.Windows.Forms / System.Windows.Forms / ThemeEngine.cs
index 014a52581b0d7d880b79bc2606d739340b6a3131..d3d9f5eec86c2422710bc4fec0a8c73d2ff57ac2 100644 (file)
@@ -17,7 +17,7 @@
 // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
-// Copyright (c) 2004 Novell, Inc.
+// Copyright (c) 2004-2006 Novell, Inc.
 //
 // Authors:
 //     Jordi Mas i Hernandez, jordi@ximian.com
@@ -39,18 +39,21 @@ namespace System.Windows.Forms
 
                        theme_var = Environment.GetEnvironmentVariable("MONO_THEME");
 
-                       if (theme_var == null)
+                       if (theme_var == null) {
                                theme_var = "win32";
+                       } else {
+                               theme_var = theme_var.ToLower ();
+                       }
 
-                       theme_var.ToLower ();
-
-                       if (theme_var == "gtk")
+                       if (theme_var == "gtk") {
                                theme = new ThemeGtk ();
-                       else
-                       if ( theme_var == "nice" )
+                       } else if ( theme_var == "nice" ) {
                                theme = new ThemeNice ();
-                       else
+                       } else if ( theme_var == "clearlooks" ) {
+                               theme = new ThemeClearlooks ();
+                       } else {
                                theme = new ThemeWin32Classic ();
+                       }
                }