public static Window CreateWindow(ref WindowType windowType) { if (windowType == null && Factory.HasContract(typeof(Window))) { windowType = new WindowType { IsFactoryType = true } } ; if (windowType == null) { windowType = new WindowType { Type = Assemblies.ExportedTypes.FirstOrDefault(x => x.IsSubclassOf(typeof(Window))) } } ; if (windowType == null) { windowType = new WindowType { Type = typeof(Window) } } ; return(windowType.CreateWindow()); } } }
public static Window CreateWindow(ref WindowType windowType) { if (windowType == null && Factory.HasContract(typeof(Window))) { windowType = new WindowType { IsFactoryType = true } } ; if (windowType == null) { windowType = new WindowType { Type = typeof(Window) } } ; return(windowType.CreateWindow()); } } }