Add convenience ctors to Div

This commit is contained in:
Frank A. Krueger 2017-12-09 13:20:11 -08:00
parent cfdad03e1c
commit e93d28957c
1 changed files with 17 additions and 0 deletions

View File

@ -1,4 +1,5 @@
using System;
using System.Collections.Generic;
namespace Ooui
{
@ -8,5 +9,21 @@ namespace Ooui
: base ("div")
{
}
public Div (params Element[] children)
: this ()
{
foreach (var c in children) {
AppendChild (c);
}
}
public Div (IEnumerable<Element> children)
: this ()
{
foreach (var c in children) {
AppendChild (c);
}
}
}
}