Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWade Berrier <wade@mono-cvs.ximian.com>2007-08-27 22:27:57 +0400
committerWade Berrier <wade@mono-cvs.ximian.com>2007-08-27 22:27:57 +0400
commitb80cb128d794441da87095b62dda79fc977b43a2 (patch)
tree9b415b67a62bbb4b6646c561822fb4b03440c301
parentdee7e0bcc74b8d15792b1b72b399bb155fb1c827 (diff)
Revert r84521 from p4 1.2.5 mcs tagmono-1-2-5-p4
svn path=/tags/mono-1-2-5-p4/mcs/; revision=84906
-rw-r--r--mcs/class/System.Web/System.Web.Configuration/ChangeLog5
-rw-r--r--mcs/class/System.Web/System.Web.Configuration/PagesConfiguration.cs2
-rw-r--r--mcs/class/System.Web/System.Web.Configuration/PagesConfigurationHandler.cs15
-rw-r--r--mcs/class/System.Web/System.Web.Configuration_2.0/ChangeLog4
-rw-r--r--mcs/class/System.Web/System.Web.Configuration_2.0/PagesEnableSessionState.cs19
-rw-r--r--mcs/class/System.Web/System.Web.UI/ChangeLog16
-rw-r--r--mcs/class/System.Web/System.Web.UI/PageParser.cs51
7 files changed, 44 insertions, 68 deletions
diff --git a/mcs/class/System.Web/System.Web.Configuration/ChangeLog b/mcs/class/System.Web/System.Web.Configuration/ChangeLog
index c074532b67b..f889d222ebe 100644
--- a/mcs/class/System.Web/System.Web.Configuration/ChangeLog
+++ b/mcs/class/System.Web/System.Web.Configuration/ChangeLog
@@ -1,8 +1,3 @@
-2007-08-10 Gert Driesen <drieseng@users.sourceforge.net>
-
- * PagesConfigurationHandler.cs: Use enum for EnableSessionState.
- * PagesConfiguration.cs: Use enum for EnableSessionState.
-
2007-05-01 Marek Habersack <mhabersack@novell.com>
* HttpCapabilitiesBase.cs: move the User-Agent code to a separate
diff --git a/mcs/class/System.Web/System.Web.Configuration/PagesConfiguration.cs b/mcs/class/System.Web/System.Web.Configuration/PagesConfiguration.cs
index 4bc4bad718f..8066b177b23 100644
--- a/mcs/class/System.Web/System.Web.Configuration/PagesConfiguration.cs
+++ b/mcs/class/System.Web/System.Web.Configuration/PagesConfiguration.cs
@@ -36,7 +36,7 @@ namespace System.Web.Configuration
class PagesConfiguration
{
internal bool Buffer = true;
- internal PagesEnableSessionState EnableSessionState = PagesEnableSessionState.True;
+ internal string EnableSessionState = "true";
internal bool EnableViewState = true;
internal bool EnableViewStateMac = false;
internal bool SmartNavigation = false;
diff --git a/mcs/class/System.Web/System.Web.Configuration/PagesConfigurationHandler.cs b/mcs/class/System.Web/System.Web.Configuration/PagesConfigurationHandler.cs
index 55c16d48fa3..e517c981e69 100644
--- a/mcs/class/System.Web/System.Web.Configuration/PagesConfigurationHandler.cs
+++ b/mcs/class/System.Web/System.Web.Configuration/PagesConfigurationHandler.cs
@@ -48,22 +48,11 @@ namespace System.Web.Configuration
attvalue = AttValue ("enableSessionState", section);
if (attvalue != null) {
- switch (attvalue) {
- case "true":
- config.EnableSessionState = PagesEnableSessionState.True;
- break;
- case "ReadOnly":
- config.EnableSessionState = PagesEnableSessionState.ReadOnly;
- break;
- case "false":
- config.EnableSessionState = PagesEnableSessionState.False;
- break;
- default:
+ if (attvalue != "true" && attvalue != "false" && attvalue != "ReadOnly")
HandlersUtil.ThrowException ("The 'enableSessionState' attribute"
+ " is case sensitive and must be one of the following values:"
+ " false, true, ReadOnly.", section);
- break;
- }
+ config.EnableSessionState = attvalue;
}
attvalue = AttValue ("enableViewState", section);
diff --git a/mcs/class/System.Web/System.Web.Configuration_2.0/ChangeLog b/mcs/class/System.Web/System.Web.Configuration_2.0/ChangeLog
index 2d76af8c9de..ea7c1c1a72f 100644
--- a/mcs/class/System.Web/System.Web.Configuration_2.0/ChangeLog
+++ b/mcs/class/System.Web/System.Web.Configuration_2.0/ChangeLog
@@ -1,7 +1,3 @@
-2007-08-10 Gert Driesen <drieseng@users.sourceforge.net>
-
- * PagesEnableSessionState.cs: Marked internal on 1.0 profile.
-
2007-07-16 Vladimir Krasnov <vladimirk@mainsoft.com>
* ProfileGroupSettingsCollection.cs: added ResetInternal internal
diff --git a/mcs/class/System.Web/System.Web.Configuration_2.0/PagesEnableSessionState.cs b/mcs/class/System.Web/System.Web.Configuration_2.0/PagesEnableSessionState.cs
index 3895dc74f42..4379e8051ff 100644
--- a/mcs/class/System.Web/System.Web.Configuration_2.0/PagesEnableSessionState.cs
+++ b/mcs/class/System.Web/System.Web.Configuration_2.0/PagesEnableSessionState.cs
@@ -28,17 +28,14 @@
using System.Resources;
+#if NET_2_0
namespace System.Web.Configuration
{
-#if NET_2_0
- public
-#else
- internal
-#endif
- enum PagesEnableSessionState
- {
- False = 0,
- ReadOnly = 1,
- True = 2
- }
+ public enum PagesEnableSessionState
+ {
+ False = 0,
+ ReadOnly = 1,
+ True = 2
+ }
}
+#endif
diff --git a/mcs/class/System.Web/System.Web.UI/ChangeLog b/mcs/class/System.Web/System.Web.UI/ChangeLog
index f720b031b3f..ed37506fc56 100644
--- a/mcs/class/System.Web/System.Web.UI/ChangeLog
+++ b/mcs/class/System.Web/System.Web.UI/ChangeLog
@@ -1,21 +1,7 @@
-2007-08-10 Gert Driesen <drieseng@users.sourceforge.net>
-
- * PageParser.cs: Replace enableSessionState and readOnlySessionState
- bools with enum backed field. Move 1.0 profile code for checking value
- of EnableSessionState pages config to PagesConfigurationHandler.
- Fixes bug #82392 for 1.0 profile.
-
-2007-08-09 Marek Habersack <mhabersack@novell.com>
-
- * PageParser.cs: honor web.config enableSessionState
- ReadOnly setting instead of overwriting based on default value for
- page directive EnableSessionState. Patch from Joel Reed
- <joelwreed@comcast.com>, thanks! Fixes bug #82392
-
2007-07-24 Igor Zelmanovich <igorz@mainsoft.com>
* ClientScriptManager.cs: fixed: GetCallbackEventReference method.
-
+
2007-07-23 Igor Zelmanovich <igorz@mainsoft.com>
* Page.cs: refactoring: __doPostBack client script
diff --git a/mcs/class/System.Web/System.Web.UI/PageParser.cs b/mcs/class/System.Web/System.Web.UI/PageParser.cs
index ea4d1bc22c5..a128f91b372 100644
--- a/mcs/class/System.Web/System.Web.UI/PageParser.cs
+++ b/mcs/class/System.Web/System.Web.UI/PageParser.cs
@@ -43,13 +43,14 @@ namespace System.Web.UI
[AspNetHostingPermission (SecurityAction.LinkDemand, Level = AspNetHostingPermissionLevel.Minimal)]
public sealed class PageParser : TemplateControlParser
{
- PagesEnableSessionState enableSessionState = PagesEnableSessionState.True;
+ bool enableSessionState = true;
bool enableViewStateMac = true;
- bool smartNavigation;
+ bool smartNavigation = false;
bool haveTrace;
bool trace;
bool notBuffer;
TraceMode tracemode;
+ bool readonlySessionState;
string responseEncoding;
string contentType;
int codepage = -1;
@@ -111,7 +112,24 @@ namespace System.Web.UI
#endif
notBuffer = !ps.Buffer;
- enableSessionState = ps.EnableSessionState;
+#if NET_2_0
+ switch (ps.EnableSessionState) {
+ case PagesEnableSessionState.True:
+ case PagesEnableSessionState.ReadOnly:
+ enableSessionState = true;
+ break;
+
+ default:
+ enableSessionState = false;
+ break;
+ }
+#else
+ if (String.Compare (ps.EnableSessionState, "true", true, CultureInfo.InvariantCulture) == 0)
+ enableSessionState = true;
+ else
+ enableSessionState = false;
+#endif
+
enableViewStateMac = ps.EnableViewStateMac;
smartNavigation = ps.SmartNavigation;
validateRequest = ps.ValidateRequest;
@@ -147,23 +165,23 @@ namespace System.Web.UI
// note: the 'enableSessionState' configuration property is
// processed in a case-sensitive manner while the page-level
// attribute is processed case-insensitive
- string enabless = GetString (atts, "EnableSessionState", null);
+ string enabless = GetString (atts, "EnableSessionState", enableSessionState.ToString ());
if (enabless != null) {
- if (String.Compare (enabless, "readonly", true) == 0)
- enableSessionState = PagesEnableSessionState.ReadOnly;
- else if (String.Compare (enabless, "true", true) == 0)
- enableSessionState = PagesEnableSessionState.True;
- else if (String.Compare (enabless, "false", true) == 0)
- enableSessionState = PagesEnableSessionState.False;
- else
+ readonlySessionState = (String.Compare (enabless, "readonly", true) == 0);
+ if (readonlySessionState == true || String.Compare (enabless, "true", true) == 0) {
+ enableSessionState = true;
+ } else if (String.Compare (enabless, "false", true) == 0) {
+ enableSessionState = false;
+ } else {
ThrowParseException ("Invalid value for enableSessionState: " + enabless);
+ }
}
string cp = GetString (atts, "CodePage", null);
if (cp != null) {
if (responseEncoding != null)
ThrowParseException ("CodePage and ResponseEncoding are " +
- "mutually exclusive.");
+ "mutually exclusive.");
int codepage = 0;
try {
@@ -418,10 +436,7 @@ namespace System.Web.UI
}
internal bool EnableSessionState {
- get {
- return enableSessionState == PagesEnableSessionState.True ||
- ReadOnlySessionState;
- }
+ get { return enableSessionState; }
}
internal bool EnableViewStateMac {
@@ -433,9 +448,7 @@ namespace System.Web.UI
}
internal bool ReadOnlySessionState {
- get {
- return enableSessionState == PagesEnableSessionState.ReadOnly;
- }
+ get { return readonlySessionState; }
}
internal bool HaveTrace {