本文整理汇总了Java中com.trollworks.toolkit.ui.menu.help.AboutCommand类的典型用法代码示例。如果您正苦于以下问题:Java AboutCommand类的具体用法?Java AboutCommand怎么用?Java AboutCommand使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
AboutCommand类属于com.trollworks.toolkit.ui.menu.help包,在下文中一共展示了AboutCommand类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createMenu
import com.trollworks.toolkit.ui.menu.help.AboutCommand; //导入依赖的package包/类
@Override
public JMenu createMenu() {
JMenu menu = new JMenu(HELP);
menu.setName(NAME);
if (!Platform.isMacintosh()) {
menu.add(new JMenuItem(AboutCommand.INSTANCE));
menu.addSeparator();
}
menu.add(new JMenuItem(UpdateCommand.INSTANCE));
menu.addSeparator();
menu.add(new JMenuItem(new OpenURICommand(RELEASE_NOTES, GCSApp.WEB_SITE + "/release_notes.html"))); //$NON-NLS-1$
menu.add(new JMenuItem(new OpenURICommand(LICENSE, App.getHomePath().resolve("license.html").toUri()))); //$NON-NLS-1$
menu.addSeparator();
menu.add(new JMenuItem(new OpenURICommand(WEB_SITE, GCSApp.WEB_SITE)));
menu.add(new JMenuItem(new OpenURICommand(MAILING_LISTS, GCSApp.WEB_SITE + "/mailing_lists.html"))); //$NON-NLS-1$
menu.add(new JMenuItem(new OpenURICommand(FEATURE_REQUESTS, "https://gurpscharactersheet.atlassian.net/issues/?filter=10000"))); //$NON-NLS-1$
menu.add(new JMenuItem(new OpenURICommand(BUG_REPORTS, "https://gurpscharactersheet.atlassian.net/issues/?filter=10001"))); //$NON-NLS-1$
DynamicMenuEnabler.add(menu);
return menu;
}
示例2: App
import com.trollworks.toolkit.ui.menu.help.AboutCommand; //导入依赖的package包/类
/** Creates a new {@link App}. */
protected App() {
if (Platform.isMacintosh()) {
Application app = Application.getApplication();
app.setAboutHandler(AboutCommand.INSTANCE);
app.setPreferencesHandler(PreferencesCommand.INSTANCE);
app.setOpenFileHandler(OpenCommand.INSTANCE);
app.setPrintFileHandler(PrintCommand.INSTANCE);
app.setQuitHandler(QuitCommand.INSTANCE);
app.setQuitStrategy(QuitStrategy.SYSTEM_EXIT_0);
app.disableSuddenTermination();
}
}