Переглянути джерело

2005-08-29 Chris Toshok <[email protected]>

	* HtmlInputSubmit.cs: new implementation.
	
	* HtmlInputReset.cs (ValidationGroup): implement

	* HtmlInputButton.cs (ValidationGroup): implement.


svn path=/trunk/mcs/; revision=49075
Chris Toshok 20 роки тому
батько
коміт
dfd85687a9

+ 8 - 0
mcs/class/System.Web/System.Web.UI.HtmlControls/ChangeLog

@@ -1,3 +1,11 @@
+2005-08-29  Chris Toshok  <[email protected]>
+
+	* HtmlInputSubmit.cs: new implementation.
+	
+	* HtmlInputReset.cs (ValidationGroup): implement
+
+	* HtmlInputButton.cs (ValidationGroup): implement.
+
 2005-08-29  Chris Toshok  <[email protected]>
 
 	* HtmlButton.cs: Fix some 2.0 Page/ClientScript obsolete warnings.

+ 2 - 3
mcs/class/System.Web/System.Web.UI.HtmlControls/HtmlInputButton.cs

@@ -62,14 +62,13 @@ namespace System.Web.UI.HtmlControls {
 
 #if NET_2_0
 		[DefaultValue ("")]
-		[MonoTODO]
 		public string ValidationGroup
 		{
 			get {
-				throw new NotImplementedException ();
+				return ViewState.GetString ("ValidationGroup", "");
 			}
 			set {
-				throw new NotImplementedException ();
+				ViewState ["ValidationGroup"] = value;
 			}
 		}
 #endif

+ 4 - 3
mcs/class/System.Web/System.Web.UI.HtmlControls/HtmlInputReset.cs

@@ -46,6 +46,7 @@ namespace System.Web.UI.HtmlControls {
 		{
 		}
 
+		[MonoTODO("Why override?")]
 		[Browsable (false)]
 		[EditorBrowsable (EditorBrowsableState.Never)]
 		public override bool CausesValidation {
@@ -57,16 +58,16 @@ namespace System.Web.UI.HtmlControls {
 			}
 		}
 
-		[MonoTODO]
+		[MonoTODO("Why new?")]
 		[Browsable (false)]
 		[EditorBrowsable (EditorBrowsableState.Never)]
 		public new string ValidationGroup
 		{
 			get {
-				throw new NotImplementedException ();
+				return ViewState.GetString ("ValidationGroup", "");
 			}
 			set {
-				throw new NotImplementedException ();
+				ViewState ["ValidationGroup"] = value;
 			}
 		}
 

+ 54 - 0
mcs/class/System.Web/System.Web.UI.HtmlControls/HtmlInputSubmit.cs

@@ -0,0 +1,54 @@
+//
+// System.Web.UI.HtmlControls.HtmlInputSubmit.cs
+//
+// Author:
+//	Chris Toshok  <[email protected]>
+//
+// Copyright (C) 2005 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
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.ComponentModel;
+
+#if NET_2_0
+namespace System.Web.UI.HtmlControls {
+
+	[DefaultEventAttribute ("")]
+	public class HtmlInputSubmit : HtmlInputButton, IPostBackEventHandler
+	{
+		public HtmlInputSubmit ()
+			: base ("submit")
+		{
+		}
+
+		public HtmlInputSubmit (string type)
+			: base (type)
+		{
+		}
+
+		[MonoTODO]
+		void IPostBackEventHandler.RaisePostBackEvent (string eventArgument)
+		{
+			base.RaisePostBackEvent (eventArgument);
+		}
+	}
+}
+#endif