public static DLSetingsForSingle Load(string id) { DLSetingsForSingle returnSettings = null; var name = System.AppDomain.CurrentDomain.FriendlyName; string adp = Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData) + "\\" + name; adp += "\\" + id + "-decklink_settings.xml"; if (File.Exists(adp)) { try { StreamReader reader = new StreamReader(adp); XmlSerializer xms = new XmlSerializer(typeof(DLSetingsForSingle)); returnSettings = (DLSetingsForSingle)xms.Deserialize(reader); reader.Close(); } catch { returnSettings = GetNewShowSettings(); } } else { return(GetNewShowSettings()); } return(returnSettings); }
public DLAccessForSingle(string uniqueId) { settings = DLSetingsForSingle.Load(uniqueId); this.uniqueId = uniqueId; }
public static DLSetingsForSingle GetNewShowSettings() { var settings = new DLSetingsForSingle(); return(settings); }