Procházet zdrojové kódy

[System.Web] Razor works now (modulo DB)

Gonzalo Paniagua Javier před 15 roky
rodič
revize
a2ed4f6fc2

+ 1 - 1
mcs/class/System.Web/System.Web.Compilation/AppCodeCompiler.cs

@@ -282,7 +282,7 @@ namespace System.Web.Compilation
 		
 		VirtualPath PhysicalToVirtual (string file)
 		{
-			return new VirtualPath (file.Replace (HttpRuntime.AppDomainAppPath, "/").Replace (Path.DirectorySeparatorChar, '/'));
+			return new VirtualPath (file.Replace (HttpRuntime.AppDomainAppPath, "~/").Replace (Path.DirectorySeparatorChar, '/'));
 		}
 		
 		BuildProvider GetBuildProviderFor (string file, BuildProviderCollection buildProviders)

+ 2 - 2
mcs/class/System.Web/System.Web.Compilation/BuildManager.cs

@@ -628,8 +628,8 @@ namespace System.Web.Compilation
 		public static Type GetGlobalAsaxType ()
 		{
 			Type ret = HttpApplicationFactory.AppType;
-			if (!preStartMethodsRunning)
-				throw new InvalidOperationException ("This method cannot be called during the application's pre-start initialization stage.");
+			if (ret == null)
+				return typeof (HttpApplication);
 			
 			return ret;
 		}

+ 1 - 0
mcs/class/System.Web/System.Web.Security/Roles.cs

@@ -236,6 +236,7 @@ namespace System.Web.Security {
 
 		public static bool Enabled {
 			get { return config.Enabled; }
+			set { config.Enabled = value; }
 		}
 
 		public static int MaxCachedResults {