/// <summary> /// Creates a new instance of the WinFormsUpdateChecker class. /// </summary> /// <param name="url">The location of the file containing update information.</param> /// <param name="owner">The parent window of the update window to show.</param> /// <param name="identifier">An identifier specifying the download option to use.</param> public WinFormsUpdateChecker(string url, Form owner = null, string identifier = null) : base(url, identifier) { this.Owner = owner; settings = new CustomSettings(AppInfo.IsPortable.GetValueOrDefault(), typeof(UpdateCheckerBase).FullName); settings.AddSetting("CheckedUpdate", typeof(string), "0.0", true, System.Configuration.SettingsSerializeAs.String); settings.AddSetting("SkipVersion", typeof(bool), false, true, System.Configuration.SettingsSerializeAs.String); }
/// <inheritdoc /> public override void ManageDefault() { this.manageDefault = true; CustomSettings.AddSetting(Context.GetType().GetProperty(nameof(Context.Left)), DEFAULT, false); CustomSettings.AddSetting(Context.GetType().GetProperty(nameof(Context.Top)), DEFAULT, false); CustomSettings.AddSetting(Context.GetType().GetProperty(nameof(Context.WindowState)), WindowState.Normal, false); CustomSettings.AddSetting(Context.GetType().GetProperty(nameof(Context.Width)), DEFAULT, false); CustomSettings.AddSetting(Context.GetType().GetProperty(nameof(Context.Height)), DEFAULT, false); }