1 19 20 package org.netbeans.editor; 21 22 import java.beans.PropertyChangeListener ; 23 import javax.swing.text.JTextComponent ; 24 import org.netbeans.modules.editor.lib2.DocumentsJumpList; 25 import org.openide.util.WeakListeners; 26 27 36 public class JumpList { 37 38 static void addPropertyChangeListener(PropertyChangeListener listener) { 39 PropertyChangeListener pcl = WeakListeners.propertyChange(listener, null); 40 DocumentsJumpList.addPropertyChangeListener(pcl); 41 } 42 43 static void dotMoved(JTextComponent c, int offset) { 44 DocumentsJumpList.dotMoved(c, offset); 45 } 46 47 public static void checkAddEntry() { 48 DocumentsJumpList.checkAddEntry(); 49 } 50 51 public static void checkAddEntry(JTextComponent c) { 52 DocumentsJumpList.checkAddEntry(c); 53 } 54 55 public static void checkAddEntry(JTextComponent c, int pos) { 56 DocumentsJumpList.checkAddEntry(c, pos); 57 } 58 59 public static void addEntry(JTextComponent c, int pos) { 60 DocumentsJumpList.addEntry(c, pos); 61 } 62 63 67 public static void jumpPrev(JTextComponent c) { 68 DocumentsJumpList.jumpPrev(c); 69 } 70 71 public static boolean hasPrev() { 72 return DocumentsJumpList.hasPrev(); 73 } 74 75 79 public static void jumpNext(JTextComponent c) { 80 DocumentsJumpList.jumpNext(c); 81 } 82 83 public static boolean hasNext() { 84 return DocumentsJumpList.hasNext(); 85 } 86 87 91 public static void jumpPrevComponent(JTextComponent c) { 92 DocumentsJumpList.jumpPrevComponent(c); 93 } 94 95 99 public static void jumpNextComponent(JTextComponent c) { 100 DocumentsJumpList.jumpNextComponent(c); 101 } 102 103 public static String dump() { 104 return DocumentsJumpList.dump(); 105 } 106 } 107 | Popular Tags |