隐藏Mac操作系统下的所有桌面图标

发布于 2024-10-03 11:17:29 字数 110 浏览 0 评论 0原文

我正在寻找一种在 Mac OS X 下的 Objective-C 中以编程方式显示/隐藏桌面图标的方法。

您知道我如何实现这一目标吗?

感谢您的帮助,

问候,

I am looking for a way to show/hide desktop icons programmatically in objective-c under Mac OS X.

Do you have any idea on how I can achieve this?

Thanks for your help,

Regards,

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

暖树树初阳… 2024-10-10 11:17:29

Finder 对此有一个隐藏的偏好。将com.apple.finder下的CreateDesktop的值设置为kCFBooleanFalse,然后终止Finder。要恢复桌面图标,请删除 CreateDesktop 首选项并再次终止 Finder。

当然,这不是受支持的 API 功能;它随时可能消失。

The Finder has a hidden preference for this. Set the value of CreateDesktop under com.apple.finder to kCFBooleanFalse, then kill the Finder. To put the desktop icons back, delete the CreateDesktop preference and kill the Finder again.

Of course, this isn't a supported API feature; it could go away at any time.

柳絮泡泡 2024-10-10 11:17:29

如果不实际将项目移入或移出桌面,或者修补 Finder,则无法做到这一点,这两者都不是一个特别好的主意。

另一种选择是在您要隐藏的图标顶部放置一个窗口。请参阅我对您的其他问题的回答。

You can't do this short of actually moving the items on and off the desktop, or patching the Finder, neither of which is a particularly good idea.

Another option is to place a window over the top of the icon you're trying to hide. See my answer to your other question.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文