开发者

Custom Application Menu in Mac OS X

I manage to make Mac OS X Application Menu work on Java using com.apple.eawt API and ad开发者_StackOverflowded handlers for "About App", "Preferences..." and "Quit App" menu item.

But is it possible to add some custom menu option in this Application Menu in Java?

By example, Safari have "Report Bugs...", "Block Pop-Up", "Private Browsing...", etc. :

Custom Application Menu in Mac OS X

Any idea ?


The OSXAdapter example application shows how to do this.

Addendum:

it looks like it only defines About/Preferences/Quit handlers

Yes, Services and Hide/Show are supplied by the system. It sounds like you want to add menu items between Preferences and Services. Unfortunately, I've not tried that. You might look in com.apple.eawt for alternatives. I can see it would be convenient; but for reference, NetBeans, Eclipse, et al. use the existing functionality.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜