diff options
author | Vsevolod Kukol <sevoku@microsoft.com> | 2019-07-17 10:25:59 +0300 |
---|---|---|
committer | Vsevolod Kukol <sevoku@microsoft.com> | 2019-07-17 10:25:59 +0300 |
commit | 091d8c8cdfd044f4f41543e5dc43dc382f5250ad (patch) | |
tree | 0fdcac637cccc04c8f214450b0cf635d3ffa95bf /main/src/addins/MacPlatform/MacPlatform.cs | |
parent | 797d609b0f2cbdbe325a115693c0256bd71944ed (diff) |
[Mac] Improve ApplicationIcon logic and make setter private
Diffstat (limited to 'main/src/addins/MacPlatform/MacPlatform.cs')
-rw-r--r-- | main/src/addins/MacPlatform/MacPlatform.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/main/src/addins/MacPlatform/MacPlatform.cs b/main/src/addins/MacPlatform/MacPlatform.cs index 705df36dd6..49cadaa103 100644 --- a/main/src/addins/MacPlatform/MacPlatform.cs +++ b/main/src/addins/MacPlatform/MacPlatform.cs @@ -776,8 +776,8 @@ namespace MonoDevelop.MacIntegration } return applicationIcon; } - set { - applicationIcon = value; + private set { + NSApplication.SharedApplication.ApplicationIconImage = applicationIcon = value; } } @@ -808,7 +808,7 @@ namespace MonoDevelop.MacIntegration var imageFile = new NSString (iconFile); IntPtr p = IntPtr_objc_msgSend_IntPtr (image.Handle, Selector.GetHandle ("initByReferencingFile:"), imageFile.Handle); - NSApplication.SharedApplication.ApplicationIconImage = applicationIcon = ObjCRuntime.Runtime.GetNSObject<NSImage> (p); + ApplicationIcon = ObjCRuntime.Runtime.GetNSObject<NSImage> (p); } } |