2006-02-07 Chris Toshok <toshok@ximian.com>
authorChris Toshok <toshok@novell.com>
Tue, 7 Feb 2006 16:49:30 +0000 (16:49 -0000)
committerChris Toshok <toshok@novell.com>
Tue, 7 Feb 2006 16:49:30 +0000 (16:49 -0000)
* ContentPlaceHolder.cs: fix ToolboxDataAttribute.

* Content.cs: use ContentControlBuilderInternal, and add a bunch
of unused (for now) EventHandler's here.

* ContentControlBuilderInternal.cs: rename ContentControlBuilder
to this.

svn path=/trunk/mcs/; revision=56621

1  2 
mcs/class/System.Web/System.Web.UI.WebControls/ChangeLog
mcs/class/System.Web/System.Web.UI.WebControls/Content.cs
mcs/class/System.Web/System.Web.UI.WebControls/ContentControlBuilder.cs
mcs/class/System.Web/System.Web.UI.WebControls/ContentControlBuilderInternal.cs
mcs/class/System.Web/System.Web.UI.WebControls/ContentPlaceHolder.cs

index 27e8dc0e11222fc83bcd7a3a681fd4b4666cba4b,27e8dc0e11222fc83bcd7a3a681fd4b4666cba4b..158a02c76dbc9700c24741ba5a3a05f7e46e10a2
@@@ -1,3 -1,3 +1,13 @@@
++2006-02-07  Chris Toshok  <toshok@ximian.com>
++
++      * ContentPlaceHolder.cs: fix ToolboxDataAttribute.
++
++      * Content.cs: use ContentControlBuilderInternal, and add a bunch
++      of unused (for now) EventHandler's here.
++
++      * ContentControlBuilderInternal.cs: rename ContentControlBuilder
++      to this.
++
  2006-01-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>
  
        * ListControl.cs: bound checking for Items when loading the control
index a6011121e1335437de7a0b323fc615f77a4f5016,a6011121e1335437de7a0b323fc615f77a4f5016..a661f9694b0b17f98b84e56713176717abfd70f8
@@@ -37,11 -37,11 +37,7 @@@ namespace System.Web.UI.WebControl
  {
        [ToolboxItem (false)]
        [DesignerAttribute ("System.Web.UI.Design.WebControls.ContentDesigner, " + Consts.AssemblySystem_Design, "System.ComponentModel.Design.IDesigner")]
--#if notyet
--      [ControlBuilder(typeof(ContentControlBuilderInternal))]  /* XXX ew, this is in beta2 - an internal builder? */
--#else
--      [ControlBuilder(typeof(ContentControlBuilder))] 
--#endif
++      [ControlBuilder(typeof(ContentControlBuilderInternal))]
        public class Content: Control, INamingContainer
        {
                string placeHolderId;
                        get { return placeHolderId; }
                        set { placeHolderId = value; }
                }
++
++              static readonly object DataBindingEvent = new object ();
++              [DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
++              [Browsable (false)]
++              public new event EventHandler DataBinding {
++                      add { Events.AddHandler (DataBindingEvent, value); }
++                      remove { Events.RemoveHandler (DataBindingEvent, value); }
++              }
++
++              static readonly object DisposedEvent = new object ();
++              [DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
++              [Browsable (false)]
++              public new event EventHandler Disposed {
++                      add { Events.AddHandler (DisposedEvent, value); }
++                      remove { Events.RemoveHandler (DisposedEvent, value); }
++              }
++
++              static readonly object InitEvent = new object ();
++              [DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
++              [Browsable (false)]
++              public new event EventHandler Init {
++                      add { Events.AddHandler (InitEvent, value); }
++                      remove { Events.RemoveHandler (InitEvent, value); }
++              }
++
++              static readonly object LoadEvent = new object ();
++              [DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
++              [Browsable (false)]
++              public new event EventHandler Load {
++                      add { Events.AddHandler (LoadEvent, value); }
++                      remove { Events.RemoveHandler (LoadEvent, value); }
++              }
++
++              static readonly object PreRenderEvent = new object ();
++              [DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
++              [Browsable (false)]
++              public new event EventHandler PreRender {
++                      add { Events.AddHandler (PreRenderEvent, value); }
++                      remove { Events.RemoveHandler (PreRenderEvent, value); }
++              }
++
++              static readonly object UnloadEvent = new object ();
++              [DesignerSerializationVisibility (DesignerSerializationVisibility.Hidden)]
++              [Browsable (false)]
++              public new event EventHandler Unload {
++                      add { Events.AddHandler (UnloadEvent, value); }
++                      remove { Events.RemoveHandler (UnloadEvent, value); }
++              }
        }
  }
  
diff --cc mcs/class/System.Web/System.Web.UI.WebControls/ContentControlBuilder.cs
index ca31d83b974d8bf0af54cae05f30c62753c73943,ca31d83b974d8bf0af54cae05f30c62753c73943..0000000000000000000000000000000000000000
deleted file mode 100644,100644
+++ /dev/null
@@@ -1,60 -1,60 +1,0 @@@
--//
--// System.Web.UI.WebControls.Content.cs
--//
--// Authors:
--//   Lluis Sanchez Gual (lluis@novell.com)
--//
--// (C) 2005 Novell, Inc.
--//
--
--//
--// 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.
--//
--
--#if NET_2_0
--
--using System;
--using System.Collections;
--using System.Web.UI.WebControls;
--
--namespace System.Web.UI
--{
--      internal class ContentControlBuilder: TemplateBuilder
--      {
--              string placeHolderID;
--              
--              public override void Init (TemplateParser parser,
--                                        ControlBuilder parentBuilder,
--                                        Type type,
--                                        string tagName,
--                                        string ID,
--                                        IDictionary attribs)
--              {
--                      base.Init (parser, parentBuilder, type, tagName, ID, attribs);
--                      placeHolderID = attribs ["ContentPlaceHolderID"] as string;
--              }
--              
--              public string ContentPlaceHolderID {
--                      get { return placeHolderID; }
--              }
--      }
--}
--
--#endif
index 0000000000000000000000000000000000000000,0000000000000000000000000000000000000000..e77e1388d37140de5ed5260cd20c97df667e8f53
new file mode 100644 (file)
--- /dev/null
--- /dev/null
@@@ -1,0 -1,0 +1,60 @@@
++//
++// System.Web.UI.WebControls.ContentControlBuilderInternal.cs
++//
++// Authors:
++//   Lluis Sanchez Gual (lluis@novell.com)
++//
++// (C) 2005 Novell, Inc.
++//
++
++//
++// 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.
++//
++
++#if NET_2_0
++
++using System;
++using System.Collections;
++using System.Web.UI.WebControls;
++
++namespace System.Web.UI
++{
++      internal class ContentControlBuilderInternal: TemplateBuilder
++      {
++              string placeHolderID;
++              
++              public override void Init (TemplateParser parser,
++                                        ControlBuilder parentBuilder,
++                                        Type type,
++                                        string tagName,
++                                        string ID,
++                                        IDictionary attribs)
++              {
++                      base.Init (parser, parentBuilder, type, tagName, ID, attribs);
++                      placeHolderID = attribs ["ContentPlaceHolderID"] as string;
++              }
++              
++              public string ContentPlaceHolderID {
++                      get { return placeHolderID; }
++              }
++      }
++}
++
++#endif
index 7fd9d5b70ed5f56c57fb598e1ea66b2517fa4a70,7fd9d5b70ed5f56c57fb598e1ea66b2517fa4a70..f4db7963c9a369fe516cf2f4bfbd40bc3ab829d7
@@@ -39,7 -39,7 +39,7 @@@ namespace System.Web.UI.WebControl
        [ToolboxItemFilterAttribute ("Microsoft.VisualStudio.Web.WebForms.MasterPageWebFormDesigner", ToolboxItemFilterType.Require)]
        [ToolboxItemFilterAttribute ("System.Web.UI", ToolboxItemFilterType.Allow)]
        [DesignerAttribute ("System.Web.UI.Design.WebControls.ContentPlaceHolderDesigner, " + Consts.AssemblySystem_Design, "System.ComponentModel.Design.IDesigner")]
--      [ToolboxDataAttribute ("<{0}:ContentPlaceHolder runat='server'></{0}:ContentPlaceHolder>")]
++      [ToolboxDataAttribute ("&lt;{0}:ContentPlaceHolder runat=&quot;server&quot;&gt;&lt;/{0}:ContentPlaceHolder&gt;")]
        [ControlBuilder(typeof(ContentPlaceHolderBuilder))] 
        public class ContentPlaceHolder: Control, INamingContainer
        {