This change should make the UI Icon Size setting dynamic, clearing all cached icons when the size changes (in the settings UI) so if they have a dynamic size the best is selected.

This commit is contained in:
RKrom 2014-11-11 13:23:59 +01:00
commit 61c2921b2a
16 changed files with 140 additions and 123 deletions

View file

@ -336,7 +336,7 @@ namespace Greenshot {
public MainForm(CopyDataTransport dataTransport) {
_instance = this;
//
// The InitializeComponent() call is required for Windows Forms designer support.
//
@ -388,6 +388,8 @@ namespace Greenshot {
}
SoundHelper.Initialize();
MainForm.ResetImageScalingSize();
// Set the Greenshot icon visibility depending on the configuration. (Added for feature #3521446)
// Setting it to true this late prevents Problems with the context menu
notifyIcon.Visible = !_conf.HideTrayicon;
@ -549,6 +551,15 @@ namespace Greenshot {
}
}
/// <summary>
/// Reset ImageScalingSize
/// </summary>
/// <returns>Used for fixing scaling issues</returns>
public static void ResetImageScalingSize() {
MainForm thisForm = MainForm.Instance;
thisForm.contextMenu.ImageScalingSize = coreConfiguration.IconSize;
}
/// <summary>
/// Registers all hotkeys as configured, displaying a dialog in case of hotkey conflicts with other tools.
/// </summary>