bugged
stringlengths
6
599k
fixed
stringlengths
6
40.8M
__index_level_0__
int64
0
3.24M
public void mousePressed(MouseEvent e) { MenuSelectionManager manager = MenuSelectionManager.defaultManager(); JMenu menu = (JMenu) menuItem; manager.processMouseEvent(e); // Menu should be displayed when the menu is pressed only if // it is top-level menu if (menu.isTopLevelMenu()...
public void mousePressed(MouseEvent e) { MenuSelectionManager manager = MenuSelectionManager.defaultManager(); JMenu menu = (JMenu) menuItem; manager.processMouseEvent(e); // Menu should be displayed when the menu is pressed only if // it is top-level menu if (menu.isTopLevelMenu()...
8,530
public void mousePressed(MouseEvent e) { MenuSelectionManager manager = MenuSelectionManager.defaultManager(); JMenu menu = (JMenu) menuItem; manager.processMouseEvent(e); // Menu should be displayed when the menu is pressed only if // it is top-level menu if (menu.isTopLevelMenu()...
public void mousePressed(MouseEvent e) { MenuSelectionManager manager = MenuSelectionManager.defaultManager(); JMenu menu = (JMenu) menuItem; manager.processMouseEvent(e); // Menu should be displayed when the menu is pressed only if // it is top-level menu if (menu.isTopLevelMenu()...
8,531
protected void installKeyboardActions() throws NotImplementedException { // FIXME: Need to implement }
protected void installKeyboardActions() { // FIXME: Need to implement }
8,533
protected void installKeyboardActions() throws NotImplementedException { // FIXME: Need to implement }
super.installKeyboardActions(); super.installKeyboardActions(); protectedsuper.installKeyboardActions(); voidsuper.installKeyboardActions(); installKeyboardActions()super.installKeyboardActions(); super.installKeyboardActions(); super.installKeyboardActions(); super.installKeyboardActions(); throwssuper.installKeyboard...
8,534
protected void installListeners() { ((JMenu) menuItem).addMouseListener(mouseInputListener); ((JMenu) menuItem).addMouseMotionListener(mouseInputListener); ((JMenu) menuItem).addMenuListener(menuListener); ((JMenu) menuItem).addMenuDragMouseListener(menuDragMouseListener); }
protected void installListeners() { ((JMenu) menuItem).addMouseListener(mouseInputListener); ((JMenu) menuItem).addMouseMotionListener(mouseInputListener); ((JMenu) menuItem).addMenuListener(menuListener); ((JMenu) menuItem).addMenuDragMouseListener(menuDragMouseListener); }
8,535
protected void installListeners() { ((JMenu) menuItem).addMouseListener(mouseInputListener); ((JMenu) menuItem).addMouseMotionListener(mouseInputListener); ((JMenu) menuItem).addMenuListener(menuListener); ((JMenu) menuItem).addMenuDragMouseListener(menuDragMouseListener); }
protected void installListeners() { ((JMenu) menuItem).addMouseListener(mouseInputListener); ((JMenu) menuItem).addMouseMotionListener(mouseInputListener); ((JMenu) menuItem).addMenuListener(menuListener); }
8,536
protected void setupPostTimer(JMenu menu) { // TODO: Implement this properly. }
Timer timer = new Timer(menu.getDelay(), new SelectMenuAction()); timer.setRepeats(false); timer.start(); Timer timer = new Timer(menu.getDelay(), new SelectMenuAction()); timer.setRepeats(false); timer.start(); protectedTimer timer = new Timer(menu.getDelay(), new SelectMenuAction()); timer.setRepeats(false); timer.st...
8,537
protected void uninstallKeyboardActions() throws NotImplementedException { // FIXME: Need to implement }
protected void uninstallKeyboardActions() { // FIXME: Need to implement }
8,538
protected void uninstallKeyboardActions() throws NotImplementedException { // FIXME: Need to implement }
super.installKeyboardActions(); super.installKeyboardActions(); protectedsuper.installKeyboardActions(); voidsuper.installKeyboardActions(); uninstallKeyboardActions()super.installKeyboardActions(); super.installKeyboardActions(); super.installKeyboardActions(); super.installKeyboardActions(); throwssuper.installKeyboa...
8,539
protected void uninstallListeners() { ((JMenu) menuItem).removeMouseListener(mouseInputListener); ((JMenu) menuItem).removeMenuListener(menuListener); ((JMenu) menuItem).removePropertyChangeListener(propertyChangeListener); }
protected void uninstallListeners() { super.uninstallListeners(); ((JMenu) menuItem).removeMenuListener(menuListener); ((JMenu) menuItem).removePropertyChangeListener(propertyChangeListener); }
8,540
protected void uninstallListeners() { ((JMenu) menuItem).removeMouseListener(mouseInputListener); ((JMenu) menuItem).removeMenuListener(menuListener); ((JMenu) menuItem).removePropertyChangeListener(propertyChangeListener); }
protected void uninstallListeners() { ((JMenu) menuItem).removeMouseListener(mouseInputListener); ((JMenu) menuItem).removeMenuListener(menuListener); }
8,541
static String absolutize(String base, String href) { if (href == null) return null; int ci = href.indexOf(':'); if (ci > 1 && isLowercaseAscii(href.substring(0, ci))) { // href is absolute already return href; } if (base == null) base = ""; else { int i = ...
public static String absolutize(String base, String href) throws MalformedURLException { if (href == null) return null; int ci = href.indexOf(':'); if (ci > 1 && isLowercaseAscii(href.substring(0, ci))) { // href is absolute already return href; } if (base == null) base ...
8,542
static String absolutize(String base, String href) { if (href == null) return null; int ci = href.indexOf(':'); if (ci > 1 && isLowercaseAscii(href.substring(0, ci))) { // href is absolute already return href; } if (base == null) base = ""; else { int i = ...
static String absolutize(String base, String href) { if (href == null) return null; int ci = href.indexOf(':'); if (ci > 1 && isURLScheme(href.substring(0, ci))) { // href is absolute already return href; } if (base == null) base = ""; else { int i = base....
8,543
static String absolutize(String base, String href) { if (href == null) return null; int ci = href.indexOf(':'); if (ci > 1 && isLowercaseAscii(href.substring(0, ci))) { // href is absolute already return href; } if (base == null) base = ""; else { int i = ...
static String absolutize(String base, String href) { if (href == null) return null; int ci = href.indexOf(':'); if (ci > 1 && isLowercaseAscii(href.substring(0, ci))) { // href is absolute already return href; } if (base == null) base = ""; else { int i = ...
8,544
private InputStream resolve(String url) throws IOException { try { return new URL(url).openStream(); } catch (MalformedURLException e) { return null; } }
static InputStream resolve(String url) throws IOException { try { return new URL(url).openStream(); } catch (MalformedURLException e) { return null; } }
8,545
public void menuDragMouseReleased(MenuDragMouseEvent e) { MenuElement[] path = e.getPath(); if (path[path.length - 1] instanceof JMenuItem) ((JMenuItem) path[path.length - 1]).doClick(); MenuSelectionManager manager = MenuSelectionManager.defaultManager(); manager.clearSelectedPath(); }
public void menuDragMouseReleased(MenuDragMouseEvent e) { MenuElement[] path = e.getPath(); if (path[path.length - 1] instanceof JMenuItem) ((JMenuItem) path[path.length - 1]).doClick(); MenuSelectionManager manager = MenuSelectionManager.defaultManager(); manager.clearSelectedPath(); }
8,548
public void mouseEntered(MouseEvent e) { Component source = (Component) e.getSource(); if (source.getParent() instanceof MenuElement) { MenuSelectionManager manager = MenuSelectionManager.defaultManager(); manager.setSelectedPath(getPath()); manager.processMouseEvent(e); } }
public void mouseEntered(MouseEvent e) { Component source = (Component) e.getSource(); if (source.getParent() instanceof MenuElement) { MenuSelectionManager manager = MenuSelectionManager.defaultManager(); manager.setSelectedPath(getPath()); manager.processMouseEvent(e); } }
8,549
public void mouseReleased(MouseEvent e) { Rectangle size = menuItem.getBounds(); MenuSelectionManager manager = MenuSelectionManager.defaultManager(); if (e.getX() > 0 && e.getX() < size.width && e.getY() > 0 && e.getY() < size.height) { manager.clearSelectedPath(); menuItem.do...
public void mouseReleased(MouseEvent e) { Rectangle size = menuItem.getBounds(); MenuSelectionManager manager = MenuSelectionManager.defaultManager(); if (e.getX() > 0 && e.getX() < size.width && e.getY() > 0 && e.getY() < size.height) { manager.clearSelectedPath(); menuItem.do...
8,550
public void mouseReleased(MouseEvent e) { Rectangle size = menuItem.getBounds(); MenuSelectionManager manager = MenuSelectionManager.defaultManager(); if (e.getX() > 0 && e.getX() < size.width && e.getY() > 0 && e.getY() < size.height) { manager.clearSelectedPath(); menuItem.do...
public void mouseReleased(MouseEvent e) { Rectangle size = menuItem.getBounds(); MenuSelectionManager manager = MenuSelectionManager.defaultManager(); if (e.getX() > 0 && e.getX() < size.width && e.getY() > 0 && e.getY() < size.height) { manager.clearSelectedPath(); menuItem.do...
8,551
public MenuElement[] getPath() { ArrayList path = new ArrayList(); // Path to menu should also include its popup menu. if (menuItem instanceof JMenu) path.add(((JMenu) menuItem).getPopupMenu()); Component c = menuItem; while (c instanceof MenuElement) { path.add(0, (MenuElement) c); if (c in...
public MenuElement[] getPath() { ArrayList path = new ArrayList(); // Path to menu should also include its popup menu. if (menuItem instanceof JMenu) path.add(((JMenu) menuItem).getPopupMenu()); Component c = menuItem; while (c instanceof MenuElement) { path.add(0, (MenuElement) c); if (c in...
8,552
public MenuElement[] getPath() { ArrayList path = new ArrayList(); // Path to menu should also include its popup menu. if (menuItem instanceof JMenu) path.add(((JMenu) menuItem).getPopupMenu()); Component c = menuItem; while (c instanceof MenuElement) { path.add(0, (MenuElement) c); if (c in...
public MenuElement[] getPath() { ArrayList path = new ArrayList(); // Path to menu should also include its popup menu. if (menuItem instanceof JMenu) path.add(((JMenu) menuItem).getPopupMenu()); Component c = menuItem; while (c instanceof MenuElement) { path.add(0, (MenuElement) c); if (c in...
8,553
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
8,554
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
8,555
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
8,556
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
8,557
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
8,558
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
8,559
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
protected Dimension getPreferredMenuItemSize(JComponent c, Icon checkIcon, Icon arrowIcon, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Dimension d = BasicGraphicsUtils.getPreferredButtonSize(m, ...
8,560
private void paintAccelerator(Graphics g, JMenuItem menuItem, Rectangle acceleratorRect, String acceleratorText) { g.setFont(acceleratorFont); FontMetrics fm = g.getFontMetrics(acceleratorFont); if (menuItem.isEnabled()) g.setColor(accelerator...
private void paintAccelerator(Graphics g, JMenuItem menuItem, Rectangle acceleratorRect, String acceleratorText) { g.setFont(acceleratorFont); FontMetrics fm = g.getFontMetrics(acceleratorFont); if (menuItem.isEnabled()) g.setColor(accelerator...
8,561
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,562
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,563
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,564
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,565
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,566
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,567
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,568
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,569
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,570
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
protected void paintMenuItem(Graphics g, JComponent c, Icon checkIcon, Icon arrowIcon, Color background, Color foreground, int defaultTextIconGap) { JMenuItem m = (JMenuItem) c; Rectangle tr = new Rectangle(); // text rectangle Rectangle ir = new R...
8,571
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
8,572
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
8,573
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
8,574
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
8,575
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
8,576
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
8,577
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
protected void paintText(Graphics g, JMenuItem menuItem, Rectangle textRect, String text) { Font f = menuItem.getFont(); g.setFont(f); FontMetrics fm = g.getFontMetrics(f); if (text != null && !text.equals("")) { if (menuItem.isEnabled()) { // Menu item ...
8,578
public void run() { try { synchronized (queueLock) { try { queueLock.wait(initialDelay); } catch (InterruptedException e) { // Ignored } if (!runnin...
public void run() { try { synchronized (queueLock) { try { queueLock.wait(initialDelay); } catch (InterruptedException e) { // Ignored } if (!runnin...
8,579
public void run() { try { synchronized (queueLock) { try { queueLock.wait(initialDelay); } catch (InterruptedException e) { // Ignored } if (!runnin...
public void run() { try { synchronized (queueLock) { try { queueLock.wait(initialDelay); } catch (InterruptedException e) { // Ignored } if (!runnin...
8,580
void queueEvent() { synchronized (queueLock) { queue++; if (queue == 1) SwingUtilities.invokeLater(drainer); } }
void queueEvent() { synchronized (queueLock) { queue++; if (queue == 1) SwingUtilities.invokeLater(drainer); } }
8,582
void queueEvent() { synchronized (queueLock) { queue++; if (queue == 1) SwingUtilities.invokeLater(drainer); } }
void queueEvent() { synchronized (queueLock) { queue++; if (queue == 1) SwingUtilities.invokeLater(drainer); }
8,583
public void start() { synchronized (queueLock) { if (waker != null) return; waker = new Waker(); waker.start(); } }
public void start() { synchronized (queueLock) { if (waker != null) return; waker = new Waker(); waker.start(); } }
8,584
public void stop() { synchronized (queueLock) { running = false; queue = 0; if (waker != null) queueLock.notifyAll(); waker = null; } }
public void stop() { synchronized (queueLock) { running = false; queue = 0; if (waker != null) queueLock.notifyAll(); waker = null; } }
8,586
public Area(Shape s) { }
public Area() { }
8,587
public void transform(AffineTransform at) { // XXX Implement. throw new Error("not implemented"); }
public void transform(AffineTransform at) { // XXX Implement. for (int i = 0; i < solids.size(); i++) ((Segment) solids.elementAt(i)).transformSegmentList(at); for (int i = 0; i < holes.size(); i++) ((Segment) holes.elementAt(i)).transformSegmentList(at); if ((at.getType() & AffineTransform.TYPE_FLIP) != 0) {...
8,589
public boolean contains(double x, double y) { // XXX Implement. throw new Error("not implemented"); }
public boolean contains(double x, double y) { // XXX Implement. int n = 0; for (int i = 0; i < solids.size(); i++) if (((Segment) solids.elementAt(i)).contains(x, y)) n++; for (int i = 0; i < holes.size(); i++) if (((Segment) holes.elementAt(i)).contains(x, y)) n--; return (n != 0); }
8,591
public boolean equals(Object obj) { if (obj instanceof UID) { UID uid = (UID)obj; if (this.unique == uid.unique && this.time == uid.time && this.count == uid.count) { return (true); } } return (false);}
public boolean equals(Object obj) { if (obj instanceof UID) { UID uid = (UID)obj; if (this.unique == uid.unique && this.time == uid.time && this.count == uid.count) { return (true); } } return (false);}
8,592
public int hashCode() { return (unique);}
public int hashCode() { return (unique);}
8,593
public int signum() { int top = words == null ? ival : words[ival-1]; if (top == 0 && words == null) return 0; return top < 0 ? -1 : 1; }
public int signum() { int top = words == null ? ival : words[ival-1]; if (top == 0 && words == null) return 0; return top < 0 ? -1 : 1; }
8,597
private void writeObject(ObjectOutputStream s) throws IOException, ClassNotFoundException { signum = signum(); magnitude = toByteArray(); s.defaultWriteObject(); }
private void writeObject(ObjectOutputStream s) throws IOException, ClassNotFoundException { signum = signum(); magnitude = signum == 0 ? new byte[0] : toByteArray(); s.defaultWriteObject(); }
8,598
public EmulatorAction(Session session, String name, KeyStroke ks, KeyMapper keyMap) { this(session,name); setKeyStroke(name, ks, keyMap); }
public EmulatorAction(Session session, String name) { this(session,name); setKeyStroke(name, ks, keyMap); }
8,599
public EmulatorAction(Session session, String name, KeyStroke ks, KeyMapper keyMap) { this(session,name); setKeyStroke(name, ks, keyMap); }
public EmulatorAction(Session session, String name, KeyStroke ks, KeyMapper keyMap) { this(session,name); setKeyStroke(name, ks, keyMap); }
8,600
protected void startPlugin() throws PluginException { try { final DeviceManager dm = DeviceUtils.getDeviceManager(); dm.addListener(this); final Collection devs = dm.getDevices(); for (Iterator i = devs.iterator(); i.hasNext();) { addListeners((Devic...
protected void startPlugin() throws PluginException { try { final DeviceManager dm = DeviceUtils.getDeviceManager(); dm.addListener(this); final Collection devs = new ArrayList(dm.getDevices()); for (Iterator i = devs.iterator(); i.hasNext();) { addL...
8,601
public Object action (SaxDocumentHandler handler, Attributes attrs) throws SAXException { // we only need to do these things for the first time we enter // a data node if (DataNodeLevel == 0) { // A little 'pre-handling' as href is a specialattribute ...
public Object action (SaxDocumentHandler handler, Attributes attrs) throws SAXException { // we only need to do these things for the first time we enter // a data node if (DataNodeLevel == 0) { // A little 'pre-handling' as href is a specialattribute ...
8,602
public Array appendArrayToArray ( Array arrayToAppendTo, Array arrayToAdd ) { if (arrayToAppendTo != null) { List origAxisList = arrayToAppendTo.getAxes(); List addAxisList = arrayToAdd.getAxes(); Hashtable correspondingAddAxis = ne...
public Array appendArrayToArray ( Array arrayToAppendTo, Array arrayToAdd ) { if (arrayToAppendTo != null) { List origAxisList = arrayToAppendTo.getAxes(); List addAxisList = arrayToAdd.getAxes(); Hashtable correspondingAddAxis = ne...
8,603
protected void fireActionPerformed() { ActionEvent event = new ActionEvent(this, 0, getText()); ActionListener[] listeners = getActionListeners(); for (int index = 0; index < listeners.length; ++index) listeners[index].actionPerformed(event); }
protected void fireActionPerformed() { ActionEvent event = new ActionEvent(this, 0, actionCommand == null ? getText() : actionCommand); ActionListener[] listeners = getActionListeners(); for (int index = 0; index < listeners.length; ++index) listeners[index].actionPerformed(event); }
8,604
public static void main(String[] args) throws NoSuchAliasException, NameNotFoundException { ParsedArguments cmdLine = HELP_INFO.parse(args); final Shell shell = ShellUtils.getShellManager().getCurrentShell(); final AliasManager aliasMgr = shell.getAliasManager(); if (cmdLine.size() == 0) { for (Iterator i = alia...
public static void main(String[] args) throws NoSuchAliasException, NameNotFoundException { ParsedArguments cmdLine = HELP_INFO.parse(args); final Shell shell = ShellUtils.getShellManager().getCurrentShell(); final AliasManager aliasMgr = shell.getAliasManager(); if (cmdLine.size() == 0) { for (Iterator i = alia...
8,606
private DeviceToDriverMapper newMapperInstance(Class cls, ConfigurationElement element) throws InstantiationException, IllegalAccessException { try { final Constructor c = cls.getConstructor(new Class[] { ConfigurationElement.class }); try { return (DeviceToDriverMapper)c...
private DeviceToDriverMapper newMapperInstance(Class cls, ConfigurationElement element) throws InstantiationException, IllegalAccessException { try { final Constructor c = cls.getConstructor(new Class[] { ConfigurationElement.class }); try { return (DeviceToDriverMapper)c...
8,607
public float getPreferredSpan(int axis) { if (view != null) return view.getPreferredSpan(axis); return Integer.MAX_VALUE; }
public float getPreferredSpan(int axis) { float span = 10; if (view != null) return view.getPreferredSpan(axis); return Integer.MAX_VALUE; }
8,609
public float getPreferredSpan(int axis) { if (view != null) return view.getPreferredSpan(axis); return Integer.MAX_VALUE; }
public float getPreferredSpan(int axis) { if (view != null) return view.getPreferredSpan(axis); return Integer.MAX_VALUE; }
8,610
public void paint(Graphics g, Shape s) { if (view != null) { Rectangle b = s.getBounds(); view.setSize(b.width, b.height); view.paint(g, s); } }
public void paint(Graphics g, Shape s) { if (view != null) { Rectangle b = s.getBounds(); view.setSize(b.width, b.height); view.paint(g, s); } }
8,612
public void setSize(float w, float h) { if (view != null) view.setSize(w, h); }
public synchronized void setSize(float w, float h) { if (view != null) view.setSize(w, h); }
8,614
public Dimension getMaximumSize(JComponent c) { // Sun's implementation returns Integer.MAX_VALUE here, so do we. return new Dimension(Integer.MAX_VALUE, Integer.MAX_VALUE); }
public Dimension getMaximumSize(JComponent c) { // Sun's implementation returns Integer.MAX_VALUE here, so do we. Dimension d = new Dimension(); Insets i = c.getInsets(); Document doc = textComponent.getDocument(); if (doc instanceof AbstractDocument) ((AbstractDocument) doc).readLock(); try { d.width = (int...
8,616
public Dimension getMinimumSize(JComponent c) { Insets i = c.getInsets(); return new Dimension(i.left + i.right, i.top + i.bottom); }
public Dimension getMinimumSize(JComponent c) { Insets i = c.getInsets(); d.width += i.left + i.right; d.height += i.top + i.bottom; return d; }
8,617
public int getNextVisualPositionFrom(JTextComponent t, int pos, Position.Bias b, int direction, Position.Bias[] biasRet) throws BadLocationException { // A comment in the spec of NavigationFilter.getNextVisualPositionFrom() // sugge...
public int getNextVisualPositionFrom(JTextComponent t, int pos, Position.Bias b, int direction, Position.Bias[] biasRet) throws BadLocationException { // A comment in the spec of NavigationFilter.getNextVisualPositionFrom() // sugge...
8,618
public Dimension getPreferredSize(JComponent c) { Dimension d = c.getSize(); Insets i = c.getInsets(); if (d.width > (i.left + i.right) && d.height > (i.top + i.bottom)) { rootView.setSize(d.width - i.left - i.right, d.height - i.top - i.bottom); } float w = rootV...
public Dimension getPreferredSize(JComponent c) { Dimension d = c.getSize(); Insets i = c.getInsets(); if (d.width > (i.left + i.right) && d.height > (i.top + i.bottom)) { rootView.setSize(d.width - i.left - i.right, d.height - i.top - i.bottom); } float w = rootV...
8,620
protected Rectangle getVisibleEditorRect() { int width = textComponent.getWidth(); int height = textComponent.getHeight(); // Return null if the component has no valid size. if (width <= 0 || height <= 0) return null; Insets insets = textComponent.getInsets(); return new Rectangle(insets.left...
protected Rectangle getVisibleEditorRect() { int width = textComponent.getWidth(); int height = textComponent.getHeight(); // Return null if the component has no valid size. if (width <= 0 || height <= 0) return null; Insets insets = textComponent.getInsets(cachedInsets); return new Rectangle...
8,621
protected void installDefaults() { String prefix = getPropertyPrefix(); // Install the standard properties. LookAndFeel.installColorsAndFont(textComponent, prefix + ".background", prefix + ".foreground", prefix + ".font"); LookAndFeel.installBorder(textComponent, prefi...
protected void installDefaults() { String prefix = getPropertyPrefix(); // Install the standard properties. LookAndFeel.installColorsAndFont(textComponent, prefix + ".background", prefix + ".foreground", prefix + ".font"); LookAndFeel.installBorder(textComponent, prefi...
8,622
protected void installDefaults() { String prefix = getPropertyPrefix(); // Install the standard properties. LookAndFeel.installColorsAndFont(textComponent, prefix + ".background", prefix + ".foreground", prefix + ".font"); LookAndFeel.installBorder(textComponent, prefi...
protected void installDefaults() { String prefix = getPropertyPrefix(); // Install the standard properties. LookAndFeel.installColorsAndFont(textComponent, prefix + ".background", prefix + ".foreground", prefix + ".font"); LookAndFeel.installBorder(textComponent, prefi...
8,623
protected void installDefaults() { String prefix = getPropertyPrefix(); // Install the standard properties. LookAndFeel.installColorsAndFont(textComponent, prefix + ".background", prefix + ".foreground", prefix + ".font"); LookAndFeel.installBorder(textComponent, prefi...
protected void installDefaults() { String prefix = getPropertyPrefix(); // Install the standard properties. LookAndFeel.installColorsAndFont(textComponent, prefix + ".background", prefix + ".foreground", prefix + ".font"); LookAndFeel.installBorder(textComponent, prefi...
8,624
protected void installListeners() { textComponent.addFocusListener(focuslistener); }
protected void installListeners() { if (SystemProperties.getProperty("gnu.swing.text.no-xlike-clipboard") == null) { if (focusListener == null) focusListener = new FocusHandler(); textComponent.addFocusListener(focusListener); } }
8,625
public void installUI(final JComponent c) { textComponent = (JTextComponent) c; installDefaults(); textComponent.addPropertyChangeListener(updateHandler); Document doc = textComponent.getDocument(); if (doc == null) { doc = getEditorKit(textComponent).createDefaultDocument(); textComponent.setDoc...
public void installUI(final JComponent c) { textComponent = (JTextComponent) c; installDefaults(); installFixedDefaults(); if (handler == null) handler = new Handler(); textComponent.addPropertyChangeListener(handler); Document doc = textComponent.getDocument(); if (doc == null) { doc = getEd...
8,626
public void installUI(final JComponent c) { textComponent = (JTextComponent) c; installDefaults(); textComponent.addPropertyChangeListener(updateHandler); Document doc = textComponent.getDocument(); if (doc == null) { doc = getEditorKit(textComponent).createDefaultDocument(); textComponent.setDoc...
public void installUI(final JComponent c) { textComponent = (JTextComponent) c; installDefaults(); textComponent.addPropertyChangeListener(updateHandler); Document doc = textComponent.getDocument(); if (doc == null) { doc = getEditorKit(textComponent).createDefaultDocument(); textComponent.setDoc...
8,627
public final void paint(Graphics g, JComponent c) { try { Document doc = textComponent.getDocument(); if (doc instanceof AbstractDocument) { AbstractDocument aDoc = (AbstractDocument) doc; aDoc.readLock(); } paintSafely(g); } finally {...
publicfinalvoidpaint(Graphicsg,JComponentc){try{Documentdoc=textComponent.getDocument();if(docinstanceofAbstractDocument){AbstractDocumentaDoc=(AbstractDocument)doc;aDoc.readLock();}paintSafely(g);}finally{Documentdoc=textComponent.getDocument();if(docinstanceofAbstractDocument){AbstractDocumentaDoc=(AbstractDocument)d...
8,628
protected void paintSafely(Graphics g) { Caret caret = textComponent.getCaret(); Highlighter highlighter = textComponent.getHighlighter(); if (textComponent.isOpaque()) paintBackground(g); // Try painting with the highlighter without checking whether there // is a selection because a high...
protectedvoidpaintSafely(Graphicsg){Caretcaret=textComponent.getCaret();Highlighterhighlighter=textComponent.getHighlighter();if(textComponent.isOpaque())paintBackground(g);//Trypaintingwiththehighlighterwithoutcheckingwhetherthere//isaselectionbecauseahighlightercanbeusedtodomorethan//markingselectedtext.if(highlighte...
8,629
protected void uninstallDefaults() { // Do nothing here. }
if (textComponent.getCaretColor() instanceof UIResource) textComponent.setCaretColor(null); if (textComponent.getSelectionColor() instanceof UIResource) textComponent.setSelectionColor(null); if (textComponent.getDisabledTextColor() instanceof UIResource) textComponent.setDisabledTextColor(null); if (textComponent.getS...
8,630
protected void uninstallListeners() { textComponent.removeFocusListener(focuslistener); textComponent.getDocument().removeDocumentListener(documentHandler); }
protected void uninstallListeners() { textComponent.removeFocusListener(focuslistener); textComponent.getDocument().removeDocumentListener(documentHandler); }
8,631
public void uninstallUI(final JComponent component) { super.uninstallUI(component); rootView.setView(null); uninstallDefaults(); uninstallListeners(); uninstallKeyboardActions(); textComponent = null; }
public void uninstallUI(final JComponent component) { textComponent.removePropertyChangeListener(handler); textComponent.getDocument().removeDocumentListener(handler); rootView.setView(null); uninstallDefaults(); uninstallListeners(); uninstallKeyboardActions(); textComponent = null; }
8,632
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
8,634
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
8,635
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
8,636
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
8,637
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
8,638
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
public void toXMLOutputStream (OutputStream outputstream, String indent) throws java.io.IOException { if (Specification.getInstance().isPrettyXDFOutput()) writeOut(outputstream, indent); // indent node if desired // no need to have repeatable set to 'yes' would just waste space even if we used ...
8,639
public boolean match(Certificate certificate) { if (!(certificate instanceof X509Certificate)) return false; X509Certificate cert = (X509Certificate) certificate; if (this.cert != null) { try { byte[] e1 = this.cert.getEncoded(); byte[] e2 = cert.getEncoded();...
public boolean match(Certificate certificate) { if (!(certificate instanceof X509Certificate)) return false; X509Certificate cert = (X509Certificate) certificate; if (this.cert != null) { try { byte[] e1 = this.cert.getEncoded(); byte[] e2 = cert.getEncoded();...
8,640
protected PropertyChangeListener createActionPropertyChangeListener(Action a) { return new PropertyChangeListener() { public void propertyChange(PropertyChangeEvent e) { Action act = (Action) (e.getSource()); if (e.getPropertyName().equals(AbstractAction.ENABLED_PROPERTY)) setE...
protected PropertyChangeListener createActionPropertyChangeListener(Action a) { return new PropertyChangeListener() { public void propertyChange(PropertyChangeEvent e) { Action act = (Action) (e.getSource()); if (e.getPropertyName().equals(AbstractAction.ENABLED_PROPERTY)) setE...
8,641
public void propertyChange(PropertyChangeEvent e) { Action act = (Action) (e.getSource()); if (e.getPropertyName().equals(AbstractAction.ENABLED_PROPERTY)) setEnabled(act.isEnabled()); else if (e.getPropertyName().equals(Action.NAME)) setText((String)(act.getValue(Action.NAME...
public void propertyChange(PropertyChangeEvent e) { Action act = (Action) (e.getSource()); if (e.getPropertyName().equals(AbstractAction.ENABLED_PROPERTY)) setEnabled(act.isEnabled()); else if (e.getPropertyName().equals(Action.NAME)) setText((String)(act.getValue(Action.NAME...
8,642
public void fireActionPerformed(ActionEvent e) { e.setSource(this); ActionListener[] listeners = getActionListeners(); for (int i = 0; i < listeners.length; i++) listeners[i].actionPerformed(e); }
protected void fireActionPerformed(ActionEvent e) { e.setSource(this); ActionListener[] listeners = getActionListeners(); for (int i = 0; i < listeners.length; i++) listeners[i].actionPerformed(e); }
8,643
public void fireItemStateChanged(ItemEvent e) { e.setSource(this); ItemListener[] listeners = getItemListeners(); for (int i = 0; i < listeners.length; i++) listeners[i].itemStateChanged(e); }
protected void fireItemStateChanged(ItemEvent e) { e.setSource(this); ItemListener[] listeners = getItemListeners(); for (int i = 0; i < listeners.length; i++) listeners[i].itemStateChanged(e); }
8,644
public void fireStateChanged() { ChangeListener[] listeners = getChangeListeners(); for (int i = 0; i < listeners.length; i++) listeners[i].stateChanged(changeEvent); }
protected void fireStateChanged() { ChangeListener[] listeners = getChangeListeners(); for (int i = 0; i < listeners.length; i++) listeners[i].stateChanged(changeEvent); }
8,645
protected String paramString() { return "AbstractButton"; }
protected String paramString() { StringBuffer sb = new StringBuffer(); sb.append(super.paramString()); sb.append(",defaultIcon="); if (getIcon() != null) sb.append(getIcon()); sb.append(",disabledIcon="); if (getDisabledIcon() != null) sb.append(getDisabledIcon()); sb.append(",disabledSelectedIcon="); if (getDisa...
8,646