mirror of
https://github.com/BepInEx/mono.git
synced 2026-11-16 17:10:20 -10:00
* *.cs -- Updates from Leen Toelen ([email protected]) svn path=/trunk/mcs/; revision=2142
85 lines
1.6 KiB
C#
Executable File
85 lines
1.6 KiB
C#
Executable File
/* System.Web.UI.HtmlControls
|
|
* Authors
|
|
* Leen Toelen ([email protected])
|
|
*/
|
|
|
|
using System;
|
|
using System.Web;
|
|
using System.Web.UI;
|
|
using System.Collections;
|
|
|
|
namespace System.Web.UI.HtmlControls{
|
|
public sealed class HtmlTableCellCollection : ICollection {
|
|
private HtmlTableRow _owner;
|
|
|
|
internal HtmlTableCellCollection(HtmlTableRow owner){
|
|
_owner = owner;
|
|
}
|
|
|
|
public void Add(HtmlTableCell cell){
|
|
Insert(-1, cell);
|
|
}
|
|
|
|
public void Clear(){
|
|
if (_owner.HasControls()) _owner.Controls.Clear();
|
|
}
|
|
|
|
public void CopyTo(Array array, int index){
|
|
IEnumerator tablecell = this.GetEnumerator();
|
|
while(tablecell.MoveNext()){
|
|
index = index + 1;
|
|
array.SetValue(tablecell.Current, index);
|
|
}
|
|
}
|
|
|
|
public IEnumerator GetEnumerator(){
|
|
return _owner.Controls.GetEnumerator();
|
|
}
|
|
|
|
public void Insert(int index, HtmlTableCell cell){
|
|
_owner.Controls.AddAt(index,cell);
|
|
}
|
|
|
|
public void Remove(HtmlTableCell cell){
|
|
_owner.Controls.Remove(cell);
|
|
}
|
|
|
|
public void RemoveAt(int index){
|
|
_owner.Controls.RemoveAt(index);
|
|
}
|
|
|
|
public int Count {
|
|
get{
|
|
if (_owner.HasControls()) return _owner.Controls.Count;
|
|
return 0;
|
|
}
|
|
}
|
|
|
|
public bool IsReadOnly {
|
|
get{
|
|
return false;
|
|
}
|
|
}
|
|
|
|
public bool IsSynchronized {
|
|
get{
|
|
return false;
|
|
}
|
|
}
|
|
|
|
public HtmlTableRow this[int index] {
|
|
get{
|
|
return (HtmlTableRow) _owner.Controls[index];
|
|
}
|
|
}
|
|
|
|
public object SyncRoot {
|
|
get{
|
|
return null;
|
|
}
|
|
}
|
|
|
|
} // end of System.Web.UI.HtmlControls.HtmlTableCellCollection
|
|
|
|
}
|