我正在开发一个Mac应用程序,用于将文件共享到不同的社交平台,如Flickr,Facebook等。我想在文件的上下文菜单中添加“与MyApp共享”功能。也就是说,当我(control+click)文件系统中的任何文件时,我必须在上下文菜单中看到一个像'share with MyApp‘这样的菜单项,这样我才能运行我<e
我能够使用applescript tell perform action "AXShowMenu“打开上下文菜单。tell application "System Events" to tell process "Finder" tell window {window name} tell splitter groupimage {filename} perform action "AXShowMenu" end tell end tell end te