Last active
May 4, 2023 00:00
-
-
Save alfonmga/e714b91475568629aacfb0a5251d0436 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//go:build darwin | |
package common | |
/* | |
#cgo CFLAGS: -x objective-c | |
#cgo LDFLAGS: -framework Cocoa | |
#import <Cocoa/Cocoa.h> | |
int | |
SetActivationPolicy(void) { | |
[NSApp setActivationPolicy:NSApplicationActivationPolicyAccessory]; | |
return 0; | |
} | |
*/ | |
import "C" | |
func HideMacDockIcon() { | |
C.SetActivationPolicy() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment