rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k |
|---|---|---|
Dimension ss = ((JNodeToolkit) Toolkit.getDefaultToolkit()).changeScreenSize(resolution); | ((JNodeToolkit) Toolkit.getDefaultToolkit()).changeScreenSize(resolution); | public void run() { final ClassLoader cl = getClass().getClassLoader(); final ExtensionPoint appsEP; if (cl instanceof PluginClassLoader) { appsEP = ((PluginClassLoader) cl).getDeclaringPluginDescriptor().getExtensionPoint("apps"); ... |
ctx.adjustDesktopSize(ss.width, ss.height); System.out.println("screenres1: " + ss); System.out.println("screenres2: " + Toolkit.getDefaultToolkit().getScreenSize()); | public void run() { final ClassLoader cl = getClass().getClassLoader(); final ExtensionPoint appsEP; if (cl instanceof PluginClassLoader) { appsEP = ((PluginClassLoader) cl).getDeclaringPluginDescriptor().getExtensionPoint("apps"); ... | |
Dimension ss = ((JNodeToolkit) Toolkit.getDefaultToolkit()).changeScreenSize(resolution); | ((JNodeToolkit) Toolkit.getDefaultToolkit()).changeScreenSize(resolution); | public void run() { Dimension ss = ((JNodeToolkit) Toolkit.getDefaultToolkit()).changeScreenSize(resolution); AccessController.doPrivileged(new SetPropertyAction("jnode.awt.screensize", resolution)); ctx.adjustDesktopSize(ss.width,... |
ctx.adjustDesktopSize(ss.width, ss.height); System.out.println("screenres1: " + ss); System.out.println("screenres2: " + Toolkit.getDefaultToolkit().getScreenSize()); | public void run() { Dimension ss = ((JNodeToolkit) Toolkit.getDefaultToolkit()).changeScreenSize(resolution); AccessController.doPrivileged(new SetPropertyAction("jnode.awt.screensize", resolution)); ctx.adjustDesktopSize(ss.width,... | |
public BufferCapabilities(ImageCapabilities front, ImageCapabilities back, | public BufferCapabilities(ImageCapabilities frontCaps, ImageCapabilities backCaps, | public BufferCapabilities(ImageCapabilities front, ImageCapabilities back, FlipContents flip) { if (front == null || back == null) throw new IllegalArgumentException(); this.front = front; this.back = back; this.flip = flip; } |
if (front == null || back == null) | if (frontCaps == null || backCaps == null) | public BufferCapabilities(ImageCapabilities front, ImageCapabilities back, FlipContents flip) { if (front == null || back == null) throw new IllegalArgumentException(); this.front = front; this.back = back; this.flip = flip; } |
this.front = front; this.back = back; | this.front = frontCaps; this.back = backCaps; | public BufferCapabilities(ImageCapabilities front, ImageCapabilities back, FlipContents flip) { if (front == null || back == null) throw new IllegalArgumentException(); this.front = front; this.back = back; this.flip = flip; } |
if (peer != null && ! e.consumed) peer.handleEvent(e); | public final void dispatchEvent(AWTEvent e) { // Some subclasses in the AWT package need to override this behavior, // hence the use of dispatchEventImpl(). dispatchEventImpl(e); if (peer != null && ! e.consumed) peer.handleEvent(e); } | |
processEvent (e); | if (e.id != PaintEvent.PAINT && e.id != PaintEvent.UPDATE) processEvent(e); | void dispatchEventImpl (AWTEvent e) { Event oldEvent = translateEvent (e); if (oldEvent != null) postEvent (oldEvent); if (eventTypeEnabled (e.id)) { // the trick we use to communicate between dispatch and redispatch // is to have KeyboardFocusManager.redispatch synchronize on the ... |
if (peer != null) peer.handleEvent(e); | void dispatchEventImpl (AWTEvent e) { Event oldEvent = translateEvent (e); if (oldEvent != null) postEvent (oldEvent); if (eventTypeEnabled (e.id)) { // the trick we use to communicate between dispatch and redispatch // is to have KeyboardFocusManager.redispatch synchronize on the ... | |
if (parent != null) return parent.isDisplayable(); return false; | return peer != null; | public boolean isDisplayable() { if (parent != null) return parent.isDisplayable(); return false; } |
if (!isLightweight() && peer != null) peer.paint(g); | public void paint(Graphics g) { // Paint the heavyweight peer if (!isLightweight() && peer != null) peer.paint(g); } | |
param.append(",parent==null"); | param.append(",parent=null"); | protected String paramString() { StringBuffer param = new StringBuffer(); String name = getName(); if (name != null) param.append(name).append(","); param.append(x).append(",").append(y).append(",").append(width) .append("x").append(height); if (! isValid()) param.append(",invalid"); if (! isVis... |
param.append(",parent==").append(parent.getName()); | param.append(",parent=").append(parent.getName()); | protected String paramString() { StringBuffer param = new StringBuffer(); String name = getName(); if (name != null) param.append(name).append(","); param.append(x).append(",").append(y).append(",").append(width) .append("x").append(height); if (! isValid()) param.append(",invalid"); if (! isVis... |
if(!isShowing()) { Component p = parent; if (p != null) p.repaint(0, getX(), getY(), width, height); } else | public void repaint() { repaint(0, 0, 0, width, height); } | |
boolean shouldRepaintParent = false; boolean shouldRepaintSelf = false; | public void reshape(int x, int y, int width, int height) { int oldx = this.x; int oldy = this.y; int oldwidth = this.width; int oldheight = this.height; if (this.x == x && this.y == y && this.width == width && this.height == height) return; invalidate (); this.x = x; this.y = y; ... | |
shouldRepaintParent = parentBounds.intersects(oldBounds); shouldRepaintSelf = parentBounds.intersects(newBounds); | Rectangle destroyed = oldBounds.union(newBounds); if (!destroyed.isEmpty()) parent.repaint(0, destroyed.x, destroyed.y, destroyed.width, destroyed.height); | public void reshape(int x, int y, int width, int height) { int oldx = this.x; int oldy = this.y; int oldwidth = this.width; int oldheight = this.height; if (this.x == x && this.y == y && this.width == width && this.height == height) return; invalidate (); this.x = x; this.y = y; ... |
if (shouldRepaintParent && parent != null) parent.repaint(oldx, oldy, oldwidth, oldheight); if (shouldRepaintSelf) repaint(); | public void reshape(int x, int y, int width, int height) { int oldx = this.x; int oldy = this.y; int oldwidth = this.width; int oldheight = this.height; if (this.x == x && this.y == y && this.width == width && this.height == height) return; invalidate (); this.x = x; this.y = y; ... | |
UIDefaults defaults = UIManager.getLookAndFeelDefaults(); tabPane.setFont(defaults.getFont("TabbedPane.font")); tabPane.setForeground(defaults.getColor("TabbedPane.foreground")); tabPane.setBackground(defaults.getColor("TabbedPane.background")); | LookAndFeel.installColorsAndFont(tabPane, "TabbedPane.background", "TabbedPane.foreground", "TabbedPane.font"); | protected void installDefaults() { UIDefaults defaults = UIManager.getLookAndFeelDefaults(); tabPane.setFont(defaults.getFont("TabbedPane.font")); tabPane.setForeground(defaults.getColor("TabbedPane.foreground")); tabPane.setBackground(defaults.getColor("TabbedPane.background")); tabPane.setOpaque(fal... |
highlight = defaults.getColor("TabbedPane.highlight"); lightHighlight = defaults.getColor("TabbedPane.lightHighlight"); | highlight = UIManager.getColor("TabbedPane.highlight"); lightHighlight = UIManager.getColor("TabbedPane.lightHighlight"); | protected void installDefaults() { UIDefaults defaults = UIManager.getLookAndFeelDefaults(); tabPane.setFont(defaults.getFont("TabbedPane.font")); tabPane.setForeground(defaults.getColor("TabbedPane.foreground")); tabPane.setBackground(defaults.getColor("TabbedPane.background")); tabPane.setOpaque(fal... |
shadow = defaults.getColor("TabbedPane.shadow"); darkShadow = defaults.getColor("TabbedPane.darkShadow"); | shadow = UIManager.getColor("TabbedPane.shadow"); darkShadow = UIManager.getColor("TabbedPane.darkShadow"); | protected void installDefaults() { UIDefaults defaults = UIManager.getLookAndFeelDefaults(); tabPane.setFont(defaults.getFont("TabbedPane.font")); tabPane.setForeground(defaults.getColor("TabbedPane.foreground")); tabPane.setBackground(defaults.getColor("TabbedPane.background")); tabPane.setOpaque(fal... |
focus = defaults.getColor("TabbedPane.focus"); | focus = UIManager.getColor("TabbedPane.focus"); | protected void installDefaults() { UIDefaults defaults = UIManager.getLookAndFeelDefaults(); tabPane.setFont(defaults.getFont("TabbedPane.font")); tabPane.setForeground(defaults.getColor("TabbedPane.foreground")); tabPane.setBackground(defaults.getColor("TabbedPane.background")); tabPane.setOpaque(fal... |
textIconGap = defaults.getInt("TabbedPane.textIconGap"); tabRunOverlay = defaults.getInt("TabbedPane.tabRunOverlay"); | textIconGap = UIManager.getInt("TabbedPane.textIconGap"); tabRunOverlay = UIManager.getInt("TabbedPane.tabRunOverlay"); | protected void installDefaults() { UIDefaults defaults = UIManager.getLookAndFeelDefaults(); tabPane.setFont(defaults.getFont("TabbedPane.font")); tabPane.setForeground(defaults.getColor("TabbedPane.foreground")); tabPane.setBackground(defaults.getColor("TabbedPane.background")); tabPane.setOpaque(fal... |
tabInsets = defaults.getInsets("TabbedPane.tabbedPaneTabInsets"); selectedTabPadInsets = defaults.getInsets("TabbedPane.tabbedPaneTabPadInsets"); tabAreaInsets = defaults.getInsets("TabbedPane.tabbedPaneTabAreaInsets"); contentBorderInsets = defaults.getInsets("TabbedPane.tabbedPaneContentBorderInsets"); | tabInsets = UIManager.getInsets("TabbedPane.tabbedPaneTabInsets"); selectedTabPadInsets = UIManager.getInsets("TabbedPane.tabbedPaneTabPadInsets"); tabAreaInsets = UIManager.getInsets("TabbedPane.tabbedPaneTabAreaInsets"); contentBorderInsets = UIManager.getInsets("TabbedPane.tabbedPaneContentBorderInsets"); | protected void installDefaults() { UIDefaults defaults = UIManager.getLookAndFeelDefaults(); tabPane.setFont(defaults.getFont("TabbedPane.font")); tabPane.setForeground(defaults.getColor("TabbedPane.foreground")); tabPane.setBackground(defaults.getColor("TabbedPane.background")); tabPane.setOpaque(fal... |
SwingConstants.CENTER, tabRect, | SwingConstants.RIGHT, tabRect, | protected void layoutLabel(int tabPlacement, FontMetrics metrics, int tabIndex, String title, Icon icon, Rectangle tabRect, Rectangle iconRect, Rectangle textRect, boolean isSelected) { SwingUtilities.layoutCompoundLabel(metrics, ... |
public GlyphJustificationInfo getJustificationInfo () throws NotImplementedException | public GlyphJustificationInfo getJustificationInfo() | public GlyphJustificationInfo getJustificationInfo () throws NotImplementedException { throw new Error ("not implemented"); } |
throw new Error ("not implemented"); | float adv = getAdvance(); return new GlyphJustificationInfo(adv, false, 2, adv / 3, adv / 3, false, 1, 0, 0); | public GlyphJustificationInfo getJustificationInfo () throws NotImplementedException { throw new Error ("not implemented"); } |
Inet4Address(byte[] addr) | Inet4Address(byte[] addr, String host) | Inet4Address(byte[] addr) { this(addr, null, null); } |
this(addr, null, null); | super(addr, host); | Inet4Address(byte[] addr) { this(addr, null, null); } |
StringBuffer sbuf = new StringBuffer(40); int len = addr.length; int i = 0; for (;;) { sbuf.append(addr[i] & 0xFF); i++; if (i == len) break; sbuf.append('.'); } return sbuf.toString(); | return super.getHostAddress(); | public String getHostAddress() { StringBuffer sbuf = new StringBuffer(40); int len = addr.length; int i = 0; for (;;) { sbuf.append(addr[i] & 0xFF); i++; if (i == len) break; sbuf.append('.'); } return sbuf.toString(); } |
byte[] anylocal = { 0, 0, 0, 0 }; return Arrays.equals(addr, anylocal); | return super.isAnyLocalAddress(); | public boolean isAnyLocalAddress() { byte[] anylocal = { 0, 0, 0, 0 }; return Arrays.equals(addr, anylocal); } |
return false; | return super.isLinkLocalAddress(); | public boolean isLinkLocalAddress() { // XXX: This seems to not exist with IPv4 addresses return false; } |
return addr[0] == 0x7F; | return super.isLoopbackAddress(); | public boolean isLoopbackAddress() { return addr[0] == 0x7F; } |
return false; | return super.isMCGlobal(); | public boolean isMCGlobal() { // XXX: This seems to net exist with IPv4 addresses return false; } |
if (! isMulticastAddress()) return false; return (addr[0] == 0xE0) && (addr[1] == 0x00) && (addr[2] == 0x00); | return super.isMCLinkLocal(); | public boolean isMCLinkLocal() { if (! isMulticastAddress()) return false; return (addr[0] == 0xE0) && (addr[1] == 0x00) && (addr[2] == 0x00); } |
return false; | return isMCNodeLocal(); | public boolean isMCNodeLocal() { // XXX: This seems to net exist with IPv4 addresses return false; } |
return false; | return isMCOrgLocal(); | public boolean isMCOrgLocal() { // XXX: This seems to net exist with IPv4 addresses return false; } |
return false; | return super.isMCSiteLocal(); | public boolean isMCSiteLocal() { // XXX: This seems to net exist with IPv4 addresses return false; } |
return (addr[0] & 0xF0) == 0xE0; | return super.isMulticastAddress(); | public boolean isMulticastAddress() { return (addr[0] & 0xF0) == 0xE0; } |
if (addr[0] == 0x0A) return true; if (addr[0] == 0xAC && (addr[1] & 0xF0) == 0x01) return true; if (addr[0] == 0xC0 && addr[1] == 0xA8) return true; return false; | return super.isSiteLocalAddress(); | public boolean isSiteLocalAddress() { // 10.0.0.0/8 if (addr[0] == 0x0A) return true; // XXX: Suns JDK 1.4.1 (on Linux) seems to have a bug here: // it says 172.16.0.0 - 172.255.255.255 are site local addresses // // 172.16.0.0/12 if (addr[0] == 0xAC && (addr[1] & 0xF0) == 0x01) return true; // 192.168.0... |
return new InetAddress(addr, hostName, null); } | return new InetAddress(addr, hostName); } | private Object writeReplace() throws ObjectStreamException { return new InetAddress(addr, hostName, null); } |
return ("[" + getClass ().getName () | return (getClass ().getName () + "[" | public String toString () { return ("[" + getClass ().getName () + ",hgap=" + hgap + ",vgap=" + vgap + ",rows=" + rows + ",cols=" + cols + "]"); } |
int lo_row = getRowForPoint(begin); int hi_row = getRowForPoint(curr); | int lo_row = table.rowAtPoint(begin); int hi_row = table.rowAtPoint(curr); | private void updateSelection() { if (table.getRowSelectionAllowed()) { int lo_row = getRowForPoint(begin); int hi_row = getRowForPoint(curr); ListSelectionModel rowModel = table.getSelectionModel(); if (lo_row != -1 && hi_row != -1) rowModel.setSelectio... |
int lo_col = getColForPoint(begin); int hi_col = getColForPoint(curr); | int lo_col = table.columnAtPoint(begin); int hi_col = table.columnAtPoint(curr); | private void updateSelection() { if (table.getRowSelectionAllowed()) { int lo_row = getRowForPoint(begin); int hi_row = getRowForPoint(curr); ListSelectionModel rowModel = table.getSelectionModel(); if (lo_row != -1 && hi_row != -1) rowModel.setSelectio... |
Scrollbar() { | public Scrollbar() { | Scrollbar(){ this(VERTICAL);} |
addAdjustmentListener(AdjustmentListener listener) { adjustment_listeners = AWTEventMulticaster.add(adjustment_listeners, listener); | public synchronized void addAdjustmentListener(AdjustmentListener listener) { adjustment_listeners = AWTEventMulticaster.add(adjustment_listeners, listener); | addAdjustmentListener(AdjustmentListener listener){ adjustment_listeners = AWTEventMulticaster.add(adjustment_listeners, listener); enableEvents(AWTEvent.ADJUSTMENT_EVENT_MASK);} |
addNotify() { | public synchronized void addNotify() { | addNotify(){ if (peer == null) peer = getToolkit ().createScrollbar (this); super.addNotify ();} |
dispatchEventImpl(AWTEvent e) { | void dispatchEventImpl(AWTEvent e) { | dispatchEventImpl(AWTEvent e){ if (e.id <= AdjustmentEvent.ADJUSTMENT_LAST && e.id >= AdjustmentEvent.ADJUSTMENT_FIRST && (adjustment_listeners != null || (eventMask & AWTEvent.ADJUSTMENT_EVENT_MASK) != 0)) processEvent(e); else super.dispatchEventImpl(e);} |
getBlockIncrement() { return getPageIncrement (); } | public int getBlockIncrement() { return getPageIncrement(); } | getBlockIncrement(){ return getPageIncrement ();} |
getLineIncrement() { | public int getLineIncrement() { | getLineIncrement(){ return lineIncrement;} |
getMaximum() { return(maximum); } | public int getMaximum() { return maximum; } | getMaximum(){ return(maximum);} |
getMinimum() { return(minimum); } | public int getMinimum() { return minimum; } | getMinimum(){ return(minimum);} |
getOrientation() { return(orientation); } | public int getOrientation() { return orientation; } | getOrientation(){ return(orientation);} |
getPageIncrement() { | public int getPageIncrement() { | getPageIncrement(){ return pageIncrement;} |
getUnitIncrement() { return getLineIncrement (); } | public int getUnitIncrement() { return getLineIncrement(); } | getUnitIncrement(){ return getLineIncrement ();} |
getValue() { return(value); } | public int getValue() { return value; } | getValue(){ return(value);} |
getVisible() { | public int getVisible() { | getVisible(){ return visibleAmount;} |
getVisibleAmount() { return getVisible (); } | public int getVisibleAmount() { return getVisible(); } | getVisibleAmount(){ return getVisible ();} |
paramString() { return("value=" + getValue() + ",visibleAmount=" + getVisibleAmount() + ",minimum=" + getMinimum() + ",maximum=" + getMaximum() + ",pageIncrement=" + pageIncrement + ",lineIncrement=" + lineIncrement + ",orientation=" + (orientation == HORIZONTAL ? "HORIZONTAL" : "VERTICAL") | protected String paramString() { return ("value=" + getValue() + ",visibleAmount=" + getVisibleAmount() + ",minimum=" + getMinimum() + ",maximum=" + getMaximum() + ",pageIncrement=" + pageIncrement + ",lineIncrement=" + lineIncrement + ",orientation=" + (orientation == HORIZONTAL ? "HORIZONTAL" : "VERTICAL") | paramString(){ return("value=" + getValue() + ",visibleAmount=" + getVisibleAmount() + ",minimum=" + getMinimum() + ",maximum=" + getMaximum() + ",pageIncrement=" + pageIncrement + ",lineIncrement=" + lineIncrement + ",orientation=" + (orientation == HORIZONTAL ? "HORIZONTAL" : "VERTICAL") + sup... |
processAdjustmentEvent(AdjustmentEvent event) { | protected void processAdjustmentEvent(AdjustmentEvent event) { | processAdjustmentEvent(AdjustmentEvent event){ value = event.getValue(); if (adjustment_listeners != null) adjustment_listeners.adjustmentValueChanged(event);} |
processEvent(AWTEvent event) { | protected void processEvent(AWTEvent event) { | processEvent(AWTEvent event){ if (event instanceof AdjustmentEvent) processAdjustmentEvent((AdjustmentEvent)event); else super.processEvent(event);} |
removeAdjustmentListener(AdjustmentListener listener) { | public synchronized void removeAdjustmentListener(AdjustmentListener listener) { | removeAdjustmentListener(AdjustmentListener listener){ adjustment_listeners = AWTEventMulticaster.remove(adjustment_listeners, listener);} |
setBlockIncrement(int blockIncrement) { setPageIncrement (blockIncrement); } | public synchronized void setBlockIncrement(int blockIncrement) { setPageIncrement(blockIncrement); } | setBlockIncrement(int blockIncrement){ setPageIncrement (blockIncrement);} |
setLineIncrement(int lineIncrement) { | public void setLineIncrement(int lineIncrement) { | setLineIncrement(int lineIncrement){ if (lineIncrement < 0) throw new IllegalArgumentException ("Unit increment less than zero."); int range = maximum - minimum; if (lineIncrement > range) { if (range == 0) lineIncrement = 1; else lineIncrement = range; } if (lineIncrement == this.line... |
setMaximum(int maximum) { | public void setMaximum(int maximum) { | setMaximum(int maximum){ setValues(value, visibleAmount, minimum, maximum);} |
setMinimum(int minimum) { | public void setMinimum(int minimum) { | setMinimum(int minimum){ setValues(value, visibleAmount, minimum, maximum);} |
setOrientation(int orientation) { | public void setOrientation(int orientation) { | setOrientation(int orientation){ if ((orientation != HORIZONTAL) && (orientation != VERTICAL)) throw new IllegalArgumentException("Bad orientation value: " + orientation); // FIXME: Communicate to peer? Or must this be called before peer creation? this.orientation = orientation;} |
setPageIncrement(int pageIncrement) { | public void setPageIncrement(int pageIncrement) { | setPageIncrement(int pageIncrement){ if (pageIncrement < 0) throw new IllegalArgumentException ("Block increment less than zero."); int range = maximum - minimum; if (pageIncrement > range) { if (range == 0) pageIncrement = 1; else pageIncrement = range; } if (pageIncrement == this.pag... |
setUnitIncrement(int unitIncrement) { setLineIncrement (unitIncrement); } | public synchronized void setUnitIncrement(int unitIncrement) { setLineIncrement(unitIncrement); } | setUnitIncrement(int unitIncrement){ setLineIncrement (unitIncrement);} |
setValue(int value) { | public void setValue(int value) { | setValue(int value){ setValues(value, visibleAmount, minimum, maximum);} |
setValues(int value, int visibleAmount, int minimum, int maximum) { | public synchronized void setValues(int value, int visibleAmount, int minimum, int maximum) { | setValues(int value, int visibleAmount, int minimum, int maximum){ if (maximum < minimum) maximum = minimum; if (value < minimum) value = minimum; if (value > maximum) value = maximum; if (visibleAmount > maximum - minimum) visibleAmount = maximum - minimum; ScrollbarPeer peer = (ScrollbarPeer) getPeer ()... |
setVisibleAmount(int visibleAmount) { | public void setVisibleAmount(int visibleAmount) { | setVisibleAmount(int visibleAmount){ setValues(value, visibleAmount, minimum, maximum);} |
if (delegate != null) | public void _releaseReply(InputStream stream) { delegate.releaseReply(this, stream); } | |
if (delegate == null) return this == other; else | public boolean equals(java.lang.Object other) { return delegate.equals(this, other); } | |
public long getLastModified() { | public long getLastModified() throws IOException { | public long getLastModified() { return 0; } |
if (isEditing()) | public void cancelEditing() { TreeUI ui = getUI(); if (ui != null) ui.cancelEditing(this); } | |
public String paramString() | protected String paramString() | public String paramString() { // TODO: this is completely legal, but it would possibly be nice // to return some more content, like the tree structure, some properties // etc ... return ""; } |
if (isEditing()) | public boolean stopEditing() { TreeUI ui = getUI(); if (ui != null) return ui.stopEditing(this); return false; } | |
isFreeStanding = (prop == null ? true : prop.booleanValue()); | isFreeStanding = prop == null ? true : prop.booleanValue(); | public void propertyChange(PropertyChangeEvent e) { if (e.getPropertyName().equals(FREE_STANDING_PROP)) { Boolean prop = (Boolean) e.getNewValue(); isFreeStanding = (prop == null ? true : prop.booleanValue()); if (increaseButton != null) increaseButton.setFreeStanding(isF... |
isFreeStanding = (prop == null ? true : prop.booleanValue()); | isFreeStanding = prop == null ? true : prop.booleanValue(); | protected void installDefaults() { // need to initialise isFreeStanding before calling the super class, // so that the value is set when createIncreaseButton() and // createDecreaseButton() are called (unless there is somewhere earlier // that we can do this). Boolean prop = (Boolean) scrollbar.... |
PlainDocument doc = new PlainDocument(); doc.putProperty("filterNewlines", Boolean.TRUE); return doc; | return new PlainDocument(); | protected Document createDefaultModel() { PlainDocument doc = new PlainDocument(); doc.putProperty("filterNewlines", Boolean.TRUE); return doc; } |
consumer.setPixels(bounds.x, bounds.y, | consumer.setPixels(0, 0, | public void setPixels(int x, int y, int w, int h, ColorModel model, byte[] pixels, int offset, int scansize) { Rectangle filterBounds = new Rectangle(this.x, this.y, this.width, this.height); Rectangle pixelBounds = new Rectangle(x, y, w, h); if (filterBounds.intersects... |
setExpandedIcon(defaults.getIcon("Tree.expandedIcon")); setCollapsedIcon(defaults.getIcon("Tree.collapsedIcon")); | setExpandedIcon(defaults.getIcon("Tree.openIcon")); setCollapsedIcon(defaults.getIcon("Tree.closedIcon")); | public void installUI(JComponent c) { tree = (JTree) c; configureLayoutCache(); UIDefaults defaults = UIManager.getLookAndFeelDefaults(); tree.setFont(defaults.getFont("Tree.font")); tree.setForeground(defaults.getColor("Tree.foreground")); tree.setBackground(defaults.getColor("Tree.background"... |
tree.expandPath(new TreePath(mod.getRoot())); | { TreePath path = new TreePath(mod.getRoot()); if (!tree.isExpanded(path)) toggleExpandState(path); } | public void installUI(JComponent c) { tree = (JTree) c; configureLayoutCache(); UIDefaults defaults = UIManager.getLookAndFeelDefaults(); tree.setFont(defaults.getFont("Tree.font")); tree.setForeground(defaults.getColor("Tree.foreground")); tree.setBackground(defaults.getColor("Tree.background"... |
public Dialog(Frame parent) { | Dialog(Frame parent) { | public Dialog(Frame parent) { this(parent, "", false); } |
public synchronized void addNotify() { | addNotify() { | public synchronized void addNotify() { if (peer == null) peer = getToolkit().createDialog(this); super.addNotify(); } |
public boolean isModal() { return (modal); } | isModal() { return(modal); } | public boolean isModal() { return (modal); } |
protected String paramString() { return ("title+" + title + ",modal=" + modal + ",resizable=" + resizable + "," + super.paramString()); } | paramString() { return ("title+" + title + ",modal=" + modal + ",resizable=" + resizable + "," + super.paramString()); } | protected String paramString() { return ("title+" + title + ",modal=" + modal + ",resizable=" + resizable + "," + super.paramString()); } |
public void setModal(boolean modal) { | setModal(boolean modal) { | public void setModal(boolean modal) { this.modal = modal; } |
public synchronized void setResizable(boolean resizable) { | setResizable(boolean resizable) { | public synchronized void setResizable(boolean resizable) { this.resizable = resizable; if (peer != null) { DialogPeer d = (DialogPeer) peer; d.setResizable(resizable); } } |
d.setResizable(resizable); } | d.setResizable (resizable); | public synchronized void setResizable(boolean resizable) { this.resizable = resizable; if (peer != null) { DialogPeer d = (DialogPeer) peer; d.setResizable(resizable); } } |
} | public synchronized void setResizable(boolean resizable) { this.resizable = resizable; if (peer != null) { DialogPeer d = (DialogPeer) peer; d.setResizable(resizable); } } | |
public synchronized void setTitle(String title) { this.title = title; if (peer != null) { | setTitle(String title) { this.title = (title != null) ? title : ""; if (peer != null) { | public synchronized void setTitle(String title) { this.title = title; if (peer != null) { DialogPeer d = (DialogPeer) peer; d.setTitle(title); } } |
d.setTitle(title); } | d.setTitle (title); | public synchronized void setTitle(String title) { this.title = title; if (peer != null) { DialogPeer d = (DialogPeer) peer; d.setTitle(title); } } |
} | public synchronized void setTitle(String title) { this.title = title; if (peer != null) { DialogPeer d = (DialogPeer) peer; d.setTitle(title); } } | |
public void show() { | show() { | public void show() { super.show(); } |
try { blocked = true; wait (); blocked = false; } catch (InterruptedException e) { blocked = false; } if (eq2 != null) { eq2.pop (); eq2 = null; } } } | public void show() { super.show(); } | |
if (offset > 0) { try { String s = getText(offset - 1, 1); if (s.equals("\n")) { int newEl2EndOffset = end; boolean replaceNext = false; if (rootElement.getElementCount() > elementIndex + 1) { replaceNext = true; newEl2EndOffset = rootElement.getElement(elementIndex + 1).getEndOffset(); } Element newEl1 = createLeafEle... | protected void insertUpdate(DefaultDocumentEvent event, AttributeSet attributes) { int offset = event.getOffset(); int end = offset + event.getLength(); int elementIndex = rootElement.getElementIndex(offset); Element firstElement = rootElement.getElement(elementIndex); ... | |
return new GLightweightPeer(target); | if (lightweightPeer == null) lightweightPeer = new GLightweightPeer(); return lightweightPeer; | protected LightweightPeer createComponent(Component target) { return new GLightweightPeer(target); } |
}.run(); | }.start(); | public synchronized void send_deferred() { waitWhileBusy(); new Thread() { public void run() { invoke(); } }.run(); } |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.