// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
-using System;
using System.Globalization;
using System.Collections.Specialized;
using System.ComponentModel;
-
+using System.Security.Permissions;
namespace System.Web.UI.WebControls {
+ // CAS
+ [AspNetHostingPermission (SecurityAction.LinkDemand, Level = AspNetHostingPermissionLevel.Minimal)]
+ [AspNetHostingPermission (SecurityAction.InheritanceDemand, Level = AspNetHostingPermissionLevel.Minimal)]
public class CheckBoxList : ListControl, IRepeatInfoUser,
INamingContainer, IPostBackDataHandler {
[Bindable(true)]
#endif
[DefaultValue(-1)]
+ [WebSysDescription ("")]
+ [WebCategory ("Layout")]
public virtual int CellPadding {
get { return TableStyle.CellPadding; }
set { TableStyle.CellPadding = value; }
[Bindable(true)]
#endif
[DefaultValue(-1)]
+ [WebSysDescription ("")]
+ [WebCategory ("Layout")]
public virtual int CellSpacing {
get { return TableStyle.CellSpacing; }
set { TableStyle.CellSpacing = value; }
[Bindable(true)]
#endif
[DefaultValue(0)]
+ [WebSysDescription ("")]
+ [WebCategory ("Layout")]
public virtual int RepeatColumns {
get { return ViewState.GetInt ("RepeatColumns", 0); }
set {
[Bindable(true)]
#endif
[DefaultValue(RepeatDirection.Vertical)]
+ [WebSysDescription ("")]
+ [WebCategory ("Layout")]
public virtual RepeatDirection RepeatDirection {
get {
return (RepeatDirection) ViewState.GetInt ("RepeatDirection",
[Bindable(true)]
#endif
[DefaultValue(RepeatLayout.Table)]
+ [WebSysDescription ("")]
+ [WebCategory ("Layout")]
public virtual RepeatLayout RepeatLayout {
get {
return (RepeatLayout) ViewState.GetInt ("RepeatLayout",
[Bindable(true)]
#endif
[DefaultValue(TextAlign.Right)]
+ [WebSysDescription ("")]
+ [WebCategory ("Appearance")]
public virtual TextAlign TextAlign {
get {
return (TextAlign) ViewState.GetInt ("TextAlign",
}
}
-#if NET_2_0
- [MonoTODO]
- protected virtual bool HasFooter
- {
- get {
- throw new NotImplementedException ();
- }
- }
-
- [MonoTODO]
- protected virtual bool HasHeader
- {
- get {
- throw new NotImplementedException ();
- }
- }
-
- [MonoTODO]
- protected virtual bool HasSeparators
- {
- get {
- throw new NotImplementedException ();
- }
- }
-
- [MonoTODO]
- protected virtual int RepeatedItemCount
- {
- get {
- throw new NotImplementedException ();
- }
- }
-#endif
-
private TableStyle TableStyle {
get { return (TableStyle) ControlStyle; }
}
return this;
}
-#if NET_2_0
- [MonoTODO]
- protected virtual Style GetItemStyle (ListItemType itemType,
- int repeatIndex)
- {
- throw new NotImplementedException ();
- }
-#endif
-
#if NET_2_0
protected internal
#else
}
#if NET_2_0
- [MonoTODO]
- protected virtual void RenderItem (ListItemType itemType,
- int repeatIndex,
- RepeatInfo repeatInfo,
- HtmlTextWriter w)
- {
- throw new NotImplementedException ();
- }
-
- [MonoTODO]
- protected virtual bool LoadPostData (string postDataKey, NameValueCollection postCollection)
- {
- throw new NotImplementedException ();
- }
-
- [MonoTODO]
- protected virtual void RaisePostDataChangedEvent ()
- {
- throw new NotImplementedException ();
- }
-#endif
-
- bool IPostBackDataHandler.LoadPostData (string postDataKey,
- NameValueCollection postCollection)
+ protected virtual
+#endif
+ bool LoadPostData (string postDataKey, NameValueCollection postCollection)
{
int checkbox = -1;
return false;
}
- void IPostBackDataHandler.RaisePostDataChangedEvent ()
+#if NET_2_0
+ protected virtual
+#endif
+ void RaisePostDataChangedEvent ()
{
OnSelectedIndexChanged (EventArgs.Empty);
}
+ bool IPostBackDataHandler.LoadPostData (string postDataKey,
+ NameValueCollection postCollection)
+ {
+ return LoadPostData (postDataKey, postCollection);
+ }
+
+ void IPostBackDataHandler.RaisePostDataChangedEvent ()
+ {
+ RaisePostDataChangedEvent ();
+ }
+
+#if NET_2_0
+ protected virtual
+#endif
+ bool HasFooter
+ {
+ get {
+ return false;
+ }
+ }
+
bool IRepeatInfoUser.HasFooter {
- get { return false; }
+ get { return HasFooter; }
+ }
+
+#if NET_2_0
+ protected virtual
+#endif
+ bool HasHeader
+ {
+ get {
+ return false;
+ }
}
bool IRepeatInfoUser.HasHeader {
- get { return false; }
+ get { return HasHeader; }
+ }
+
+
+#if NET_2_0
+ protected virtual
+#endif
+ bool HasSeparators
+ {
+ get {
+ return false;
+ }
}
bool IRepeatInfoUser.HasSeparators {
- get { return false; }
+ get { return HasSeparators; }
+ }
+
+#if NET_2_0
+ protected virtual
+#endif
+ int RepeatedItemCount
+ {
+ get {
+ return Items.Count;
+ }
}
int IRepeatInfoUser.RepeatedItemCount {
- get { return Items.Count; }
+ get { return RepeatedItemCount; }
}
- Style IRepeatInfoUser.GetItemStyle (ListItemType itemType,
- int repeatIndex)
+#if NET_2_0
+ protected virtual
+#endif
+ Style GetItemStyle (ListItemType itemType,
+ int repeatIndex)
{
return null;
}
- void IRepeatInfoUser.RenderItem (ListItemType itemType,
- int repeatIndex, RepeatInfo repeatInfo,
- HtmlTextWriter writer)
+ Style IRepeatInfoUser.GetItemStyle (ListItemType itemType,
+ int repeatIndex)
+ {
+ return GetItemStyle (itemType, repeatIndex);
+ }
+
+#if NET_2_0
+ protected virtual
+#endif
+ void RenderItem (ListItemType itemType,
+ int repeatIndex,
+ RepeatInfo repeatInfo,
+ HtmlTextWriter writer)
{
ListItem item = Items [repeatIndex];
check_box.Text = item.Text;
check_box.AutoPostBack = AutoPostBack;
check_box.Checked = item.Selected;
+ check_box.TextAlign = TextAlign;
+ check_box.Enabled = Enabled;
check_box.RenderControl (writer);
}
+
+ void IRepeatInfoUser.RenderItem (ListItemType itemType,
+ int repeatIndex, RepeatInfo repeatInfo,
+ HtmlTextWriter writer)
+ {
+ RenderItem (itemType, repeatIndex, repeatInfo, writer);
+ }
}
}