@Override public void actionPerformed(ActionEvent e) { if (!invokeDefaultAction((JTextComponent) e.getSource())) { // sorry, don't know how to do without deprecated ImplementationProvider @SuppressWarnings("deprecation") Action actions[] = org.netbeans.editor.ImplementationProvider.getDefault().getGlyphGutterActions((JTextComponent) e.getSource()); if (actions == null) { return ; } int nextAction = 0; while (nextAction < actions.length && actions[nextAction] != this) { nextAction++; } nextAction++; if (actions.length > nextAction) { Action a = actions[nextAction]; if (a!=null && a.isEnabled()){ a.actionPerformed(e); } } } }
@Override public void actionPerformed( ActionEvent event ) { JTextComponent comp = (JTextComponent) event.getSource(); if (!performCdiAction(comp)) { Action actions[] = ImplementationProvider.getDefault(). getGlyphGutterActions(comp); if (actions == null) return ; int nextIndex = 0; while (nextIndex < actions.length && actions[nextIndex] != this) { nextIndex++; } nextIndex++; if (actions.length > nextIndex) { Action action = actions[nextIndex]; if (action!=null && action.isEnabled()){ action.actionPerformed(event); } } } }
annos.activateNextAnnotation(line); } else { Action actions[] = ImplementationProvider.getDefault().getGlyphGutterActions(editorUI.getComponent()); if (actions != null && actions.length >0) { Action a = actions[0]; //TODO - create GUI chooser