gpt4 book ai didi

cocoa : Repport click on dock icon

转载 作者:行者123 更新时间:2023-12-03 16:27:12 26 4
gpt4 key购买 nike

有没有办法报告每次鼠标点击应用程序停靠栏图标?

最佳答案

并不完全安全(也可以通过双击应用程序本身来激活),
但绝对是最简单的实现方法:

- (BOOL)applicationShouldHandleReopen:(NSApplication *)theApplication hasVisibleWindows:(BOOL)flag

引自NSApplicationDelegate Protocol Reference :

These events are sent whenever the Finder reactivates an already running application because someone double-clicked it again or used the dock to activate it.

关于 cocoa : Repport click on dock icon,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11333803/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com