[asp.net] Implemented the 4.0 type, FileLevelMasterPageControlBuilder
[mono.git] / mcs / class / System.Web / System.Web.UI / PageTheme.cs
index 1f13ed2ef2617fe3c769cc3ac843c85104e67377..457808992a200c0f911bc7a5755fbc0780b498b0 100644 (file)
@@ -4,7 +4,7 @@
 // Authors:
 //   Chris Toshok (toshok@ximian.com)
 //
-// (C) 2006 Novell, Inc (http://www.novell.com)
+// (C) 2006-2010 Novell, Inc (http://www.novell.com)
 //
 // Permission is hereby granted, free of charge, to any person obtaining
 // a copy of this software and associated documentation files (the
@@ -26,8 +26,6 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-#if NET_2_0
-
 using System;
 using System.Collections;
 using System.ComponentModel;
@@ -38,77 +36,74 @@ namespace System.Web.UI {
        [EditorBrowsable (EditorBrowsableState.Advanced)]
        public abstract class PageTheme
        {
+               Page _page = null;
+
                protected PageTheme ()
                {
                }
 
-               [MonoTODO]
                public static object CreateSkinKey (Type controlType, string skinID)
                {
-                       return String.Format ("{0}:{1}", skinID, controlType);
+                       return string.Concat (skinID, ":", controlType);
                }
 
-               [MonoTODO]
                protected object Eval (string expression)
                {
-                       throw new NotImplementedException ();
+                       return Page.Eval (expression);
                }
 
-               [MonoTODO]
                protected string Eval (string expression, string format)
                {
-                       throw new NotImplementedException ();
+                       return Page.Eval (expression, format);
                }
 
-               [MonoTODO]
+               [MonoTODO("Not implemented")]
                public bool TestDeviceFilter (string deviceFilterName)
                {
                        throw new NotImplementedException ();
                }
 
-               [MonoTODO]
                protected object XPath (string xPathExpression)
                {
-                       throw new NotImplementedException ();
+                       return Page.XPath (xPathExpression);
                }
 
-               [MonoTODO]
                protected object XPath (string xPathExpression, IXmlNamespaceResolver resolver)
                {
-                       throw new NotImplementedException ();
+                       return Page.XPath (xPathExpression, resolver);
                }
 
-               [MonoTODO]
                protected string XPath (string xPathExpression, string format)
                {
-                       throw new NotImplementedException ();
+                       return Page.XPath (xPathExpression, format);
                }
 
-               [MonoTODO]
                protected string XPath (string xPathExpression, string format, IXmlNamespaceResolver resolver)
                {
-                       throw new NotImplementedException ();
+                       return Page.XPath (xPathExpression, format, resolver);
                }
 
-               [MonoTODO]
                protected IEnumerable XPathSelect (string xPathExpression)
                {
-                       throw new NotImplementedException ();
+                       return Page.XPathSelect (xPathExpression);
                }
 
-               [MonoTODO]
                protected IEnumerable XPathSelect (string xPathExpression, IXmlNamespaceResolver resolver)
                {
-                       throw new NotImplementedException ();
+                       return Page.XPathSelect (xPathExpression, resolver);
                }
 
                protected abstract string AppRelativeTemplateSourceDirectory { get; }
                protected abstract IDictionary ControlSkins { get; }
                protected abstract string[] LinkedStyleSheets { get; }
 
-               [MonoTODO]
                protected Page Page {
-                       get { throw new NotImplementedException (); }
+                       get { return _page; }
+               }
+
+               internal void SetPage (Page page)
+               {
+                       _page = page;
                }
 
                internal ControlSkin GetControlSkin (Type controlType, string skinID)
@@ -122,5 +117,3 @@ namespace System.Web.UI {
                }
        }
 }
-
-#endif