public static void ShowHistory() { // Make sure the history is loaded, will be done only once ImgurUtils.LoadHistory(); if (instance == null) { instance = new ImgurHistory(); } instance.Show(); instance.redraw(); }
public SettingsForm(ImgurConfiguration config) { // // The InitializeComponent() call is required for Windows Forms designer support. // InitializeComponent(); CancelButton = buttonCancel; AcceptButton = buttonOK; ImgurUtils.LoadHistory(); historyButton.Enabled = config.runtimeImgurHistory.Count > 0; }
private void CheckHistory() { try { ImgurUtils.LoadHistory(); _host.GreenshotForm.BeginInvoke((MethodInvoker) delegate { if (_config.ImgurUploadHistory.Count > 0) { _historyMenuItem.Enabled = true; } else { _historyMenuItem.Enabled = false; } }); } catch (Exception ex) { Log.Error("Error loading history", ex); } }
public SettingsForm(ImgurConfiguration config) : base() { // // The InitializeComponent() call is required for Windows Forms designer support. // InitializeComponent(); CancelButton = buttonCancel; AcceptButton = buttonOK; this.Icon = GreenshotPlugin.Core.GreenshotResources.getGreenshotIcon(); ImgurUtils.LoadHistory(); if (config.runtimeImgurHistory.Count > 0) { historyButton.Enabled = true; } else { historyButton.Enabled = false; } }