/** * Called by VISAT after the plug-in instance has been registered in VISAT's plug-in manager. * * @param visatApp a reference to the VISAT application instance. */ public void start(VisatApp visatApp) { if (!isVersionCheckQuestionSuppressed() || isVersionCheckEnabled()) { final Timer timer = new Timer(DELAY_MILLIS, new ActionListener() { public void actionPerformed(ActionEvent e) { runAuto(); } }); timer.setRepeats(false); timer.start(); } CommandAdapter versionCheckerAction = new CommandAdapter() { @Override public void actionPerformed(CommandEvent event) { runManual(); } }; CommandManager commandManager = visatApp.getCommandManager(); ExecCommand versionCheckerCommand = commandManager.createExecCommand("checkForUpdate", versionCheckerAction); versionCheckerCommand.setText("Check for New Release..."); versionCheckerCommand.setShortDescription("Checks for a new release"); versionCheckerCommand.setParent("help"); versionCheckerCommand.setPlaceAfter("showUpdateDialog"); versionCheckerCommand.setPlaceBefore("about"); }
command.setParent("showToolViews"); command.setSmallIcon(getSmallIcon()); command.setLargeIcon(getLargeIcon());