Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
right click当用户点击change desktop background或background image在 OSX 上实际更改时,有什么方法可以收听并触发操作?
right click
change desktop background
background image
您可以像这样在 shell 中获取当前桌面图像:
osascript -e 'tell app "finder" to get posix path of (get desktop picture as alias)'
我想,如果你真的想要,你可以创建一个launchd脚本launchctl和一个相应的 plist 来检查每分钟左右,看看它是否已经改变,然后做一些事情......
launchd
launchctl