Skip to content

Instantly share code, notes, and snippets.

void Main()
{
var parents = new List<Parent>()
{
new Parent()
{
ParentProperty = "Parent1",
Children = new List<Child>()
{
new Child() { ChildProperty1 = "Child1a", ChildProperty2 = "Child1b" },
@SAAirey
SAAirey / MaStyleInnitBruv
Created January 22, 2014 16:42
Style, innit bruv.
<Style x:Key="MainPageTabControlStyle" TargetType="TabControl">
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="TabControl">
<Border BorderBrush="#CCCCCC" BorderThickness="1,1,0,0">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="40" />
<RowDefinition />
</Grid.RowDefinitions>
#region Internal data
[StructLayout(LayoutKind.Sequential)]
internal struct SHFILEINFO
{
public IntPtr hIcon;
public IntPtr iIcon;
public uint dwAttributes;
[MarshalAs(UnmanagedType.ByValTStr, SizeConst = 260)]
public string szDisplayName;
@SAAirey
SAAirey / gist:7353985
Created November 7, 2013 12:41
Everyone loves commands.
class ParentVM
{
public List<ChildVM> AllTheObjects { get; set; }
public ICommand AddNewChildCommand { get; set; }
public ParentVM()
{
AllTheObjects = new List<ChildVM>();