rem stringlengths 0 477k | add stringlengths 0 313k | context stringlengths 6 599k |
|---|---|---|
byte[] blockData = fs.getBlock( fs.getSuperblock().getFirstDataBlock() + 1); byte[] data = new byte[GROUPDESCRIPTOR_LENGTH]; System.arraycopy(blockData, 0, data, 0, GROUPDESCRIPTOR_LENGTH); | long baseBlock = fs.getSuperblock().getFirstDataBlock()+1; long blockOffset=(groupNr*GROUPDESCRIPTOR_LENGTH)/fs.getBlockSize(); long offset =(groupNr*GROUPDESCRIPTOR_LENGTH)%fs.getBlockSize(); byte[] blockData= fs.getBlock(baseBlock + blockOffset); data = new byte[GROUPDESCRIPTOR_LENGTH]; System.arraycopy(blockData,... | public GroupDescriptor(int groupNr, Ext2FileSystem fs) throws IOException{ //read the group descriptors from the main copy in block group 0 byte[] blockData = fs.getBlock( fs.getSuperblock().getFirstDataBlock() + 1); byte[] data = new byte[GROUPDESCRIPTOR_LENGTH]; System.arraycopy(blockData, 0, data, 0, GROUPDESCR... |
cdrBufInput in = new cdrBufInput(out.buffer.toByteArray()); in.setOrb(orb); return in; | cdrBufInput in = new cdrBufInput(out.buffer.toByteArray()); in.setOrb(orb); return in; } | public org.omg.CORBA.portable.InputStream create_input_stream() { if (has instanceof universalHolder) { universalHolder u = (universalHolder) has; return u.getInputStream(); } else { cdrBufOutput out = new cdrBufOutput(); out.setOrb(orb); write_value(out); cdrBufInput i... |
} | public org.omg.CORBA.portable.InputStream create_input_stream() { if (has instanceof universalHolder) { universalHolder u = (universalHolder) has; return u.getInputStream(); } else { cdrBufOutput out = new cdrBufOutput(); out.setOrb(orb); write_value(out); cdrBufInput i... | |
{ type(typecode); insert_Value(x); | { type(typecode); insert_Value(x); } | public void insert_Value(Serializable x, TypeCode c_typecode) { if (typecode != null && typecode.kind() == TCKind.tk_value_box) { has = new gnuValueHolder(x, typecode); } else { type(typecode); insert_Value(x); } } |
} | public void insert_Value(Serializable x, TypeCode c_typecode) { if (typecode != null && typecode.kind() == TCKind.tk_value_box) { has = new gnuValueHolder(x, typecode); } else { type(typecode); insert_Value(x); } } | |
public ConnectException(String message) | public ConnectException() | public ConnectException(String message) { super(message); } |
super(message); | public ConnectException(String message) { super(message); } | |
pages.setText(splfile.getIntegerAttribute(splfile.ATTR_PAGES).toString()); | pages.setText(splfile.getIntegerAttribute(SpooledFile.ATTR_PAGES).toString()); | private JPanel pageOne () throws Exception { contentPane = new JPanel(); contentPane.setLayout(new BorderLayout()); statusBar.setText(" "); statusBar.setBorder(BorderFactory.createEtchedBorder()); spoolPanel.setLayout(new BorderLayout()); contentPane.add(spoolPanel, BorderLayout.CENTER)... |
background = UIManager.getColor(prefix + ".background"); | protected void installDefaults() { Caret caret = textComponent.getCaret(); if (caret == null) { caret = createCaret(); textComponent.setCaret(caret); } Highlighter highlighter = textComponent.getHighlighter(); if (highlighter == null) textComponent.setHighlighter(createHighli... | |
return null; | return new DefaultKeySelectionManager(); | protected KeySelectionManager createDefaultKeySelectionManager() { return null; } |
return null; | return keySelectionManager; | public KeySelectionManager getKeySelectionManager() { return null; } |
else if (keySelectionManager != null) { int i = keySelectionManager.selectionForKey(e.getKeyChar(), getModel()); if (i >= 0) setSelectedIndex(i); else super.processKeyEvent(e); } | public void processKeyEvent(KeyEvent e) { if (e.getKeyCode() == KeyEvent.VK_TAB) setPopupVisible(false); else if (keySelectionManager != null) { int i = keySelectionManager.selectionForKey(e.getKeyChar(), getModel()); if (i >= 0) ... | |
fireActionEvent(); | public void setSelectedItem(Object item) { dataModel.setSelectedItem(item); } | |
bad.minor = Minor.Any; | public static BindingType extract(Any any) { try { return ((BindingTypeHolder) any.extract_Streamable()).value; } catch (ClassCastException ex) { BAD_OPERATION bad = new BAD_OPERATION("Binding type expected"); bad.initCause(ex); throw bad; } } | |
keyHandler.sessionClosed((Session)this); keyHandler = null; | public void closeDown() { sesConfig.saveSessionProps(getParent()); // Let's stop the cursor blinking as well as it seems to be causing problems if (screen.isBlinkCursor()) { screen.setBlinkCursorStop(); } vt.disconnect(); } | |
if (width < 0 || miterlimit < 1.0f || cap < CAP_BUTT || cap > CAP_SQUARE || join < JOIN_MITER || join > JOIN_BEVEL) throw new IllegalArgumentException(); | if (width < 0.0f ) throw new IllegalArgumentException("width " + width + " < 0"); else if (cap < CAP_BUTT || cap > CAP_SQUARE) throw new IllegalArgumentException("cap " + cap + " out of range [" + CAP_BUTT + ".." + CAP_SQUARE + "]"); else if (miterlimit < 1.0f && join == JOIN_MITER) throw new IllegalArgumentException("... | public BasicStroke(float width, int cap, int join, float miterlimit, float[] dash, float dashPhase) { if (width < 0 || miterlimit < 1.0f || cap < CAP_BUTT || cap > CAP_SQUARE || join < JOIN_MITER || join > JOIN_BEVEL) throw new IllegalArgumentException()... |
return Toolkit.getDefaultToolkit () | DragGestureRecognizer dgr; dgr = Toolkit.getDefaultToolkit () | createDragGestureRecognizer(Class recognizer, Component c, int actions, DragGestureListener dgl) { return Toolkit.getDefaultToolkit () .createDragGestureRecognizer (recognizer, this, c, actions, dgl); } |
if (dgr == null) dgr = new NoDragGestureRecognizer(this, c, actions, dgl); return dgr; | createDragGestureRecognizer(Class recognizer, Component c, int actions, DragGestureListener dgl) { return Toolkit.getDefaultToolkit () .createDragGestureRecognizer (recognizer, this, c, actions, dgl); } | |
return null; | return new DragSource(); | public static DragSource getDefaultDragSource() { return null; } |
if (defaultFlavorMap == null) defaultFlavorMap = new SystemFlavorMap (); | ClassLoader classLoader = Thread.currentThread() .getContextClassLoader(); | public static FlavorMap getDefaultFlavorMap () { if (defaultFlavorMap == null) defaultFlavorMap = new SystemFlavorMap (); return defaultFlavorMap; } |
return defaultFlavorMap; | if (classLoader == null) { classLoader = ClassLoader.getSystemClassLoader(); } synchronized(systemFlavorMaps) { FlavorMap map = (FlavorMap) systemFlavorMaps.get(classLoader); if (map == null) { map = new SystemFlavorMap(); systemFlavorMaps.put(classLoader, map); } return map; } | public static FlavorMap getDefaultFlavorMap () { if (defaultFlavorMap == null) defaultFlavorMap = new SystemFlavorMap (); return defaultFlavorMap; } |
changeButtonOrientation(); positionButtons(); | Insets insets = getInsets(); if (orientation == JSplitPane.HORIZONTAL_SPLIT) { int size = getWidth() - insets.left - insets.right; size = Math.max(size, 0); size = Math.min(size, ONE_TOUCH_SIZE); int x, y; if (centerOneTouchButtons) { y = insets.top; x = (getWidth() - size) / 2; } else { x = insets.left; y = 0; } left... | public void layoutContainer(Container c) { if (splitPane.isOneTouchExpandable()) { changeButtonOrientation(); positionButtons(); } } |
if (splitPane.isOneTouchExpandable()) { if (e.getSource() == leftButton) { currentDividerLocation--; if (currentDividerLocation < 0) currentDividerLocation = 0; moveDividerTo(currentDividerLocation); return; } else if (e.getSource() == rightButton) { currentDividerLocation++; if (currentDividerLocation > 2) currentDivi... | public void mousePressed(MouseEvent e) { if (splitPane.isOneTouchExpandable()) { if (e.getSource() == leftButton) { currentDividerLocation--; if (currentDividerLocation < 0) currentDividerLocation = 0; moveDividerTo(currentDividerLocation); return; } else if (e.ge... | |
centerOneTouchButtons = UIManager.getBoolean("SplitPane.centerOneTouchButtons"); | public BasicSplitPaneDivider(BasicSplitPaneUI ui) { setLayout(new DividerLayout()); setBasicSplitPaneUI(ui); setDividerSize(splitPane.getDividerSize()); } | |
int dir = SwingConstants.WEST; if (orientation == JSplitPane.VERTICAL_SPLIT) dir = SwingConstants.NORTH; JButton button = new BasicArrowButton(dir); button.setBorder(null); | JButton button = new BasicOneTouchButton(BasicOneTouchButton.LEFT); button.setMinimumSize(new Dimension(ONE_TOUCH_SIZE, ONE_TOUCH_SIZE)); button.setRequestFocusEnabled(false); | protected JButton createLeftOneTouchButton() { int dir = SwingConstants.WEST; if (orientation == JSplitPane.VERTICAL_SPLIT) dir = SwingConstants.NORTH; JButton button = new BasicArrowButton(dir); button.setBorder(null); return button; } |
int dir = SwingConstants.EAST; if (orientation == JSplitPane.VERTICAL_SPLIT) dir = SwingConstants.SOUTH; JButton button = new BasicArrowButton(dir); button.setBorder(null); | JButton button = new BasicOneTouchButton(BasicOneTouchButton.RIGHT); button.setMinimumSize(new Dimension(ONE_TOUCH_SIZE, ONE_TOUCH_SIZE)); button.setRequestFocusEnabled(false); | protected JButton createRightOneTouchButton() { int dir = SwingConstants.EAST; if (orientation == JSplitPane.VERTICAL_SPLIT) dir = SwingConstants.SOUTH; JButton button = new BasicArrowButton(dir); button.setBorder(null); return button; } |
return getLayout().preferredLayoutSize(this); | Dimension d; if (orientation == JSplitPane.HORIZONTAL_SPLIT) d = new Dimension(getDividerSize(), 1); else d = new Dimension(1, getDividerSize()); return d; | public Dimension getPreferredSize() { return getLayout().preferredLayoutSize(this); } |
add(leftButton); add(rightButton); | if (rightButton != null) rightButton.addActionListener(new OneTouchAction()); | protected void oneTouchExpandableChanged() { if (splitPane.isOneTouchExpandable()) { leftButton = createLeftOneTouchButton(); rightButton = createRightOneTouchButton(); add(leftButton); add(rightButton); leftButton.addMouseListener(mouseHandler); rightButton.addMouseListener(mouseHandler); // Set it to 1. cu... |
leftButton.addMouseListener(mouseHandler); rightButton.addMouseListener(mouseHandler); currentDividerLocation = 1; } else { | protected void oneTouchExpandableChanged() { if (splitPane.isOneTouchExpandable()) { leftButton = createLeftOneTouchButton(); rightButton = createRightOneTouchButton(); add(leftButton); add(rightButton); leftButton.addMouseListener(mouseHandler); rightButton.addMouseListener(mouseHandler); // Set it to 1. cu... | |
leftButton.removeMouseListener(mouseHandler); rightButton.removeMouseListener(mouseHandler); remove(leftButton); remove(rightButton); leftButton = null; rightButton = null; | add(leftButton); add(rightButton); | protected void oneTouchExpandableChanged() { if (splitPane.isOneTouchExpandable()) { leftButton = createLeftOneTouchButton(); rightButton = createRightOneTouchButton(); add(leftButton); add(rightButton); leftButton.addMouseListener(mouseHandler); rightButton.addMouseListener(mouseHandler); // Set it to 1. cu... |
layout(); repaint(); | invalidate(); if (splitPane != null) splitPane.revalidate(); | protected void oneTouchExpandableChanged() { if (splitPane.isOneTouchExpandable()) { leftButton = createLeftOneTouchButton(); rightButton = createRightOneTouchButton(); add(leftButton); add(rightButton); leftButton.addMouseListener(mouseHandler); rightButton.addMouseListener(mouseHandler); // Set it to 1. cu... |
if (splitPane.isOneTouchExpandable()) { ((BasicArrowButton) rightButton).paint(g); ((BasicArrowButton) leftButton).paint(g); } | public void paint(Graphics g) { Dimension dividerSize; super.paint(g); if (border != null) { dividerSize = getSize(); border.paintBorder(this, g, 0, 0, dividerSize.width, dividerSize.height); } if (splitPane.isOneTouchExpandable()) { ((BasicArrowButton) rightButton).paint(g); ... | |
if (splitPane.isOneTouchExpandable()) { layout(); repaint(); } | invalidate(); if (splitPane != null) splitPane.revalidate(); | public void propertyChange(PropertyChangeEvent e) { if (e.getPropertyName().equals(JSplitPane.ONE_TOUCH_EXPANDABLE_PROPERTY)) oneTouchExpandableChanged(); else if (e.getPropertyName().equals(JSplitPane.ORIENTATION_PROPERTY)) { orientation = splitPane.getOrientation(); if (splitPane.isOneTouchExpandab... |
if (splitPane.isOneTouchExpandable()) | public void setBasicSplitPaneUI(BasicSplitPaneUI newUI) { /* Remove the connection to the existing JSplitPane. */ if (splitPane != null) { splitPane.removePropertyChangeListener(this); removeMouseListener(mouseHandler); removeMouseMotionListener(mouseHandler); splitPane = null; hiddenDivider = nul... | |
protected Tag(String id) | public Tag() | protected Tag(String id) { name = id; flags = 0; } |
name = id; | name = null; | protected Tag(String id) { name = id; flags = 0; } |
panel.setLayout(null); | panel.setLayout(new FlowLayout(0, 0, 0)); | public void show() { // We insert a JPanel between the layered pane and the contents so we // can fiddle with the setLocation() method without disturbing a // JPopupMenu (which overrides setLocation in an unusual manner). if (panel == null) { panel = new JPanel(); pan... |
if (c == '\t' || c == '\n') | if (c == '\t') | public static final int drawTabbedText(Segment s, int x, int y, Graphics g, TabExpander e, int startOffset) { // This buffers the chars to be drawn. char[] buffer = s.array; // The font metrics of the current selected font. FontMetrics metrics = g.getFontMetrics();... |
pixelX = (int) e.nextTabStop((float) pixelX, | pixelX = (int) e.nextTabStop(pixelX, | public static final int drawTabbedText(Segment s, int x, int y, Graphics g, TabExpander e, int startOffset) { // This buffers the chars to be drawn. char[] buffer = s.array; // The font metrics of the current selected font. FontMetrics metrics = g.getFontMetrics();... |
break; case '\n': pixelY += metrics.getHeight(); pixelX = x; | public static final int drawTabbedText(Segment s, int x, int y, Graphics g, TabExpander e, int startOffset) { // This buffers the chars to be drawn. char[] buffer = s.array; // The font metrics of the current selected font. FontMetrics metrics = g.getFontMetrics();... | |
int preceding = breaker.preceding(mark + 1 - shift); | int preceding = breaker.preceding(mark + 1 + s.offset); | public static final int getBreakLocation(Segment s, FontMetrics metrics, int x0, int x, TabExpander e, int startOffset) { int mark = Utilities.getTabbedTextOffset(s, metrics, x0, x, e, startOffset, false); BreakIterator breaker... |
null) | new Position.Bias[1]) | static int getNextVisualPositionFrom(JTextComponent t, int offset, int direction) { NavigationFilter nf = t.getNavigationFilter(); try { return (nf != null) ? nf.getNextVisualPositionFrom(t, offset, Bias.F... |
null); | new Position.Bias[1]); | static int getNextVisualPositionFrom(JTextComponent t, int offset, int direction) { NavigationFilter nf = t.getNavigationFilter(); try { return (nf != null) ? nf.getNextVisualPositionFrom(t, offset, Bias.F... |
return pos + p0; | return pos; | public static final int getTabbedTextOffset(Segment s, FontMetrics fm, int x0, int x, TabExpander te, int p0, boolean round) { // At the end of the for loop, this holds the requested model location int pos; int current... |
pixelX = (int) e.nextTabStop((float) pixelX, | pixelX = (int) e.nextTabStop(pixelX, | public static final int getTabbedTextWidth(Segment s, FontMetrics metrics, int x, TabExpander e, int startOffset) { // This buffers the chars to be drawn. char[] buffer = s.array; // The current x coordinate. int pixe... |
return Utilities.drawTabbedText(segment, x, y, g, this, 0); | return Utilities.drawTabbedText(segment, x, y, g, this, segment.offset); | protected int drawUnselectedText(Graphics g, int x, int y, int p0, int p1) throws BadLocationException { g.setColor(unselectedColor); Segment segment = new Segment(); getDocument().getText(p0, p1 - p0, segment); return Utilities.drawTabbedText(segment, x, y, g, this, 0); } |
System.out.println(" we are adjusting "); | log.info(" we are adjusting "); | public void setBoundsForFrame(JComponent f, int x, int y, int w, int h) { System.out.println(" we are adjusting "); if (f instanceof MyInternalFrame == false) { super.setBoundsForFrame(f, x, y, w, h); // only deal w/internal frames } else { MyInternalFrame fram... |
e.printStackTrace(); | log.warn("In constructor: "+e); | public Gui5250MDIFrame(My5250 m) { super(m); enableEvents(AWTEvent.WINDOW_EVENT_MASK); try { jbInit(); } catch(Exception e) { e.printStackTrace(); } } |
System.out.println("Can not set maximum " + pve.getMessage()); | log.warn("Can not set maximum " + pve.getMessage()); | public void addSessionView(String tabText,Session session) { MyInternalFrame frame = new MyInternalFrame(); frame.setVisible(true); desktop.add(frame); myFrameList.add(frame); selectedIndex = desktop.getComponentCount(); frame.setContentPane(session); try { frame.setSelecte... |
log.debug(" current index " + x + " count " + frames.length + " has focus " + mif.isActive() + " title " + mif.getTitle() + " seq " + seq + " id " + mif.getInternalId()); | private MyInternalFrame getNextInternalFrame() { JInternalFrame[] frames = (JInternalFrame[])desktop.getAllFrames(); JInternalFrame miv = desktop.getSelectedFrame(); if (miv == null) return null; int index = desktop.getIndexOf(miv); if (index == -1) return null; MyIntern... | |
System.out.println(e.getMessage()); | log.warn(e.getMessage()); | private void nextSession() { MyInternalFrame mif = getNextInternalFrame(); if (mif != null) { try { if (mif.isIcon()) { mif.setIcon(false); } mif.setSelected(true); } catch (java.beans.PropertyVetoException e) { System.out.pr... |
System.out.println(changeEvent.getState() + " " + d); | log.info(changeEvent.getState() + " " + d); | public void onSessionChanged(SessionChangeEvent changeEvent) { Session ses = (Session)changeEvent.getSource(); switch (changeEvent.getState()) { case STATE_CONNECTED: final String d = ses.getAllocDeviceName(); if (d != null) { System.out.println(changeEvent.getSt... |
log.debug(" index of session " + index + " num frames " + desktop.getAllFrames().length); | public void onSessionChanged(SessionChangeEvent changeEvent) { Session ses = (Session)changeEvent.getSource(); switch (changeEvent.getState()) { case STATE_CONNECTED: final String d = ses.getAllocDeviceName(); if (d != null) { System.out.println(changeEvent.getSt... | |
log.debug(" current index " + x + " count " + frames.length + " has focus " + mif.isActive() + " title " + mif.getTitle() + " seq " + seq + " id " + mif.getInternalId()); | private void prevSession() { JInternalFrame[] frames = (JInternalFrame[])desktop.getAllFrames(); JInternalFrame miv = desktop.getSelectedFrame(); if (miv == null) return; int index = desktop.getIndexOf(miv); if (index == -1) return; MyInternalFrame mix = (MyInternalFrame... | |
System.out.println(e.getMessage()); | log.warn(e.getMessage()); | private void prevSession() { JInternalFrame[] frames = (JInternalFrame[])desktop.getAllFrames(); JInternalFrame miv = desktop.getSelectedFrame(); if (miv == null) return; int index = desktop.getIndexOf(miv); if (index == -1) return; MyInternalFrame mix = (MyInternalFrame... |
System.out.println("session found and closing down " + index); | log.info("session found and closing down " + index); | public void removeSessionView(Session targetSession) { int index = getIndexOfSession(targetSession); MyInternalFrame nextMIF = getNextInternalFrame(); System.out.println("session found and closing down " + index); targetSession.removeSessionListener(this); targetSession.removeSessionJumpList... |
log.debug(" num of frames before removal " + myFrameList.size()); | public void removeSessionView(Session targetSession) { int index = getIndexOfSession(targetSession); MyInternalFrame nextMIF = getNextInternalFrame(); System.out.println("session found and closing down " + index); targetSession.removeSessionListener(this); targetSession.removeSessionJumpList... | |
log.debug(" num of frames left " + myFrameList.size()); | public void removeSessionView(Session targetSession) { int index = getIndexOfSession(targetSession); MyInternalFrame nextMIF = getNextInternalFrame(); System.out.println("session found and closing down " + index); targetSession.removeSessionListener(this); targetSession.removeSessionJumpList... | |
System.out.println(e.getMessage()); | log.warn(e.getMessage()); | public void removeSessionView(Session targetSession) { int index = getIndexOfSession(targetSession); MyInternalFrame nextMIF = getNextInternalFrame(); System.out.println("session found and closing down " + index); targetSession.removeSessionListener(this); targetSession.removeSessionJumpList... |
threadIterator = threads.values().iterator(); index = 1; | reset(); | public DebugState process(KeyboardEvent event) { DebugState newState = this; switch (event.getKeyChar()) { case 'n': if (threadIterator.hasNext()) { final Thread t = (Thread) threadIterator.next(); newState = new ThreadState(this, t, index++); ... |
if (!initStageDone) super.addImpl(comp, constraints, index); | if (isRootPaneCheckingEnabled()) getContentPane().add(comp, constraints, index); | protected void addImpl(Component comp, Object constraints, int index) { // If we're adding in the initialization stage use super.add. // Otherwise pass the add onto the content pane. if (!initStageDone) super.addImpl(comp, constraints, index); else { if (isRootPaneCheckingEnabled()) ... |
{ if (isRootPaneCheckingEnabled()) throw new Error("Do not add directly to JDialog." + " Use getContentPane().add instead."); getContentPane().add(comp, constraints, index); } | super.addImpl(comp, constraints, index); | protected void addImpl(Component comp, Object constraints, int index) { // If we're adding in the initialization stage use super.add. // Otherwise pass the add onto the content pane. if (!initStageDone) super.addImpl(comp, constraints, index); else { if (isRootPaneCheckingEnabled()) ... |
initStageDone = true; | setRootPaneCheckingEnabled(true); | protected void dialogInit() { // FIXME: Do a check on GraphicsEnvironment.isHeadless() setLocale(JComponent.getDefaultLocale()); getRootPane(); // Will do set/create. invalidate(); // Now that initStageDone is true, adds and layouts apply to contentPane, // not top-level. initStageDone = ... |
if (initStageDone) { | public void setLayout(LayoutManager manager) { // Check if we're in initialization stage. If so, call super.setLayout // otherwise, valid calls go to the content pane. if (initStageDone) { if (isRootPaneCheckingEnabled()) throw new Error("Cannot set top-level layout. Use" ... | |
throw new Error("Cannot set top-level layout. Use" + " getConentPane().setLayout instead."); | public void setLayout(LayoutManager manager) { // Check if we're in initialization stage. If so, call super.setLayout // otherwise, valid calls go to the content pane. if (initStageDone) { if (isRootPaneCheckingEnabled()) throw new Error("Cannot set top-level layout. Use" ... | |
} | public void setLayout(LayoutManager manager) { // Check if we're in initialization stage. If so, call super.setLayout // otherwise, valid calls go to the content pane. if (initStageDone) { if (isRootPaneCheckingEnabled()) throw new Error("Cannot set top-level layout. Use" ... | |
Dimension prefSize = getPreferredSize(); prefSize.width = Math.max(prefSize.width, minimumSize.width); prefSize.height = Math.max(prefSize.height, minimumSize.height); setPreferredSize(prefSize); Dimension maxSize = getMaximumSize(); maxSize.width = Math.max(maxSize.width, minimumSize.width); maxSize.height = Math.max(... | public void setMinimumSize(Dimension min) { Dimension oldMinimumSize = minimumSize; minimumSize = min; firePropertyChange("minimumSize", oldMinimumSize, minimumSize); revalidate(); repaint(); } | |
kbArea = new Rectangle2D.Float(); | public GuiGraphicBuffer () { tArea = new Rectangle2D.Float(); cArea = new Rectangle2D.Float(); aArea = new Rectangle2D.Float(); sArea = new Rectangle2D.Float(); pArea = new Rectangle2D.Float(); mArea = new Rectangle2D.Float(); iArea = new Rectangle2D.Float(); } | |
if (gg2d == null) { return; } | public synchronized void drawImageBuffer(Graphics2D gg2d,int x, int y, int width, int height) { synchronized (lock) { gg2d.drawImage(bi.getSubimage(x,y,width,height),null,x,y); // tell waiting threads to wake up lock.notify(); } } | |
kbArea.setRect((float)(sArea.getX()+ sArea.getWidth()) + (20 * fmWidth), fmHeight * (numRows + 1), fmWidth + fmWidth, fmHeight); | public Graphics2D drawOIA (int fmWidth, int fmHeight, int numRows, int numCols, Font font, Color colorBg, Color colorBlue ) { G... | |
bad.minor = Minor.Any; | public static TaggedComponent[] extract(Any any) { try { return ((MultipleComponentProfileHolder) any.extract_Streamable()).value; } catch (ClassCastException cex) { BAD_OPERATION bad = new BAD_OPERATION("MultipleComponentProfile expected"); bad.initCause(cex); throw ... | |
orb.setPort(PORT); orb.init(args, null); | Functional_ORB.setPort(Functional_ORB.DEFAULT_INITIAL_PORT); | public static void main(String[] args) { int port = PORT; String iorf = null; try { // Create and initialize the ORB final Functional_ORB orb = new Functional_ORB(); orb.setPort(PORT); orb.init(args, null); // Create the servant and register it with the ORB Nam... |
sb = new StringBuffer(); | public KeyStrokenizer() { setKeyStrokes(null); } | |
String ks = keyStrokes.substring(index); keyStrokes.setLength(0); return ks; | return keyStrokes.substring(index); | public String getUnprocessedKeyStroked() { if(index >= length)// if (keyStrokes.length() == 0) return null; else {// return keyStrokes.toString(); String ks = keyStrokes.substring(index); keyStrokes.setLength(0); return ks; } } |
"at position " + index); | "at position " + index + " len " + length ); | public String nextKeyStroke() { String s = null; boolean gotOne = false; int start = index; if(length > index) { sb.setLength(0); char c = keyStrokes.charAt(index); switch(c) { case '[': sb.append(c); index++; // we need... |
" mnemonic key was not not complete ending not found :2 " + | " mnemonic key was incomplete ending not found :2 " + | public String nextKeyStroke() { String s = null; boolean gotOne = false; int start = index; if(length > index) { sb.setLength(0); char c = keyStrokes.charAt(index); switch(c) { case '[': sb.append(c); index++; // we need... |
" mnemonic key was not not complete ending not found :3 " + | " mnemonic key was incomplete ending not found :3 " + | public String nextKeyStroke() { String s = null; boolean gotOne = false; int start = index; if(length > index) { sb.setLength(0); char c = keyStrokes.charAt(index); switch(c) { case '[': sb.append(c); index++; // we need... |
} c = keyStrokes.charAt(index); if(c == ']') { | public String nextKeyStroke() { String s = null; boolean gotOne = false; int start = index; if(length > index) { sb.setLength(0); char c = keyStrokes.charAt(index); switch(c) { case '[': sb.append(c); index++; // we need... | |
System.out.println( " mnemonic key was not complete beginning not found :4 " + "at position " + index); | c = keyStrokes.charAt(index); if(c == ']') { sb.append(c); index++; } else { System.out.println( " mnemonic key was incomplete beginning not found :4 " + "at position " + index); } | public String nextKeyStroke() { String s = null; boolean gotOne = false; int start = index; if(length > index) { sb.setLength(0); char c = keyStrokes.charAt(index); switch(c) { case '[': sb.append(c); index++; // we need... |
keyStrokes.delete(start,index); index = 0; length = keyStrokes.length(); | public String nextKeyStroke() { String s = null; boolean gotOne = false; int start = index; if(length > index) { sb.setLength(0); char c = keyStrokes.charAt(index); switch(c) { case '[': sb.append(c); index++; // we need... | |
keyStrokes.append(strokes); | keyStrokes.setLength(0); | public void setKeyStrokes (String strokes) { if (strokes != null) {// keyStrokes.setLength(0); keyStrokes.append(strokes);// System.out.println("set "+ keyStrokes);// index = 0; length = keyStrokes.length(); } else { keyStrokes = new StringBuffer(); ... |
length = keyStrokes.length(); | length = strokes.length(); | public void setKeyStrokes (String strokes) { if (strokes != null) {// keyStrokes.setLength(0); keyStrokes.append(strokes);// System.out.println("set "+ keyStrokes);// index = 0; length = keyStrokes.length(); } else { keyStrokes = new StringBuffer(); ... |
sb = new StringBuffer(); index = 0; | public void setKeyStrokes (String strokes) { if (strokes != null) {// keyStrokes.setLength(0); keyStrokes.append(strokes);// System.out.println("set "+ keyStrokes);// index = 0; length = keyStrokes.length(); } else { keyStrokes = new StringBuffer(); ... | |
keyStrokes.append(strokes); index = 0; | public void setKeyStrokes (String strokes) { if (strokes != null) {// keyStrokes.setLength(0); keyStrokes.append(strokes);// System.out.println("set "+ keyStrokes);// index = 0; length = keyStrokes.length(); } else { keyStrokes = new StringBuffer(); ... | |
synchronized (lock) { | public synchronized void drawImageBuffer(Graphics2D gg2d,int x, int y, int width, int height) { /** * @todo this is a hack and should be fixed at the root of the problem */ if (gg2d == null) { System.out.println(" we got a null graphic object "); return; } //synchro... | |
lock.notifyAll(); } | public synchronized void drawImageBuffer(Graphics2D gg2d,int x, int y, int width, int height) { /** * @todo this is a hack and should be fixed at the root of the problem */ if (gg2d == null) { System.out.println(" we got a null graphic object "); return; } //synchro... | |
if (isJavaMIMEType(name)) { return name.substring(GNU_JAVA_MIME_PREFIX.length()); } else | public static String decodeJavaMIMEType (String name) { return null; } | |
if (df != null) { return encodeJavaMIMEType(df.getMimeType()); } else | public static String encodeDataFlavor (DataFlavor df) { return null; } | |
if (mime != null) return GNU_JAVA_MIME_PREFIX + mime; else | public static String encodeJavaMIMEType (String mime) { return null; } | |
return false; | return (name != null && name.startsWith(GNU_JAVA_MIME_PREFIX)); | public static boolean isJavaMIMEType (String name) { return false; } |
vt.isOnSignoffScreen(); | private void closeSession() { vt.isOnSignoffScreen(); Object[] message = new Object[1]; message[0] = LangTool.getString("cs.message"); String[] options = {LangTool.getString("cs.optThis"), LangTool.getString("cs.optAll"), LangTool.getString... | |
closeMe(); | if (!isOnSignoffScreen()) { if (confirmClose()) { closeMe(); } } else { closeMe(); } | private void closeSession() { vt.isOnSignoffScreen(); Object[] message = new Object[1]; message[0] = LangTool.getString("cs.message"); String[] options = {LangTool.getString("cs.optThis"), LangTool.getString("cs.optAll"), LangTool.getString... |
Vector listeners = sesConfig.getSessionConfigListeners(); Enumeration e = listeners.elements(); while (e.hasMoreElements()) { sa.addPropertyChangeListener((Session)e.nextElement()); } | private void doAttributes() { Frame parent = null; // if me is null then we must be called from an applet so we create // a new frame object. if (me == null) parent = new JFrame(); else parent = (Frame)me.getParentView((Session)this); SessionAttributes sa = new Session... | |
listeners = sesConfig.getSessionConfigListeners(); e = listeners.elements(); while (e.hasMoreElements()) { sa.removePropertyChangeListener((Session)e.nextElement()); } | private void doAttributes() { Frame parent = null; // if me is null then we must be called from an applet so we create // a new frame object. if (me == null) parent = new JFrame(); else parent = (Frame)me.getParentView((Session)this); SessionAttributes sa = new Session... | |
if (keyMap.isKeyStrokeDefined(MNEMONIC_JUMP_PREV + ".alt2")) { ks = keyMap.getKeyStroke(MNEMONIC_JUMP_PREV + ".alt2"); getInputMap().put(ks,MNEMONIC_JUMP_PREV); getActionMap().put(MNEMONIC_JUMP_PREV,prevSession ); } | private void initKeyBindings() { KeyStroke ks; Action newSession = new AbstractAction(MNEMONIC_OPEN_NEW) { public void actionPerformed(ActionEvent e) { me.startNewSession(); } }; if (!keyMap.isKeyStrokeDefined(MNEMONIC_OPEN_NEW)) { ks = KeyStroke.getK... | |
public void onConfigChanged(SessionConfigEvent changeEvent) { | public void onConfigChanged(SessionConfigEvent pce) { | public void onConfigChanged(SessionConfigEvent changeEvent) { } |
String pn = pce.getPropertyName(); if (pn.equals("keypad")) { if (((String)pce.getNewValue()).equals("Yes")) { keyPad.setVisible(true); } else { keyPad.setVisible(false); } this.validate(); } if (pn.equals("doubleClick")) { if (((String)pce.getNewValue()).equals("Yes")) { doubleClick = true; } else { doubleClick = fa... | public void onConfigChanged(SessionConfigEvent changeEvent) { } | |
array[0] = 1 / 3 + (blue - red) / delta; | array[0] = 1f / 3 + (blue - red) / delta; | public static float[] RGBtoHSB(int red, int green, int blue, float array[]) { if (array == null) array = new float[3]; // Calculate brightness. int min; int max; if (red < green) { min = red; max = green; } else { min = green; max = red; } if ... |
array[0] = 2 / 3 + (red - green) / delta; | array[0] = 2f / 3 + (red - green) / delta; | public static float[] RGBtoHSB(int red, int green, int blue, float array[]) { if (array == null) array = new float[3]; // Calculate brightness. int min; int max; if (red < green) { min = red; max = green; } else { min = green; max = red; } if ... |
frame.doDefaultCloseAction(); | public void closeFrame(JInternalFrame frame) { Container c = frame.getParent(); frame.doDefaultCloseAction(); if (c != null) { if (frame.isIcon()) c.remove(frame.getDesktopIcon()); else c.remove(frame); c.repaint(); } } |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.