bugged
stringlengths 6
599k
| fixed
stringlengths 10
599k
| __index_level_0__
int64 0
1.13M
|
|---|---|---|
private Object invokeCommon(Remote obj, Method method, Object[] params, int opnum, long hash) throws Exception { UnicastConnection conn; try { conn = manager.getConnection(); } catch (IOException e1) { throw new RemoteException("connection failed to host: " + manager.serverName, e1); } ObjectOutputStream out; DataOutputStream dout; try { dout = conn.getDataOutputStream(); dout.writeByte(MESSAGE_CALL); out = conn.getObjectOutputStream(); objid.write(out); out.writeInt(opnum); out.writeLong(hash); // must handle primitive class and their wrapper classes Class clss[] = method.getParameterTypes(); for(int i = 0; i < clss.length; i++) ((RMIObjectOutputStream)out).writeValue(params[i], clss[i]); out.flush(); } catch (IOException e2) { throw new RemoteException("call failed: ", e2); } int returncode; Object returnval; DataInputStream din; ObjectInputStream in; UID ack; try { din = conn.getDataInputStream(); if ((returncode = din.readUnsignedByte()) != MESSAGE_CALL_ACK) { conn.disconnect(); throw new RemoteException("Call not acked:" + returncode); } in = conn.getObjectInputStream(); returncode = in.readUnsignedByte(); ack = UID.read(in); Class cls = method.getReturnType(); if(cls == Void.TYPE){ returnval = null; in.readObject(); }else returnval = ((RMIObjectInputStream)in).readValue(cls); } catch (IOException e3) { //for debug: e3.printStackTrace(); throw new RemoteException("call return failed: ", e3); } /* if DGCAck is necessary?? //According to RMI wire protocol, send a DGCAck // to indicate receiving return value dout.writeByte(MESSAGE_DGCACK); ack.write(dout); out.flush(); */ manager.discardConnection(conn); if (returncode != RETURN_ACK && returnval != null) { throw (Exception)returnval; } return (returnval);}
|
private Object invokeCommon(Remote obj, Method method, Object[] params, int opnum, long hash) throws Exception { UnicastConnection conn; try { conn = manager.getConnection(); } catch (IOException e1) { throw new RemoteException("connection failed to host: " + manager.serverName, e1); } ObjectOutputStream out; DataOutputStream dout; try { dout = conn.getDataOutputStream(); dout.writeByte(MESSAGE_CALL); out = conn.getObjectOutputStream(); objid.write(out); out.writeInt(opnum); out.writeLong(hash); // must handle primitive class and their wrapper classes Class clss[] = method.getParameterTypes(); for(int i = 0; i < clss.length; i++) ((RMIObjectOutputStream)out).writeValue(params[i], clss[i]); out.flush(); } catch (IOException e2) { throw new RemoteException("call failed: ", e2); } int returncode; Object returnval; DataInputStream din; ObjectInputStream in; UID ack; try { din = conn.getDataInputStream(); if ((returncode = din.readUnsignedByte()) != MESSAGE_CALL_ACK) { conn.disconnect(); throw new RemoteException("Call not acked:" + returncode); } in = conn.getObjectInputStream(); returncode = in.readUnsignedByte(); ack = UID.read(in); Class cls = method.getReturnType(); if(cls == Void.TYPE){ returnval = null; in.readObject(); }else returnval = ((RMIObjectInputStream)in).readValue(cls); } catch (IOException e3) { //for debug: e3.printStackTrace(); throw new RemoteException("call return failed: ", e3); } /* if DGCAck is necessary?? //According to RMI wire protocol, send a DGCAck // to indicate receiving return value dout.writeByte(MESSAGE_DGCACK); ack.write(dout); out.flush(); */ manager.discardConnection(conn); if (returncode != RETURN_ACK && returnval != null) { throw (Exception)returnval; } return (returnval);}
| 6,064
|
private Object invokeCommon(Remote obj, Method method, Object[] params, int opnum, long hash) throws Exception { UnicastConnection conn; try { conn = manager.getConnection(); } catch (IOException e1) { throw new RemoteException("connection failed to host: " + manager.serverName, e1); } ObjectOutputStream out; DataOutputStream dout; try { dout = conn.getDataOutputStream(); dout.writeByte(MESSAGE_CALL); out = conn.getObjectOutputStream(); objid.write(out); out.writeInt(opnum); out.writeLong(hash); // must handle primitive class and their wrapper classes Class clss[] = method.getParameterTypes(); for(int i = 0; i < clss.length; i++) ((RMIObjectOutputStream)out).writeValue(params[i], clss[i]); out.flush(); } catch (IOException e2) { throw new RemoteException("call failed: ", e2); } int returncode; Object returnval; DataInputStream din; ObjectInputStream in; UID ack; try { din = conn.getDataInputStream(); if ((returncode = din.readUnsignedByte()) != MESSAGE_CALL_ACK) { conn.disconnect(); throw new RemoteException("Call not acked:" + returncode); } in = conn.getObjectInputStream(); returncode = in.readUnsignedByte(); ack = UID.read(in); Class cls = method.getReturnType(); if(cls == Void.TYPE){ returnval = null; in.readObject(); }else returnval = ((RMIObjectInputStream)in).readValue(cls); } catch (IOException e3) { //for debug: e3.printStackTrace(); throw new RemoteException("call return failed: ", e3); } /* if DGCAck is necessary?? //According to RMI wire protocol, send a DGCAck // to indicate receiving return value dout.writeByte(MESSAGE_DGCACK); ack.write(dout); out.flush(); */ manager.discardConnection(conn); if (returncode != RETURN_ACK && returnval != null) { throw (Exception)returnval; } return (returnval);}
|
private Object invokeCommon(Remote obj, Method method, Object[] params, int opnum, long hash) throws Exception { UnicastConnection conn; try { conn = manager.getConnection(); } catch (IOException e1) { throw new RemoteException("connection failed to host: " + manager.serverName, e1); } ObjectOutputStream out; DataOutputStream dout; try { dout = conn.getDataOutputStream(); dout.writeByte(MESSAGE_CALL); out = conn.getObjectOutputStream(); objid.write(out); out.writeInt(opnum); out.writeLong(hash); // must handle primitive class and their wrapper classes Class clss[] = method.getParameterTypes(); for(int i = 0; i < clss.length; i++) ((RMIObjectOutputStream)out).writeValue(params[i], clss[i]); out.flush(); } catch (IOException e2) { throw new RemoteException("call failed: ", e2); } int returncode; Object returnval; DataInputStream din; ObjectInputStream in; UID ack; try { din = conn.getDataInputStream(); if ((returncode = din.readUnsignedByte()) != MESSAGE_CALL_ACK) { conn.disconnect(); throw new RemoteException("Call not acked:" + returncode); } in = conn.getObjectInputStream(); returncode = in.readUnsignedByte(); ack = UID.read(in); Class cls = method.getReturnType(); if(cls == Void.TYPE){ returnval = null; in.readObject(); }else returnval = ((RMIObjectInputStream)in).readValue(cls); } } catch (IOException e3) { //for debug: e3.printStackTrace(); throw new RemoteException("call return failed: ", e3); } /* if DGCAck is necessary?? //According to RMI wire protocol, send a DGCAck // to indicate receiving return value dout.writeByte(MESSAGE_DGCACK); ack.write(dout); out.flush(); */ manager.discardConnection(conn); if (returncode != RETURN_ACK && returnval != null) { throw (Exception)returnval; } return (returnval);}
| 6,065
|
private Object invokeCommon(Remote obj, Method method, Object[] params, int opnum, long hash) throws Exception { UnicastConnection conn; try { conn = manager.getConnection(); } catch (IOException e1) { throw new RemoteException("connection failed to host: " + manager.serverName, e1); } ObjectOutputStream out; DataOutputStream dout; try { dout = conn.getDataOutputStream(); dout.writeByte(MESSAGE_CALL); out = conn.getObjectOutputStream(); objid.write(out); out.writeInt(opnum); out.writeLong(hash); // must handle primitive class and their wrapper classes Class clss[] = method.getParameterTypes(); for(int i = 0; i < clss.length; i++) ((RMIObjectOutputStream)out).writeValue(params[i], clss[i]); out.flush(); } catch (IOException e2) { throw new RemoteException("call failed: ", e2); } int returncode; Object returnval; DataInputStream din; ObjectInputStream in; UID ack; try { din = conn.getDataInputStream(); if ((returncode = din.readUnsignedByte()) != MESSAGE_CALL_ACK) { conn.disconnect(); throw new RemoteException("Call not acked:" + returncode); } in = conn.getObjectInputStream(); returncode = in.readUnsignedByte(); ack = UID.read(in); Class cls = method.getReturnType(); if(cls == Void.TYPE){ returnval = null; in.readObject(); }else returnval = ((RMIObjectInputStream)in).readValue(cls); } catch (IOException e3) { //for debug: e3.printStackTrace(); throw new RemoteException("call return failed: ", e3); } /* if DGCAck is necessary?? //According to RMI wire protocol, send a DGCAck // to indicate receiving return value dout.writeByte(MESSAGE_DGCACK); ack.write(dout); out.flush(); */ manager.discardConnection(conn); if (returncode != RETURN_ACK && returnval != null) { throw (Exception)returnval; } return (returnval);}
|
private Object invokeCommon(Remote obj, Method method, Object[] params, int opnum, long hash) throws Exception { UnicastConnection conn; try { conn = manager.getConnection(); } catch (IOException e1) { throw new RemoteException("connection failed to host: " + manager.serverName, e1); } ObjectOutputStream out; DataOutputStream dout; try { dout = conn.getDataOutputStream(); dout.writeByte(MESSAGE_CALL); out = conn.getObjectOutputStream(); objid.write(out); out.writeInt(opnum); out.writeLong(hash); // must handle primitive class and their wrapper classes Class clss[] = method.getParameterTypes(); for(int i = 0; i < clss.length; i++) ((RMIObjectOutputStream)out).writeValue(params[i], clss[i]); out.flush(); } catch (IOException e2) { throw new RemoteException("call failed: ", e2); } int returncode; Object returnval; DataInputStream din; ObjectInputStream in; UID ack; try { din = conn.getDataInputStream(); if ((returncode = din.readUnsignedByte()) != MESSAGE_CALL_ACK) { conn.disconnect(); throw new RemoteException("Call not acked:" + returncode); } in = conn.getObjectInputStream(); returncode = in.readUnsignedByte(); ack = UID.read(in); Class cls = method.getReturnType(); if(cls == Void.TYPE){ returnval = null; in.readObject(); }else returnval = ((RMIObjectInputStream)in).readValue(cls); } catch (IOException e3) { //for debug: e3.printStackTrace(); throw new RemoteException("call return failed: ", e3); } /* if DGCAck is necessary?? //According to RMI wire protocol, send a DGCAck // to indicate receiving return value dout.writeByte(MESSAGE_DGCACK); ack.write(dout); out.flush(); */ manager.discardConnection(conn); if (returncode != RETURN_ACK && returnval != null) { if (returncode == RETURN_NACK) throw (Exception)returnval; else throw new RemoteException("unexpected returncode: " + returncode); } return (returnval);}
| 6,066
|
public void insert_Value(Serializable x, TypeCode typecode) { 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); }
| 6,068
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); has._read(input); } catch (BadKind ex) { throw new MARSHAL("Bad kind: " + ex.getMessage()); } catch (IOException ex) { throw new MARSHAL("IO exception: " + ex.getMessage()); } }
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); if (!(has instanceof universalHolder) && (kind == TCKind._tk_value_box)) { Field vField = has.getClass().getField("value"); BoxedValueHelper helper; try { Class helperClass = Class.forName(ObjectCreator.toHelperName(a_type.id())); helper = (BoxedValueHelper) helperClass.newInstance(); } catch (BadKind ex) { throw new MARSHAL("Bad kind: " + ex.getMessage()); } catch (IOException ex) { throw new MARSHAL("IO exception: " + ex.getMessage()); } }
| 6,070
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); has._read(input); } catch (BadKind ex) { throw new MARSHAL("Bad kind: " + ex.getMessage()); } catch (IOException ex) { throw new MARSHAL("IO exception: " + ex.getMessage()); } }
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); has._read(input); } catch (Exception ex) { throw new MARSHAL("Bad kind: " + ex.getMessage()); } catch (IOException ex) { throw new MARSHAL("IO exception: " + ex.getMessage()); } }
| 6,071
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); has._read(input); } catch (BadKind ex) { throw new MARSHAL("Bad kind: " + ex.getMessage()); } catch (IOException ex) { throw new MARSHAL("IO exception: " + ex.getMessage()); } }
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); has._read(input); } catch (BadKind ex) { helper = null; } Object content = Vio.read(input, helper); vField.set(has, content); } else has._read(input); } catch (IOException ex) { throw new MARSHAL("IO exception: " + ex.getMessage()); } }
| 6,072
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); has._read(input); } catch (BadKind ex) { throw new MARSHAL("Bad kind: " + ex.getMessage()); } catch (IOException ex) { throw new MARSHAL("IO exception: " + ex.getMessage()); } }
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); has._read(input); } catch (BadKind ex) { throw new MARSHAL("Bad kind: " + ex.getMessage()); } catch (Exception ex) { throw new MARSHAL("IO exception: " + ex.getMessage()); } }
| 6,073
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); has._read(input); } catch (BadKind ex) { throw new MARSHAL("Bad kind: " + ex.getMessage()); } catch (IOException ex) { throw new MARSHAL("IO exception: " + ex.getMessage()); } }
|
public void read_value(org.omg.CORBA.portable.InputStream input, TypeCode a_type ) throws MARSHAL { try { int kind = a_type.kind().value(); // Fixed needs special handling. if (kind == TCKind._tk_fixed) { BigDecimal dec = BigDecimalHelper.read(input, a_type.fixed_scale()); has = new FixedHolder(dec); } else { has = holderFactory.createHolder(a_type); if (has == null) { // Use the Universal Holder that reads till the end of stream. // This works with the extract/insert pair of the typical // Helper. cdrBufOutput buffer = new cdrBufOutput(); buffer.setOrb(orb); has = new universalHolder(buffer); } } type(a_type); has._read(input); } catch (BadKind ex) { throw new MARSHAL("Bad kind: " + ex.getMessage()); } catch (IOException ex) { MARSHAL m = new MARSHAL(); m.initCause(ex); throw m; } }
| 6,074
|
public Object clone() { return new QuadSegment(P1.getX(), P1.getY(), cp.getX(), cp.getY(), P2.getX(), P2.getY()); }
|
public Object clone() { return new QuadSegment(P1.getX(), P1.getY(), cp.getX(), cp.getY(), P2.getX(), P2.getY()); }
| 6,076
|
public static void loadMacros(Session session, Macronizer macros, JMenu menu) { final Session ses = session; Vector mv = new Vector(); Action action; menu.addSeparator(); String[] macrosList = Macronizer.getMacroList(); for (int x = 0; x < macrosList.length; x++) { mv.add(macrosList[x]); } Collections.sort(mv); for (int x = 0; x < mv.size(); x++) { action = new AbstractAction((String)mv.get(x)) { public void actionPerformed(ActionEvent e) { ses.executeMeMacro(e); } }; JMenuItem mi = menu.add(action); final Gui5250 ji = (Gui5250)session; mi.addMouseListener(new MouseAdapter() { public void mouseReleased(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } public void mousePressed(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } public void mouseClicked(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } }); } scriptDir("scripts",menu,session); String conPath = ""; String conPath2 = ""; try { conPath = new File("scripts").getCanonicalPath(); conPath2 = new File(GlobalConfigure.instance().getProperty( "emulator.settingsDirectory") + "scripts").getCanonicalPath(); } catch (IOException ioe ) { } // lets not load the menu again if they point to the same place if (!conPath.equals(conPath2)) scriptDir(GlobalConfigure.instance().getProperty( "emulator.settingsDirectory") + "scripts",menu,session); }
|
public static void loadMacros(Session session, Macronizer macros, JMenu menu) { final Session ses = session; Vector mv = new Vector(); Action action; menu.addSeparator(); String[] macrosList = Macronizer.getMacroList(); for (int x = 0; x < macrosList.length; x++) { mv.add(macrosList[x]); } Collections.sort(mv); for (int x = 0; x < mv.size(); x++) { action = new AbstractAction((String)mv.get(x)) { public void actionPerformed(ActionEvent e) { ses.executeMeMacro(e); } }; JMenuItem mi = menu.add(action); final Gui5250 ji = (Gui5250)session; mi.addMouseListener(new MouseAdapter() { public void mouseReleased(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } public void mousePressed(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } public void mouseClicked(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } }); } scriptDir("scripts",menu,session); String conPath = ""; String conPath2 = ""; try { conPath = new File("scripts").getCanonicalPath(); conPath2 = new File(GlobalConfigure.getInstance().getProperty( "emulator.settingsDirectory") + "scripts").getCanonicalPath(); } catch (IOException ioe ) { } // lets not load the menu again if they point to the same place if (!conPath.equals(conPath2)) scriptDir(GlobalConfigure.instance().getProperty( "emulator.settingsDirectory") + "scripts",menu,session); }
| 6,077
|
public static void loadMacros(Session session, Macronizer macros, JMenu menu) { final Session ses = session; Vector mv = new Vector(); Action action; menu.addSeparator(); String[] macrosList = Macronizer.getMacroList(); for (int x = 0; x < macrosList.length; x++) { mv.add(macrosList[x]); } Collections.sort(mv); for (int x = 0; x < mv.size(); x++) { action = new AbstractAction((String)mv.get(x)) { public void actionPerformed(ActionEvent e) { ses.executeMeMacro(e); } }; JMenuItem mi = menu.add(action); final Gui5250 ji = (Gui5250)session; mi.addMouseListener(new MouseAdapter() { public void mouseReleased(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } public void mousePressed(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } public void mouseClicked(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } }); } scriptDir("scripts",menu,session); String conPath = ""; String conPath2 = ""; try { conPath = new File("scripts").getCanonicalPath(); conPath2 = new File(GlobalConfigure.instance().getProperty( "emulator.settingsDirectory") + "scripts").getCanonicalPath(); } catch (IOException ioe ) { } // lets not load the menu again if they point to the same place if (!conPath.equals(conPath2)) scriptDir(GlobalConfigure.instance().getProperty( "emulator.settingsDirectory") + "scripts",menu,session); }
|
public static void loadMacros(Session session, Macronizer macros, JMenu menu) { final Session ses = session; Vector mv = new Vector(); Action action; menu.addSeparator(); String[] macrosList = Macronizer.getMacroList(); for (int x = 0; x < macrosList.length; x++) { mv.add(macrosList[x]); } Collections.sort(mv); for (int x = 0; x < mv.size(); x++) { action = new AbstractAction((String)mv.get(x)) { public void actionPerformed(ActionEvent e) { ses.executeMeMacro(e); } }; JMenuItem mi = menu.add(action); final Gui5250 ji = (Gui5250)session; mi.addMouseListener(new MouseAdapter() { public void mouseReleased(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } public void mousePressed(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } public void mouseClicked(MouseEvent e) { if (SwingUtilities.isRightMouseButton(e)) { doOptionsPopup(e,ses); } } }); } scriptDir("scripts",menu,session); String conPath = ""; String conPath2 = ""; try { conPath = new File("scripts").getCanonicalPath(); conPath2 = new File(GlobalConfigure.instance().getProperty( "emulator.settingsDirectory") + "scripts").getCanonicalPath(); } catch (IOException ioe ) { } // lets not load the menu again if they point to the same place if (!conPath.equals(conPath2)) scriptDir(GlobalConfigure.getInstance().getProperty( "emulator.settingsDirectory") + "scripts",menu,session); }
| 6,078
|
public CheckboxMenuItem(String label, boolean state) { super(label); this.state = state; if (GraphicsEnvironment.isHeadless()) throw new HeadlessException(); }
|
public CheckboxMenuItem(String label, boolean state) { super(label); this.state = state; if (GraphicsEnvironment.isHeadless()) throw new HeadlessException(); }
| 6,079
|
public synchronized void addItemListener(ItemListener listener) { item_listeners = AWTEventMulticaster.add(item_listeners, listener); enableEvents(AWTEvent.ITEM_EVENT_MASK); }
|
addItemListener(ItemListener listener) { item_listeners = AWTEventMulticaster.add(item_listeners, listener); enableEvents(AWTEvent.ITEM_EVENT_MASK); }
| 6,080
|
public synchronized void setState(boolean state) { this.state = state; if (peer != null) { CheckboxMenuItemPeer cp = (CheckboxMenuItemPeer) peer; cp.setState(state); } }
|
setState(boolean state) { this.state = state; if (peer != null) { CheckboxMenuItemPeer cp = (CheckboxMenuItemPeer) peer; cp.setState(state); } }
| 6,081
|
public synchronized void setState(boolean state) { this.state = state; if (peer != null) { CheckboxMenuItemPeer cp = (CheckboxMenuItemPeer) peer; cp.setState(state); } }
|
public synchronized void setState(boolean state) { this.state = state; if (peer != null) { CheckboxMenuItemPeer cp = (CheckboxMenuItemPeer) peer; cp.setState(state); } }
| 6,082
|
public final void add(VmMethod method, int pc, int offset) { addressTable.add(method, pc, offset); }
|
public final void add(VmMethod method, int pc, int offset) { addressTable.add(method, pc, offset); }
| 6,084
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
| 6,085
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { if (text != null) { text = bufferedKeys + text; } keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
| 6,086
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = null; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = null; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
| 6,087
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !keyboardLocked && !isStatusErrorCode() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
| 6,088
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) { simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
| 6,089
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
|
public void sendKeys(String text) { if (keyboardLocked) { if(text.equals("[reset]") || text.equals("[sysreq]") || text.equals("[attn]")) { bufferedKeys = ""; keysBuffered = false; setKBIndicatorOff(); simulateMnemonic(getMnemonicValue(text)); } else { keysBuffered = true; setKBIndicatorOn(); if(bufferedKeys == null){ bufferedKeys = text; return; } else { bufferedKeys += text; return; } } } else { if (keysBuffered) { text = bufferedKeys + text; keysBuffered = false; setKBIndicatorOff(); bufferedKeys = ""; } // check to see if position is in a field and if it is then change // current field to that field isInField(lastPos,true); if (text.length() == 1 && !text.equals("[") && !text.equals("]")) { simulateKeyStroke(text.charAt(0)); } else { strokenizer.setKeyStrokes(text); String s; boolean done = false; while (strokenizer.hasMoreKeyStrokes() && !done) { s = strokenizer.nextKeyStroke(); if (s.length() == 1) { simulateKeyStroke(s.charAt(0)); } else { if (s != null) simulateMnemonic(getMnemonicValue(s)); else System.out.println(" send keys mnemonic " + s); } if (keyboardLocked) { bufferedKeys = strokenizer.getUnprocessedKeyStroked(); if (bufferedKeys != null) { keysBuffered = true; setKBIndicatorOn(); } done = true; } } } } }
| 6,090
|
public void setStatus(byte attr,byte value,String s) { statusString = s; // draw the status information bi.setStatus(attr,value,s, fmWidth, fmHeight, lm, font, colorBg, colorRed, colorWhite); // set environment variables switch (attr) { case STATUS_SYSTEM: if (value == STATUS_VALUE_ON) { statusXSystem =true; } else statusXSystem = false; break; case STATUS_ERROR_CODE: if (value == STATUS_VALUE_ON) { statusErrorCode = true; setKeyboardLocked(true); Toolkit.getDefaultToolkit().beep(); } else { statusErrorCode = false; setKeyboardLocked(false); homePos = saveHomePos; saveHomePos = 0; pendingInsert = false; } break; } updateImage(sArea.getBounds()); }
|
public void setStatus(byte attr,byte value,String s) { statusString = s; // draw the status information bi.setStatus(attr,value,s, fmWidth, fmHeight, lm, font, colorBg, colorRed, colorWhite); // set environment variables switch (attr) { case STATUS_SYSTEM: if (value == STATUS_VALUE_ON) { statusXSystem =true; } else statusXSystem = false; break; case STATUS_ERROR_CODE: if (value == STATUS_VALUE_ON) { statusErrorCode = true; setKeyboardLocked(true); Toolkit.getDefaultToolkit().beep(); } else { statusErrorCode = false; setKeyboardLocked(false); homePos = saveHomePos; saveHomePos = 0; pendingInsert = false; } break; } updateImage(sArea.getBounds()); }
| 6,091
|
public void setStatus(byte attr,byte value,String s) { statusString = s; // draw the status information bi.setStatus(attr,value,s, fmWidth, fmHeight, lm, font, colorBg, colorRed, colorWhite); // set environment variables switch (attr) { case STATUS_SYSTEM: if (value == STATUS_VALUE_ON) { statusXSystem =true; } else statusXSystem = false; break; case STATUS_ERROR_CODE: if (value == STATUS_VALUE_ON) { statusErrorCode = true; setKeyboardLocked(true); Toolkit.getDefaultToolkit().beep(); } else { statusErrorCode = false; setKeyboardLocked(false); homePos = saveHomePos; saveHomePos = 0; pendingInsert = false; } break; } updateImage(sArea.getBounds()); }
|
public void setStatus(byte attr,byte value,String s) { statusString = s; // draw the status information bi.setStatus(attr,value,s, fmWidth, fmHeight, lm, font, colorBg, colorRed, colorWhite); // set environment variables switch (attr) { case STATUS_SYSTEM: if (value == STATUS_VALUE_ON) { statusXSystem =true; } else statusXSystem = false; break; case STATUS_ERROR_CODE: if (value == STATUS_VALUE_ON) { statusErrorCode = true; setKeyboardLocked(true); Toolkit.getDefaultToolkit().beep(); } else { statusErrorCode = false; setKeyboardLocked(false); homePos = saveHomePos; saveHomePos = 0; pendingInsert = false; } break; } updateImage(sArea.getBounds()); }
| 6,092
|
protected boolean simulateKeyStroke(char c){ if (isStatusErrorCode() && !Character.isISOControl(c) && !keyProcessed) { restoreErrorLine(); setStatus(STATUS_ERROR_CODE,STATUS_VALUE_OFF,null); } boolean updateField = false; boolean numericError = false; boolean updatePos = false; boolean autoEnter = false; if (!Character.isISOControl(c)) { if (screenFields.getCurrentField() != null && screenFields.withinCurrentField(lastPos) && !screenFields.isCurrentFieldBypassField()) { switch (screenFields.getCurrentFieldShift()) { case 0: // Alpha shift case 2: // Numeric Shift case 4: // Kakana Shift updateField = true; break; case 1: // Alpha Only if(Character.isLetter(c) || c == ',' || c == '-' || c == '.' || c == ' ') updateField = true; break; case 3: // Numeric only if(Character.isDigit(c) || c == '+' || c == ',' || c == '-' || c == '.' || c == ' ') updateField = true; else numericError = true; break; case 5: // Digits only if(Character.isDigit(c)) updateField = true; else displayError(ERR_NUMERIC_09); break; case 7: // Signed numeric if(Character.isDigit(c) || c == '+' || c == '-') if (lastPos == screenFields.getCurrentField().endPos() && (c != '+' && c != '-')) displayError(ERR_INVALID_SIGN); else updateField = true; else displayError(ERR_NUMERIC_09); break; } if (updateField) { if (screenFields.isCurrentFieldToUpper()) c = Character.toUpperCase(c); setCursorOff(); updatePos = true; resetDirty(lastPos); if (insertMode) { if (endOfField(false) != screenFields.getCurrentField().endPos()) shiftRight(lastPos); else { displayError(ERR_NO_ROOM_INSERT); updatePos = false; } } if (updatePos) { screenFields.getCurrentField().getKeyPos(getRow(lastPos),getCol(lastPos)); screenFields.getCurrentField().changePos(1); screen[lastPos].setChar(c); screenFields.setCurrentFieldMDT(); // if we have gone passed the end of the field then goto the next field if (!screenFields.withinCurrentField(screenFields.getCurrentFieldPos())) { if (screenFields.isCurrentFieldAutoEnter()) { autoEnter = true; } else if (!screenFields.isCurrentFieldFER()) gotoFieldNext(); } else goto_XY(screenFields.getCurrentField().getCursorRow() + 1,screenFields.getCurrentField().getCursorCol() + 1); } updateImage(dirty); setCursorOn(); if (autoEnter) sendAid(AID_ENTER); } else { if (numericError) { displayError(ERR_NUMERIC_ONLY); } } } else { displayError(ERR_CURSOR_PROTECTED); } } return updatePos; }
|
protected boolean simulateKeyStroke(char c){ if (isStatusErrorCode() && !Character.isISOControl(c) && !keyProcessed) { restoreErrorLine(); setStatus(STATUS_ERROR_CODE,STATUS_VALUE_OFF,null); } boolean updateField = false; boolean numericError = false; boolean updatePos = false; boolean autoEnter = false; if (!Character.isISOControl(c)) { if (screenFields.getCurrentField() != null && screenFields.withinCurrentField(lastPos) && !screenFields.isCurrentFieldBypassField()) { switch (screenFields.getCurrentFieldShift()) { case 0: // Alpha shift case 2: // Numeric Shift case 4: // Kakana Shift updateField = true; break; case 1: // Alpha Only if(Character.isLetter(c) || c == ',' || c == '-' || c == '.' || c == ' ') updateField = true; break; case 3: // Numeric only if(Character.isDigit(c) || c == '+' || c == ',' || c == '-' || c == '.' || c == ' ') updateField = true; else numericError = true; break; case 5: // Digits only if(Character.isDigit(c)) updateField = true; else displayError(ERR_NUMERIC_09); break; case 7: // Signed numeric if(Character.isDigit(c) || c == '+' || c == '-') if (lastPos == screenFields.getCurrentField().endPos() && (c != '+' && c != '-')) displayError(ERR_INVALID_SIGN); else updateField = true; else displayError(ERR_NUMERIC_09); break; } if (updateField) { if (screenFields.isCurrentFieldToUpper()) c = Character.toUpperCase(c); setCursorOff(); updatePos = true; resetDirty(lastPos); if (insertMode) { if (endOfField(false) != screenFields.getCurrentField().endPos()) shiftRight(lastPos); else { displayError(ERR_NO_ROOM_INSERT); updatePos = false; } } if (updatePos) { screenFields.getCurrentField().getKeyPos(getRow(lastPos),getCol(lastPos)); screenFields.getCurrentField().changePos(1); screen[lastPos].setChar(c); screenFields.setCurrentFieldMDT(); // if we have gone passed the end of the field then goto the next field if (!screenFields.withinCurrentField(screenFields.getCurrentFieldPos())) { if (screenFields.isCurrentFieldAutoEnter()) { autoEnter = true; } else if (!screenFields.isCurrentFieldFER()) gotoFieldNext(); } else goto_XY(screenFields.getCurrentField().getCursorRow() + 1,screenFields.getCurrentField().getCursorCol() + 1); } updateImage(dirty); setCursorOn(); if (autoEnter) sendAid(AID_ENTER); } else { if (numericError) { displayError(ERR_NUMERIC_ONLY); } } } else { displayError(ERR_CURSOR_PROTECTED); } } return updatePos; }
| 6,093
|
boolean isSyntetic() { return (flags & SYNTETIC) != 0; }
|
boolean isSyntetic() { return (flags & SYNTETIC) != 0; }
| 6,094
|
public final void printMe() { Thread printerThread = new PrinterThread(planes.screen, font, numCols, numRows, colorBg, defaultPrinter, (Session) gui); printerThread.start(); }
|
public final void printMe() { Thread printerThread = new PrinterThread(this, font, numCols, numRows, colorBg, defaultPrinter, (Session) gui); printerThread.start(); }
| 6,096
|
private boolean getMbrSize(String member) { boolean flag = true; if(ftpOutputStream == null) { printFTPInfo("Not connected to any server!"); return false; } if(!loggedIn) { printFTPInfo("Login was not successful! Aborting!"); return false; } Socket socket = null; DataInputStream datainputstream = null; executeCommand("TYPE","I"); String remoteFile = "QTEMP/FML"; members = new Vector(10); boolean foundMbr = false; try { socket = createPassiveSocket("RETR " + remoteFile); if(socket != null) { datainputstream = new DataInputStream(socket.getInputStream()); byte abyte0[] = new byte[858]; int c = 0; int kj = 0; int len = 0; StringBuffer sb = new StringBuffer(10); printFTPInfo("<----------------- Member Information ---------------->"); for(int j = 0; j != -1 && !aborted;) { j = datainputstream.read(); if(j == -1) break; c ++; abyte0[len++] = (byte)j; if (len == abyte0.length) { sb.setLength(0); // the offset for member name MBNAME is 164 with offset of 1 but // we have to offset the buffer by 0 which makes it 164 - 1 // or 163 for (int f = 0;f < 10; f++) { sb.append(vt.getASCIIChar(abyte0[163 + f] & 0xff)); } printFTPInfo(sb + " " + packed2int(abyte0,345,5)); members.add(new MemberInfo(sb.toString(),packed2int(abyte0,345,5)));// if (member == null && fileSize == 0) {// // get current number of records// fileSize = packed2int(abyte0,345,5);// status.setFileLength(fileSize);// member = sb.toString();// break;// }// else {// if (sb.toString().equalsIgnoreCase(member)) {// // get current number of records// fileSize = packed2int(abyte0,345,5);// status.setFileLength(fileSize);//// }// else {// fileSize = packed2int(abyte0,345,5);// status.setFileLength(fileSize);// }// } len =0; } } printFTPInfo("Member list Transfer complete!"); } else flag = false; } catch(Exception _ex) { printFTPInfo("Error! " + _ex); return false; } finally { try { socket.close(); } catch(Exception _ex) { } try { datainputstream.close(); } catch(Exception _ex) { } } parseResponse(); return flag; }
|
private boolean getMbrSize(String member) { boolean flag = true; if(ftpOutputStream == null) { printFTPInfo("Not connected to any server!"); return false; } if(!loggedIn) { printFTPInfo("Login was not successful! Aborting!"); return false; } Socket socket = null; DataInputStream datainputstream = null; executeCommand("TYPE","I"); String remoteFile = "QTEMP/FML"; members = new Vector(10); boolean foundMbr = false; try { socket = createPassiveSocket("RETR " + remoteFile); if(socket != null) { datainputstream = new DataInputStream(socket.getInputStream()); byte abyte0[] = new byte[858]; int c = 0; int kj = 0; int len = 0; StringBuffer sb = new StringBuffer(10); printFTPInfo("<----------------- Member Information ---------------->"); for(int j = 0; j != -1 && !aborted;) { j = datainputstream.read(); if(j == -1) break; c ++; abyte0[len++] = (byte)j; if (len == abyte0.length) { sb.setLength(0); // the offset for member name MBNAME is 164 with offset of 1 but // we have to offset the buffer by 0 which makes it 164 - 1 // or 163 for (int f = 0;f < 10; f++) { sb.append(vt.ebcdic2uni(abyte0[163 + f] & 0xff)); } printFTPInfo(sb + " " + packed2int(abyte0,345,5)); members.add(new MemberInfo(sb.toString(),packed2int(abyte0,345,5)));// if (member == null && fileSize == 0) {// // get current number of records// fileSize = packed2int(abyte0,345,5);// status.setFileLength(fileSize);// member = sb.toString();// break;// }// else {// if (sb.toString().equalsIgnoreCase(member)) {// // get current number of records// fileSize = packed2int(abyte0,345,5);// status.setFileLength(fileSize);//// }// else {// fileSize = packed2int(abyte0,345,5);// status.setFileLength(fileSize);// }// } len =0; } } printFTPInfo("Member list Transfer complete!"); } else flag = false; } catch(Exception _ex) { printFTPInfo("Error! " + _ex); return false; } finally { try { socket.close(); } catch(Exception _ex) { } try { datainputstream.close(); } catch(Exception _ex) { } } parseResponse(); return flag; }
| 6,097
|
public XDF getOwner (XDF obj) { return owner; }
|
public XDF getOwner () { return owner; }
| 6,098
|
public void paintIcon(Component c, Graphics g, int x, int y) { boolean enabled = false; boolean focus = false; if (c != null) { enabled = c.isEnabled(); focus = c.hasFocus(); } // draw the outline if (enabled) g.setColor(MetalLookAndFeel.getBlack()); else g.setColor(MetalLookAndFeel.getControlDarkShadow()); g.drawLine(x + 1, y, x + 13, y); g.drawLine(x + 14, y + 1, x + 14, y + 7); g.drawLine(x + 14, y + 8, x + 7, y + 15); g.drawLine(x + 6, y + 14, x, y + 8); g.drawLine(x, y + 7, x, y + 1); // fill the icon if (focus) g.setColor(MetalLookAndFeel.getPrimaryControlShadow()); else g.setColor(MetalLookAndFeel.getControl()); g.fillRect(x + 1, y + 2, 13, 7); g.drawLine(x + 2, y + 9, x + 12, y + 9); g.drawLine(x + 3, y + 10, x + 11, y + 10); g.drawLine(x + 4, y + 11, x + 10, y + 11); g.drawLine(x + 5, y + 12, x + 9, y + 12); g.drawLine(x + 6, y + 13, x + 8, y + 13); g.drawLine(x + 7, y + 14, x + 7, y + 14); // if the slider is enabled, draw dots and highlights if (c.isEnabled()) { if (focus) g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); else g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 3, y + 3, x + 3, y + 3); g.drawLine(x + 7, y + 3, x + 7, y + 3); g.drawLine(x + 11, y + 3, x + 11, y + 3); g.drawLine(x + 5, y + 5, x + 5, y + 5); g.drawLine(x + 9, y + 5, x + 9, y + 5); g.drawLine(x + 3, y + 7, x + 3, y + 7); g.drawLine(x + 7, y + 7, x + 7, y + 7); g.drawLine(x + 11, y + 7, x + 11, y + 7); // draw highlights if (focus) g.setColor(MetalLookAndFeel.getPrimaryControl()); else g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 8); g.drawLine(x + 2, y + 2, x + 2, y + 2); g.drawLine(x + 6, y + 2, x + 6, y + 2); g.drawLine(x + 10, y + 2, x + 10, y + 2); g.drawLine(x + 4, y + 4, x + 4, y + 4); g.drawLine(x + 8, y + 4, x + 8, y + 4); g.drawLine(x + 2, y + 6, x + 2, y + 6); g.drawLine(x + 6, y + 6, x + 6, y + 6); g.drawLine(x + 10, y + 6, x + 10, y + 6); } }
|
public void paintIcon(Component c, Graphics g, int x, int y) { boolean enabled = false; boolean focus = false; if (c != null) { enabled = c.isEnabled(); focus = c.hasFocus(); } // draw the outline if (enabled) g.setColor(MetalLookAndFeel.getBlack()); else g.setColor(MetalLookAndFeel.getControlDarkShadow()); g.drawLine(x + 1, y, x + 13, y); g.drawLine(x + 14, y + 1, x + 14, y + 7); g.drawLine(x + 14, y + 8, x + 7, y + 15); g.drawLine(x + 6, y + 14, x, y + 8); g.drawLine(x, y + 7, x, y + 1); // fill the icon if (focus) g.setColor(MetalLookAndFeel.getPrimaryControlShadow()); else g.setColor(MetalLookAndFeel.getControl()); g.fillRect(x + 1, y + 2, 13, 7); g.drawLine(x + 2, y + 9, x + 12, y + 9); g.drawLine(x + 3, y + 10, x + 11, y + 10); g.drawLine(x + 4, y + 11, x + 10, y + 11); g.drawLine(x + 5, y + 12, x + 9, y + 12); g.drawLine(x + 6, y + 13, x + 8, y + 13); g.drawLine(x + 7, y + 14, x + 7, y + 14); // if the slider is enabled, draw dots and highlights if (c.isEnabled()) { if (focus) g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); else g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 3, y + 3, x + 3, y + 3); g.drawLine(x + 7, y + 3, x + 7, y + 3); g.drawLine(x + 11, y + 3, x + 11, y + 3); g.drawLine(x + 5, y + 5, x + 5, y + 5); g.drawLine(x + 9, y + 5, x + 9, y + 5); g.drawLine(x + 3, y + 7, x + 3, y + 7); g.drawLine(x + 7, y + 7, x + 7, y + 7); g.drawLine(x + 11, y + 7, x + 11, y + 7); // draw highlights if (focus) g.setColor(MetalLookAndFeel.getPrimaryControl()); else g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 8); g.drawLine(x + 2, y + 2, x + 2, y + 2); g.drawLine(x + 6, y + 2, x + 6, y + 2); g.drawLine(x + 10, y + 2, x + 10, y + 2); g.drawLine(x + 4, y + 4, x + 4, y + 4); g.drawLine(x + 8, y + 4, x + 8, y + 4); g.drawLine(x + 2, y + 6, x + 2, y + 6); g.drawLine(x + 6, y + 6, x + 6, y + 6); g.drawLine(x + 10, y + 6, x + 10, y + 6); } }
| 6,099
|
public void paintIcon(Component c, Graphics g, int x, int y) { boolean enabled = false; boolean focus = false; if (c != null) { enabled = c.isEnabled(); focus = c.hasFocus(); } // draw the outline if (enabled) g.setColor(MetalLookAndFeel.getBlack()); else g.setColor(MetalLookAndFeel.getControlDarkShadow()); g.drawLine(x + 1, y, x + 13, y); g.drawLine(x + 14, y + 1, x + 14, y + 7); g.drawLine(x + 14, y + 8, x + 7, y + 15); g.drawLine(x + 6, y + 14, x, y + 8); g.drawLine(x, y + 7, x, y + 1); // fill the icon if (focus) g.setColor(MetalLookAndFeel.getPrimaryControlShadow()); else g.setColor(MetalLookAndFeel.getControl()); g.fillRect(x + 1, y + 2, 13, 7); g.drawLine(x + 2, y + 9, x + 12, y + 9); g.drawLine(x + 3, y + 10, x + 11, y + 10); g.drawLine(x + 4, y + 11, x + 10, y + 11); g.drawLine(x + 5, y + 12, x + 9, y + 12); g.drawLine(x + 6, y + 13, x + 8, y + 13); g.drawLine(x + 7, y + 14, x + 7, y + 14); // if the slider is enabled, draw dots and highlights if (c.isEnabled()) { if (focus) g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); else g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 3, y + 3, x + 3, y + 3); g.drawLine(x + 7, y + 3, x + 7, y + 3); g.drawLine(x + 11, y + 3, x + 11, y + 3); g.drawLine(x + 5, y + 5, x + 5, y + 5); g.drawLine(x + 9, y + 5, x + 9, y + 5); g.drawLine(x + 3, y + 7, x + 3, y + 7); g.drawLine(x + 7, y + 7, x + 7, y + 7); g.drawLine(x + 11, y + 7, x + 11, y + 7); // draw highlights if (focus) g.setColor(MetalLookAndFeel.getPrimaryControl()); else g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 8); g.drawLine(x + 2, y + 2, x + 2, y + 2); g.drawLine(x + 6, y + 2, x + 6, y + 2); g.drawLine(x + 10, y + 2, x + 10, y + 2); g.drawLine(x + 4, y + 4, x + 4, y + 4); g.drawLine(x + 8, y + 4, x + 8, y + 4); g.drawLine(x + 2, y + 6, x + 2, y + 6); g.drawLine(x + 6, y + 6, x + 6, y + 6); g.drawLine(x + 10, y + 6, x + 10, y + 6); } }
|
public void paintIcon(Component c, Graphics g, int x, int y) { boolean enabled = false; boolean focus = false; if (c != null) { enabled = c.isEnabled(); focus = c.hasFocus(); } // draw the outline if (enabled) g.setColor(MetalLookAndFeel.getBlack()); else g.setColor(MetalLookAndFeel.getControlDarkShadow()); g.drawLine(x + 1, y, x + 13, y); g.drawLine(x + 14, y + 1, x + 14, y + 7); g.drawLine(x + 14, y + 8, x + 7, y + 15); g.drawLine(x + 6, y + 14, x, y + 8); g.drawLine(x, y + 7, x, y + 1); // fill the icon if (focus) g.setColor(MetalLookAndFeel.getPrimaryControlShadow()); else g.setColor(MetalLookAndFeel.getControl()); g.fillRect(x + 1, y + 2, 13, 7); g.drawLine(x + 2, y + 9, x + 12, y + 9); g.drawLine(x + 3, y + 10, x + 11, y + 10); g.drawLine(x + 4, y + 11, x + 10, y + 11); g.drawLine(x + 5, y + 12, x + 9, y + 12); g.drawLine(x + 6, y + 13, x + 8, y + 13); g.drawLine(x + 7, y + 14, x + 7, y + 14); // if the slider is enabled, draw dots and highlights if (c.isEnabled()) { if (focus) g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); else g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 3, y + 3, x + 3, y + 3); g.drawLine(x + 7, y + 3, x + 7, y + 3); g.drawLine(x + 11, y + 3, x + 11, y + 3); g.drawLine(x + 5, y + 5, x + 5, y + 5); g.drawLine(x + 9, y + 5, x + 9, y + 5); g.drawLine(x + 3, y + 7, x + 3, y + 7); g.drawLine(x + 7, y + 7, x + 7, y + 7); g.drawLine(x + 11, y + 7, x + 11, y + 7); // draw highlights if (focus) g.setColor(MetalLookAndFeel.getPrimaryControl()); else g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 8); g.drawLine(x + 2, y + 2, x + 2, y + 2); g.drawLine(x + 6, y + 2, x + 6, y + 2); g.drawLine(x + 10, y + 2, x + 10, y + 2); g.drawLine(x + 4, y + 4, x + 4, y + 4); g.drawLine(x + 8, y + 4, x + 8, y + 4); g.drawLine(x + 2, y + 6, x + 2, y + 6); g.drawLine(x + 6, y + 6, x + 6, y + 6); g.drawLine(x + 10, y + 6, x + 10, y + 6); } }
| 6,100
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 12, y + 1, x + 13, y + 1); g.drawLine(x + 11, y + 2, x + 12, y + 2); g.drawLine(x + 10, y + 3, x + 11, y + 3); g.drawLine(x + 8, y + 2, x + 8, y + 3); g.fillRect(x + 8, y + 4, 3, 3); g.drawLine(x + 11, y + 6, x + 12, y + 6); g.drawLine(x + 1, y + 5, x + 5, y + 5); g.drawLine(x + 1, y + 6, x + 1, y + 12); g.drawLine(x + 9, y + 9, x + 9, y + 12); g.drawLine(x + 1, y + 13, x + 9, y + 13); g.drawLine(x + 2, y + 12, x + 2, y + 12); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 12, y, x + 9, y + 3); g.drawLine(x + 7, y + 1, x + 8, y + 1); g.drawLine(x + 7, y + 2, x + 7, y + 6); g.drawLine(x + 11, y + 5, x + 12, y + 5); g.drawLine(x, y + 4, x + 5, y + 4); g.drawLine(x, y + 5, x, y + 13); g.drawLine(x + 3, y + 12, x + 8, y + 12); g.drawLine(x + 8, y + 8, x + 8, y + 11); g.drawLine(x + 9, y + 8, x + 9, y + 8); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 13, y + 2); g.drawLine(x + 13, y + 6, x + 13, y + 6); g.drawLine(x + 8, y + 7, x + 13, y + 7); g.drawLine(x + 6, y + 5, x + 6, y + 5); g.drawLine(x + 2, y + 6, x + 6, y + 6); g.drawLine(x + 2, y + 6, x + 2, y + 11); g.drawLine(x + 10, y + 8, x + 10, y + 13); g.drawLine(x + 1, y + 14, x + 10, y + 14); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 12, y + 1, x + 13, y + 1); g.drawLine(x + 11, y + 2, x + 12, y + 2); g.drawLine(x + 10, y + 3, x + 11, y + 3); g.drawLine(x + 8, y + 2, x + 8, y + 3); g.fillRect(x + 8, y + 4, 3, 3); g.drawLine(x + 11, y + 6, x + 12, y + 6); g.drawLine(x + 1, y + 5, x + 5, y + 5); g.drawLine(x + 1, y + 6, x + 1, y + 12); g.drawLine(x + 9, y + 9, x + 9, y + 12); g.drawLine(x + 1, y + 13, x + 9, y + 13); g.drawLine(x + 2, y + 12, x + 2, y + 12); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 12, y, x + 9, y + 3); g.drawLine(x + 7, y + 1, x + 8, y + 1); g.drawLine(x + 7, y + 2, x + 7, y + 6); g.drawLine(x + 11, y + 5, x + 12, y + 5); g.drawLine(x, y + 4, x + 5, y + 4); g.drawLine(x, y + 5, x, y + 13); g.drawLine(x + 3, y + 12, x + 8, y + 12); g.drawLine(x + 8, y + 8, x + 8, y + 11); g.drawLine(x + 9, y + 8, x + 9, y + 8); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 13, y + 2); g.drawLine(x + 13, y + 6, x + 13, y + 6); g.drawLine(x + 8, y + 7, x + 13, y + 7); g.drawLine(x + 6, y + 5, x + 6, y + 5); g.drawLine(x + 2, y + 6, x + 6, y + 6); g.drawLine(x + 2, y + 6, x + 2, y + 11); g.drawLine(x + 10, y + 8, x + 10, y + 13); g.drawLine(x + 1, y + 14, x + 10, y + 14); }
| 6,101
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 12, y + 1, x + 13, y + 1); g.drawLine(x + 11, y + 2, x + 12, y + 2); g.drawLine(x + 10, y + 3, x + 11, y + 3); g.drawLine(x + 8, y + 2, x + 8, y + 3); g.fillRect(x + 8, y + 4, 3, 3); g.drawLine(x + 11, y + 6, x + 12, y + 6); g.drawLine(x + 1, y + 5, x + 5, y + 5); g.drawLine(x + 1, y + 6, x + 1, y + 12); g.drawLine(x + 9, y + 9, x + 9, y + 12); g.drawLine(x + 1, y + 13, x + 9, y + 13); g.drawLine(x + 2, y + 12, x + 2, y + 12); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 12, y, x + 9, y + 3); g.drawLine(x + 7, y + 1, x + 8, y + 1); g.drawLine(x + 7, y + 2, x + 7, y + 6); g.drawLine(x + 11, y + 5, x + 12, y + 5); g.drawLine(x, y + 4, x + 5, y + 4); g.drawLine(x, y + 5, x, y + 13); g.drawLine(x + 3, y + 12, x + 8, y + 12); g.drawLine(x + 8, y + 8, x + 8, y + 11); g.drawLine(x + 9, y + 8, x + 9, y + 8); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 13, y + 2); g.drawLine(x + 13, y + 6, x + 13, y + 6); g.drawLine(x + 8, y + 7, x + 13, y + 7); g.drawLine(x + 6, y + 5, x + 6, y + 5); g.drawLine(x + 2, y + 6, x + 6, y + 6); g.drawLine(x + 2, y + 6, x + 2, y + 11); g.drawLine(x + 10, y + 8, x + 10, y + 13); g.drawLine(x + 1, y + 14, x + 10, y + 14); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 12, y + 1, x + 13, y + 1); g.drawLine(x + 11, y + 2, x + 12, y + 2); g.drawLine(x + 10, y + 3, x + 11, y + 3); g.drawLine(x + 8, y + 2, x + 8, y + 3); g.fillRect(x + 8, y + 4, 3, 3); g.drawLine(x + 11, y + 6, x + 12, y + 6); g.drawLine(x + 1, y + 5, x + 5, y + 5); g.drawLine(x + 1, y + 6, x + 1, y + 12); g.drawLine(x + 9, y + 9, x + 9, y + 12); g.drawLine(x + 1, y + 13, x + 9, y + 13); g.drawLine(x + 2, y + 12, x + 2, y + 12); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 12, y, x + 9, y + 3); g.drawLine(x + 7, y + 1, x + 8, y + 1); g.drawLine(x + 7, y + 2, x + 7, y + 6); g.drawLine(x + 11, y + 5, x + 12, y + 5); g.drawLine(x, y + 4, x + 5, y + 4); g.drawLine(x, y + 5, x, y + 13); g.drawLine(x + 3, y + 12, x + 8, y + 12); g.drawLine(x + 8, y + 8, x + 8, y + 11); g.drawLine(x + 9, y + 8, x + 9, y + 8); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 13, y + 2); g.drawLine(x + 13, y + 6, x + 13, y + 6); g.drawLine(x + 8, y + 7, x + 13, y + 7); g.drawLine(x + 6, y + 5, x + 6, y + 5); g.drawLine(x + 2, y + 6, x + 6, y + 6); g.drawLine(x + 2, y + 6, x + 2, y + 11); g.drawLine(x + 10, y + 8, x + 10, y + 13); g.drawLine(x + 1, y + 14, x + 10, y + 14); }
| 6,102
|
public void paintIcon(Component c, Graphics g, int x, int y) { // draw the gray areas first g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 12); g.drawLine(x + 1, y + 13, x + 13, y + 13); g.drawLine(x + 13, y + 2, x + 13, y + 12); g.fillRect(x + 4, y + 4, 2, 2); g.fillRect(x + 4, y + 9, 2, 2); g.fillRect(x + 9, y + 4, 2, 2); g.fillRect(x + 9, y + 9, 2, 2); g.fillRect(x + 5, y + 5, 5, 5); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x, y, x + 13, y); g.drawLine(x, y + 1, x, y + 13); g.drawLine(x + 3, y + 4, x + 4, y + 3); g.drawLine(x + 3, y + 9, x + 5, y + 7); g.drawLine(x + 7, y + 5, x + 9, y + 3); g.drawLine(x + 12, y + 3, x + 12, y + 11); g.drawLine(x + 3, y + 12, x + 12, y + 12); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 14, x + 14, y + 14); g.drawLine(x + 14, y + 1, x + 14, y + 14); g.drawLine(x + 5, y + 10, x + 5, y + 10); g.drawLine(x + 6, y + 9, x + 7, y + 9); g.drawLine(x + 10, y + 5, x + 10, y + 5); g.drawLine(x + 9, y + 6, x + 9, y + 7); g.drawLine(x + 10, y + 10, x + 11, y + 10); g.drawLine(x + 10, y + 11, x + 10, y + 11); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { // draw the gray areas first Color savedColor = g.getColor(); AbstractButton b = (AbstractButton) c; if (b.getModel().isPressed()) g.setColor(MetalLookAndFeel.getPrimaryControlShadow()); else g.setColor(MetalLookAndFeel.getPrimaryControl()); g.fillRect(x + 2, y + 2, 10, 10); if (b.getModel().isPressed()) g.setColor(MetalLookAndFeel.getBlack()); else { boolean selected = true; if (selected) g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); else g.setColor(MetalLookAndFeel.getControlDarkShadow()); } g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 12); g.drawLine(x + 1, y + 13, x + 13, y + 13); g.drawLine(x + 13, y + 2, x + 13, y + 12); g.fillRect(x + 4, y + 4, 2, 2); g.fillRect(x + 4, y + 9, 2, 2); g.fillRect(x + 9, y + 4, 2, 2); g.fillRect(x + 9, y + 9, 2, 2); g.fillRect(x + 5, y + 5, 5, 5); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x, y, x + 13, y); g.drawLine(x, y + 1, x, y + 13); g.drawLine(x + 3, y + 4, x + 4, y + 3); g.drawLine(x + 3, y + 9, x + 5, y + 7); g.drawLine(x + 7, y + 5, x + 9, y + 3); g.drawLine(x + 12, y + 3, x + 12, y + 11); g.drawLine(x + 3, y + 12, x + 12, y + 12); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 14, x + 14, y + 14); g.drawLine(x + 14, y + 1, x + 14, y + 14); g.drawLine(x + 5, y + 10, x + 5, y + 10); g.drawLine(x + 6, y + 9, x + 7, y + 9); g.drawLine(x + 10, y + 5, x + 10, y + 5); g.drawLine(x + 9, y + 6, x + 9, y + 7); g.drawLine(x + 10, y + 10, x + 11, y + 10); g.drawLine(x + 10, y + 11, x + 10, y + 11); }
| 6,104
|
public void paintIcon(Component c, Graphics g, int x, int y) { // draw the gray areas first g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 12); g.drawLine(x + 1, y + 13, x + 13, y + 13); g.drawLine(x + 13, y + 2, x + 13, y + 12); g.fillRect(x + 4, y + 4, 2, 2); g.fillRect(x + 4, y + 9, 2, 2); g.fillRect(x + 9, y + 4, 2, 2); g.fillRect(x + 9, y + 9, 2, 2); g.fillRect(x + 5, y + 5, 5, 5); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x, y, x + 13, y); g.drawLine(x, y + 1, x, y + 13); g.drawLine(x + 3, y + 4, x + 4, y + 3); g.drawLine(x + 3, y + 9, x + 5, y + 7); g.drawLine(x + 7, y + 5, x + 9, y + 3); g.drawLine(x + 12, y + 3, x + 12, y + 11); g.drawLine(x + 3, y + 12, x + 12, y + 12); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 14, x + 14, y + 14); g.drawLine(x + 14, y + 1, x + 14, y + 14); g.drawLine(x + 5, y + 10, x + 5, y + 10); g.drawLine(x + 6, y + 9, x + 7, y + 9); g.drawLine(x + 10, y + 5, x + 10, y + 5); g.drawLine(x + 9, y + 6, x + 9, y + 7); g.drawLine(x + 10, y + 10, x + 11, y + 10); g.drawLine(x + 10, y + 11, x + 10, y + 11); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { // draw the gray areas first g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 12); g.drawLine(x + 1, y + 13, x + 13, y + 13); g.drawLine(x + 13, y + 2, x + 13, y + 12); g.fillRect(x + 4, y + 4, 2, 2); g.fillRect(x + 4, y + 9, 2, 2); g.fillRect(x + 9, y + 4, 2, 2); g.fillRect(x + 9, y + 9, 2, 2); g.fillRect(x + 5, y + 5, 5, 5); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x, y, x + 13, y); g.drawLine(x, y + 1, x, y + 13); g.drawLine(x + 3, y + 4, x + 4, y + 3); g.drawLine(x + 3, y + 9, x + 5, y + 7); g.drawLine(x + 7, y + 5, x + 9, y + 3); g.drawLine(x + 12, y + 3, x + 12, y + 11); g.drawLine(x + 3, y + 12, x + 12, y + 12); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 14, x + 14, y + 14); g.drawLine(x + 14, y + 1, x + 14, y + 14); g.drawLine(x + 5, y + 10, x + 5, y + 10); g.drawLine(x + 6, y + 9, x + 7, y + 9); g.drawLine(x + 10, y + 5, x + 10, y + 5); g.drawLine(x + 9, y + 6, x + 9, y + 7); g.drawLine(x + 10, y + 10, x + 11, y + 10); g.drawLine(x + 10, y + 11, x + 10, y + 11); }
| 6,105
|
public void paintIcon(Component c, Graphics g, int x, int y) { // draw the gray areas first g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 12); g.drawLine(x + 1, y + 13, x + 13, y + 13); g.drawLine(x + 13, y + 2, x + 13, y + 12); g.fillRect(x + 4, y + 4, 2, 2); g.fillRect(x + 4, y + 9, 2, 2); g.fillRect(x + 9, y + 4, 2, 2); g.fillRect(x + 9, y + 9, 2, 2); g.fillRect(x + 5, y + 5, 5, 5); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x, y, x + 13, y); g.drawLine(x, y + 1, x, y + 13); g.drawLine(x + 3, y + 4, x + 4, y + 3); g.drawLine(x + 3, y + 9, x + 5, y + 7); g.drawLine(x + 7, y + 5, x + 9, y + 3); g.drawLine(x + 12, y + 3, x + 12, y + 11); g.drawLine(x + 3, y + 12, x + 12, y + 12); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 14, x + 14, y + 14); g.drawLine(x + 14, y + 1, x + 14, y + 14); g.drawLine(x + 5, y + 10, x + 5, y + 10); g.drawLine(x + 6, y + 9, x + 7, y + 9); g.drawLine(x + 10, y + 5, x + 10, y + 5); g.drawLine(x + 9, y + 6, x + 9, y + 7); g.drawLine(x + 10, y + 10, x + 11, y + 10); g.drawLine(x + 10, y + 11, x + 10, y + 11); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { // draw the gray areas first g.setColor(MetalLookAndFeel.getPrimaryControlDarkShadow()); g.drawLine(x + 1, y + 1, x + 13, y + 1); g.drawLine(x + 1, y + 2, x + 1, y + 12); g.drawLine(x + 1, y + 13, x + 13, y + 13); g.drawLine(x + 13, y + 2, x + 13, y + 12); g.fillRect(x + 4, y + 4, 2, 2); g.fillRect(x + 4, y + 9, 2, 2); g.fillRect(x + 9, y + 4, 2, 2); g.fillRect(x + 9, y + 9, 2, 2); g.fillRect(x + 5, y + 5, 5, 5); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x, y, x + 13, y); g.drawLine(x, y + 1, x, y + 13); g.drawLine(x + 3, y + 4, x + 4, y + 3); g.drawLine(x + 3, y + 9, x + 5, y + 7); g.drawLine(x + 7, y + 5, x + 9, y + 3); g.drawLine(x + 12, y + 3, x + 12, y + 11); g.drawLine(x + 3, y + 12, x + 12, y + 12); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 1, y + 14, x + 14, y + 14); g.drawLine(x + 14, y + 1, x + 14, y + 14); g.drawLine(x + 5, y + 10, x + 5, y + 10); g.drawLine(x + 6, y + 9, x + 7, y + 9); g.drawLine(x + 10, y + 5, x + 10, y + 5); g.drawLine(x + 9, y + 6, x + 9, y + 7); g.drawLine(x + 10, y + 10, x + 11, y + 10); g.drawLine(x + 10, y + 11, x + 10, y + 11); }
| 6,106
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 9, y + 1, x + 10, y + 1); g.fillRect(x + 11, y + 1, 3, 3); g.fillRect(x + 12, y + 4, 2, 2); g.drawLine(x + 10, y + 3, x + 10, y + 3); g.drawLine(x + 9, y + 4, x + 10, y + 4); g.drawLine(x + 1, y + 5, x + 9, y + 5); g.drawLine(x + 1, y + 6, x + 1, y + 12); g.drawLine(x + 9, y + 6, x + 9, y + 12); g.drawLine(x + 1, y + 13, x + 9, y + 13); // fill g.drawLine(x + 7, y + 6, x + 8, y + 6); g.drawLine(x + 6, y + 7, x + 8, y + 7); g.drawLine(x + 5, y + 8, x + 6, y + 8); g.drawLine(x + 4, y + 9, x + 5, y + 9); g.drawLine(x + 3, y + 10, x + 4, y + 10); g.drawLine(x + 2, y + 11, x + 3, y + 11); g.drawLine(x + 2, y + 12, x + 4, y + 12); g.drawLine(x + 8, y + 8, x + 8, y + 8); // draw black g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 8, y, x + 13, y); g.drawLine(x + 8, y + 1, x + 8, y + 1); g.drawLine(x + 10, y + 2, x + 9, y + 3); g.drawLine(x, y + 4, x + 8, y + 4); g.drawLine(x, y + 5, x, y + 13); g.drawLine(x + 2, y + 10, x + 6, y + 6); g.drawLine(x + 8, y + 9, x + 8, y + 11); g.drawLine(x + 5, y + 12, x + 8, y + 12); // draw white g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 2, y + 6, x + 5, y + 6); g.drawLine(x + 2, y + 7, x + 2, y + 9); g.drawLine(x + 4, y + 11, x + 7, y + 8); g.drawLine(x + 1, y + 14, x + 10, y + 14); g.drawLine(x + 10, y + 5, x + 10, y + 13); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 11, y + 5); g.drawLine(x + 13, y + 6, x + 14, y + 6); g.drawLine(x + 14, y + 1, x + 14, y + 5); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 9, y + 1, x + 10, y + 1); g.fillRect(x + 11, y + 1, 3, 3); g.fillRect(x + 12, y + 4, 2, 2); g.drawLine(x + 10, y + 3, x + 10, y + 3); g.drawLine(x + 9, y + 4, x + 10, y + 4); g.drawLine(x + 1, y + 5, x + 9, y + 5); g.drawLine(x + 1, y + 6, x + 1, y + 12); g.drawLine(x + 9, y + 6, x + 9, y + 12); g.drawLine(x + 1, y + 13, x + 9, y + 13); // fill g.drawLine(x + 7, y + 6, x + 8, y + 6); g.drawLine(x + 6, y + 7, x + 8, y + 7); g.drawLine(x + 5, y + 8, x + 6, y + 8); g.drawLine(x + 4, y + 9, x + 5, y + 9); g.drawLine(x + 3, y + 10, x + 4, y + 10); g.drawLine(x + 2, y + 11, x + 3, y + 11); g.drawLine(x + 2, y + 12, x + 4, y + 12); g.drawLine(x + 8, y + 8, x + 8, y + 8); // draw black g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 8, y, x + 13, y); g.drawLine(x + 8, y + 1, x + 8, y + 1); g.drawLine(x + 10, y + 2, x + 9, y + 3); g.drawLine(x, y + 4, x + 8, y + 4); g.drawLine(x, y + 5, x, y + 13); g.drawLine(x + 2, y + 10, x + 6, y + 6); g.drawLine(x + 8, y + 9, x + 8, y + 11); g.drawLine(x + 5, y + 12, x + 8, y + 12); // draw white g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 2, y + 6, x + 5, y + 6); g.drawLine(x + 2, y + 7, x + 2, y + 9); g.drawLine(x + 4, y + 11, x + 7, y + 8); g.drawLine(x + 1, y + 14, x + 10, y + 14); g.drawLine(x + 10, y + 5, x + 10, y + 13); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 11, y + 5); g.drawLine(x + 13, y + 6, x + 14, y + 6); g.drawLine(x + 14, y + 1, x + 14, y + 5); }
| 6,107
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 9, y + 1, x + 10, y + 1); g.fillRect(x + 11, y + 1, 3, 3); g.fillRect(x + 12, y + 4, 2, 2); g.drawLine(x + 10, y + 3, x + 10, y + 3); g.drawLine(x + 9, y + 4, x + 10, y + 4); g.drawLine(x + 1, y + 5, x + 9, y + 5); g.drawLine(x + 1, y + 6, x + 1, y + 12); g.drawLine(x + 9, y + 6, x + 9, y + 12); g.drawLine(x + 1, y + 13, x + 9, y + 13); // fill g.drawLine(x + 7, y + 6, x + 8, y + 6); g.drawLine(x + 6, y + 7, x + 8, y + 7); g.drawLine(x + 5, y + 8, x + 6, y + 8); g.drawLine(x + 4, y + 9, x + 5, y + 9); g.drawLine(x + 3, y + 10, x + 4, y + 10); g.drawLine(x + 2, y + 11, x + 3, y + 11); g.drawLine(x + 2, y + 12, x + 4, y + 12); g.drawLine(x + 8, y + 8, x + 8, y + 8); // draw black g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 8, y, x + 13, y); g.drawLine(x + 8, y + 1, x + 8, y + 1); g.drawLine(x + 10, y + 2, x + 9, y + 3); g.drawLine(x, y + 4, x + 8, y + 4); g.drawLine(x, y + 5, x, y + 13); g.drawLine(x + 2, y + 10, x + 6, y + 6); g.drawLine(x + 8, y + 9, x + 8, y + 11); g.drawLine(x + 5, y + 12, x + 8, y + 12); // draw white g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 2, y + 6, x + 5, y + 6); g.drawLine(x + 2, y + 7, x + 2, y + 9); g.drawLine(x + 4, y + 11, x + 7, y + 8); g.drawLine(x + 1, y + 14, x + 10, y + 14); g.drawLine(x + 10, y + 5, x + 10, y + 13); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 11, y + 5); g.drawLine(x + 13, y + 6, x + 14, y + 6); g.drawLine(x + 14, y + 1, x + 14, y + 5); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 9, y + 1, x + 10, y + 1); g.fillRect(x + 11, y + 1, 3, 3); g.fillRect(x + 12, y + 4, 2, 2); g.drawLine(x + 10, y + 3, x + 10, y + 3); g.drawLine(x + 9, y + 4, x + 10, y + 4); g.drawLine(x + 1, y + 5, x + 9, y + 5); g.drawLine(x + 1, y + 6, x + 1, y + 12); g.drawLine(x + 9, y + 6, x + 9, y + 12); g.drawLine(x + 1, y + 13, x + 9, y + 13); // fill g.drawLine(x + 7, y + 6, x + 8, y + 6); g.drawLine(x + 6, y + 7, x + 8, y + 7); g.drawLine(x + 5, y + 8, x + 6, y + 8); g.drawLine(x + 4, y + 9, x + 5, y + 9); g.drawLine(x + 3, y + 10, x + 4, y + 10); g.drawLine(x + 2, y + 11, x + 3, y + 11); g.drawLine(x + 2, y + 12, x + 4, y + 12); g.drawLine(x + 8, y + 8, x + 8, y + 8); // draw black g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 8, y, x + 13, y); g.drawLine(x + 8, y + 1, x + 8, y + 1); g.drawLine(x + 10, y + 2, x + 9, y + 3); g.drawLine(x, y + 4, x + 8, y + 4); g.drawLine(x, y + 5, x, y + 13); g.drawLine(x + 2, y + 10, x + 6, y + 6); g.drawLine(x + 8, y + 9, x + 8, y + 11); g.drawLine(x + 5, y + 12, x + 8, y + 12); // draw white g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 2, y + 6, x + 5, y + 6); g.drawLine(x + 2, y + 7, x + 2, y + 9); g.drawLine(x + 4, y + 11, x + 7, y + 8); g.drawLine(x + 1, y + 14, x + 10, y + 14); g.drawLine(x + 10, y + 5, x + 10, y + 13); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 11, y + 5); g.drawLine(x + 13, y + 6, x + 14, y + 6); g.drawLine(x + 14, y + 1, x + 14, y + 5); }
| 6,108
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 12, y + 1, x + 13, y + 1); g.drawLine(x + 11, y + 2, x + 12, y + 2); g.drawLine(x + 10, y + 3, x + 11, y + 3); g.drawLine(x + 8, y + 2, x + 8, y + 3); g.fillRect(x + 8, y + 4, 3, 3); g.drawLine(x + 11, y + 6, x + 12, y + 6); g.drawLine(x + 1, y + 8, x + 6, y + 8); g.drawLine(x + 1, y + 9, x + 1, y + 12); g.drawLine(x + 6, y + 9, x + 6, y + 12); g.drawLine(x + 1, y + 13, x + 6, y + 13); g.drawLine(x + 5, y + 9, x + 5, y + 9); g.drawLine(x + 2, y + 12, x + 2, y + 12); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 12, y, x + 9, y + 3); g.drawLine(x + 7, y + 1, x + 8, y + 1); g.drawLine(x + 7, y + 2, x + 7, y + 6); g.drawLine(x, y + 7, x + 6, y + 7); g.drawLine(x, y + 8, x, y + 13); g.drawLine(x + 3, y + 12, x + 5, y + 12); g.drawLine(x + 5, y + 10, x + 5, y + 11); g.drawLine(x + 11, y + 5, x + 12, y + 5); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 13, y + 2); g.drawLine(x + 13, y + 6, x + 13, y + 6); g.drawLine(x + 8, y + 7, x + 13, y + 7); g.drawLine(x + 2, y + 9, x + 4, y + 9); g.drawLine(x + 2, y + 10, x + 2, y + 11); g.drawLine(x + 7, y + 9, x + 7, y + 13); g.drawLine(x + 1, y + 14, x + 7, y + 14); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 12, y + 1, x + 13, y + 1); g.drawLine(x + 11, y + 2, x + 12, y + 2); g.drawLine(x + 10, y + 3, x + 11, y + 3); g.drawLine(x + 8, y + 2, x + 8, y + 3); g.fillRect(x + 8, y + 4, 3, 3); g.drawLine(x + 11, y + 6, x + 12, y + 6); g.drawLine(x + 1, y + 8, x + 6, y + 8); g.drawLine(x + 1, y + 9, x + 1, y + 12); g.drawLine(x + 6, y + 9, x + 6, y + 12); g.drawLine(x + 1, y + 13, x + 6, y + 13); g.drawLine(x + 5, y + 9, x + 5, y + 9); g.drawLine(x + 2, y + 12, x + 2, y + 12); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 12, y, x + 9, y + 3); g.drawLine(x + 7, y + 1, x + 8, y + 1); g.drawLine(x + 7, y + 2, x + 7, y + 6); g.drawLine(x, y + 7, x + 6, y + 7); g.drawLine(x, y + 8, x, y + 13); g.drawLine(x + 3, y + 12, x + 5, y + 12); g.drawLine(x + 5, y + 10, x + 5, y + 11); g.drawLine(x + 11, y + 5, x + 12, y + 5); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 13, y + 2); g.drawLine(x + 13, y + 6, x + 13, y + 6); g.drawLine(x + 8, y + 7, x + 13, y + 7); g.drawLine(x + 2, y + 9, x + 4, y + 9); g.drawLine(x + 2, y + 10, x + 2, y + 11); g.drawLine(x + 7, y + 9, x + 7, y + 13); g.drawLine(x + 1, y + 14, x + 7, y + 14); }
| 6,110
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 12, y + 1, x + 13, y + 1); g.drawLine(x + 11, y + 2, x + 12, y + 2); g.drawLine(x + 10, y + 3, x + 11, y + 3); g.drawLine(x + 8, y + 2, x + 8, y + 3); g.fillRect(x + 8, y + 4, 3, 3); g.drawLine(x + 11, y + 6, x + 12, y + 6); g.drawLine(x + 1, y + 8, x + 6, y + 8); g.drawLine(x + 1, y + 9, x + 1, y + 12); g.drawLine(x + 6, y + 9, x + 6, y + 12); g.drawLine(x + 1, y + 13, x + 6, y + 13); g.drawLine(x + 5, y + 9, x + 5, y + 9); g.drawLine(x + 2, y + 12, x + 2, y + 12); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 12, y, x + 9, y + 3); g.drawLine(x + 7, y + 1, x + 8, y + 1); g.drawLine(x + 7, y + 2, x + 7, y + 6); g.drawLine(x, y + 7, x + 6, y + 7); g.drawLine(x, y + 8, x, y + 13); g.drawLine(x + 3, y + 12, x + 5, y + 12); g.drawLine(x + 5, y + 10, x + 5, y + 11); g.drawLine(x + 11, y + 5, x + 12, y + 5); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 13, y + 2); g.drawLine(x + 13, y + 6, x + 13, y + 6); g.drawLine(x + 8, y + 7, x + 13, y + 7); g.drawLine(x + 2, y + 9, x + 4, y + 9); g.drawLine(x + 2, y + 10, x + 2, y + 11); g.drawLine(x + 7, y + 9, x + 7, y + 13); g.drawLine(x + 1, y + 14, x + 7, y + 14); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color color = MetalLookAndFeel.getControlDarkShadow(); if (c instanceof JInternalFrame) { JInternalFrame f = (JInternalFrame) c; if (f.isSelected()) color = MetalLookAndFeel.getPrimaryControlShadow(); } g.setColor(color); g.drawLine(x + 12, y + 1, x + 13, y + 1); g.drawLine(x + 11, y + 2, x + 12, y + 2); g.drawLine(x + 10, y + 3, x + 11, y + 3); g.drawLine(x + 8, y + 2, x + 8, y + 3); g.fillRect(x + 8, y + 4, 3, 3); g.drawLine(x + 11, y + 6, x + 12, y + 6); g.drawLine(x + 1, y + 8, x + 6, y + 8); g.drawLine(x + 1, y + 9, x + 1, y + 12); g.drawLine(x + 6, y + 9, x + 6, y + 12); g.drawLine(x + 1, y + 13, x + 6, y + 13); g.drawLine(x + 5, y + 9, x + 5, y + 9); g.drawLine(x + 2, y + 12, x + 2, y + 12); g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 12, y, x + 9, y + 3); g.drawLine(x + 7, y + 1, x + 8, y + 1); g.drawLine(x + 7, y + 2, x + 7, y + 6); g.drawLine(x, y + 7, x + 6, y + 7); g.drawLine(x, y + 8, x, y + 13); g.drawLine(x + 3, y + 12, x + 5, y + 12); g.drawLine(x + 5, y + 10, x + 5, y + 11); g.drawLine(x + 11, y + 5, x + 12, y + 5); g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 9, y + 2, x + 9, y + 2); g.drawLine(x + 11, y + 4, x + 13, y + 2); g.drawLine(x + 13, y + 6, x + 13, y + 6); g.drawLine(x + 8, y + 7, x + 13, y + 7); g.drawLine(x + 2, y + 9, x + 4, y + 9); g.drawLine(x + 2, y + 10, x + 2, y + 11); g.drawLine(x + 7, y + 9, x + 7, y + 13); g.drawLine(x + 1, y + 14, x + 7, y + 14); }
| 6,111
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color savedColor = g.getColor(); JRadioButton b = (JRadioButton) c; // draw outer circle if (b.isEnabled()) g.setColor(MetalLookAndFeel.getControlDarkShadow()); else g.setColor(MetalLookAndFeel.getControlDisabled()); g.drawLine(x + 2, y + 1, x + 3, y + 1); g.drawLine(x + 4, y, x + 7, y); g.drawLine(x + 8, y + 1, x + 9, y + 1); g.drawLine(x + 10, y + 2, x + 10, y + 3); g.drawLine(x + 11, y + 4, x + 11, y + 7); g.drawLine(x + 10, y + 8, x + 10, y + 9); g.drawLine(x + 8, y + 10, x + 9, y + 10); g.drawLine(x + 4, y + 11, x + 7, y + 11); g.drawLine(x + 2, y + 10, x + 3, y + 10); g.drawLine(x + 1, y + 9, x + 1, y + 8); g.drawLine(x, y + 7, x, y + 4); g.drawLine(x + 1, y + 2, x + 1, y + 3); if (b.getModel().isArmed()) { g.setColor(MetalLookAndFeel.getControlShadow()); g.drawLine(x + 4, y + 1, x + 7, y + 1); g.drawLine(x + 4, y + 10, x + 7, y + 10); g.drawLine(x + 1, y + 4, x + 1, y + 7); g.drawLine(x + 10, y + 4, x + 10, y + 7); g.fillRect(x + 2, y + 2, 8, 8); } else { // only draw inner highlight if not filled if (b.isEnabled()) { g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 2, y + 8, x + 2, y + 9); g.drawLine(x + 1, y + 4, x + 1, y + 7); g.drawLine(x + 2, y + 2, x + 2, y + 3); g.drawLine(x + 3, y + 2, x + 3, y + 2); g.drawLine(x + 4, y + 1, x + 7, y + 1); g.drawLine(x + 8, y + 2, x + 9, y + 2); } } // draw outer highlight if (b.isEnabled()) { g.setColor(MetalLookAndFeel.getWhite()); // outer g.drawLine(x + 10, y + 1, x + 10, y + 1); g.drawLine(x + 11, y + 2, x + 11, y + 3); g.drawLine(x + 12, y + 4, x + 12, y + 7); g.drawLine(x + 11, y + 8, x + 11, y + 9); g.drawLine(x + 10, y + 10, x + 10, y + 10); g.drawLine(x + 8, y + 11, x + 9, y + 11); g.drawLine(x + 4, y + 12, x + 7, y + 12); g.drawLine(x + 2, y + 11, x + 3, y + 11); } if (b.isSelected()) { g.setColor(MetalLookAndFeel.getBlack()); g.drawLine(x + 4, y + 3, x + 7, y + 3); g.fillRect(x + 3, y + 4, 6, 4); g.drawLine(x + 4, y + 8, x + 7, y + 8); } g.setColor(savedColor); }
|
public void paintIcon(Component c, Graphics g, int x, int y) { Color savedColor = g.getColor(); JRadioButton b = (JRadioButton) c; // draw outer circle if (b.isEnabled()) g.setColor(MetalLookAndFeel.getControlDarkShadow()); else g.setColor(MetalLookAndFeel.getControlDisabled()); g.drawLine(x + 2, y + 1, x + 3, y + 1); g.drawLine(x + 4, y, x + 7, y); g.drawLine(x + 8, y + 1, x + 9, y + 1); g.drawLine(x + 10, y + 2, x + 10, y + 3); g.drawLine(x + 11, y + 4, x + 11, y + 7); g.drawLine(x + 10, y + 8, x + 10, y + 9); g.drawLine(x + 8, y + 10, x + 9, y + 10); g.drawLine(x + 4, y + 11, x + 7, y + 11); g.drawLine(x + 2, y + 10, x + 3, y + 10); g.drawLine(x + 1, y + 9, x + 1, y + 8); g.drawLine(x, y + 7, x, y + 4); g.drawLine(x + 1, y + 2, x + 1, y + 3); if (b.getModel().isArmed()) { g.setColor(MetalLookAndFeel.getControlShadow()); g.drawLine(x + 4, y + 1, x + 7, y + 1); g.drawLine(x + 4, y + 10, x + 7, y + 10); g.drawLine(x + 1, y + 4, x + 1, y + 7); g.drawLine(x + 10, y + 4, x + 10, y + 7); g.fillRect(x + 2, y + 2, 8, 8); } else { // only draw inner highlight if not filled if (b.isEnabled()) { g.setColor(MetalLookAndFeel.getWhite()); g.drawLine(x + 2, y + 8, x + 2, y + 9); g.drawLine(x + 1, y + 4, x + 1, y + 7); g.drawLine(x + 2, y + 2, x + 2, y + 3); g.drawLine(x + 3, y + 2, x + 3, y + 2); g.drawLine(x + 4, y + 1, x + 7, y + 1); g.drawLine(x + 8, y + 2, x + 9, y + 2); } } // draw outer highlight if (b.isEnabled()) { g.setColor(MetalLookAndFeel.getWhite()); // outer g.drawLine(x + 10, y + 1, x + 10, y + 1); g.drawLine(x + 11, y + 2, x + 11, y + 3); g.drawLine(x + 12, y + 4, x + 12, y + 7); g.drawLine(x + 11, y + 8, x + 11, y + 9); g.drawLine(x + 10, y + 10, x + 10, y + 10); g.drawLine(x + 8, y + 11, x + 9, y + 11); g.drawLine(x + 4, y + 12, x + 7, y + 12); g.drawLine(x + 2, y + 11, x + 3, y + 11); } if (b.isSelected()) { if (b.isEnabled()) g.setColor(MetalLookAndFeel.getBlack()); else g.setColor(MetalLookAndFeel.getControlDisabled()); g.drawLine(x + 4, y + 3, x + 7, y + 3); g.fillRect(x + 3, y + 4, 6, 4); g.drawLine(x + 4, y + 8, x + 7, y + 8); } g.setColor(savedColor); }
| 6,113
|
protected JDialog createDialog(Component parent) throws HeadlessException { Frame toUse = (Frame) SwingUtilities.getAncestorOfClass(Frame.class, parent); if (toUse == null) toUse = SwingUtilities.getOwnerFrame(); JDialog dialog = new JDialog(toUse); setSelectedFile(null); dialog.getContentPane().add(this); dialog.setModal(true); dialog.invalidate(); dialog.repaint(); return dialog; }
|
protected JDialog createDialog(Component parent) throws HeadlessException { Frame toUse = (Frame) SwingUtilities.getAncestorOfClass(Frame.class, parent); if (toUse == null) toUse = (Frame) SwingUtilities.getOwnerFrame(null); JDialog dialog = new JDialog(toUse); setSelectedFile(null); dialog.getContentPane().add(this); dialog.setModal(true); dialog.invalidate(); dialog.repaint(); return dialog; }
| 6,114
|
public int showDialog(Component parent, String approveButtonText) throws HeadlessException { JDialog d = createDialog(parent); setApproveButtonText(approveButtonText); setDialogType(CUSTOM_DIALOG); retval = ERROR_OPTION; Insets i = d.getInsets(); d.setSize(500 + i.top + i.bottom, d.getPreferredSize().height); d.show(); return retval; }
|
public int showDialog(Component parent, String approveButtonText) throws HeadlessException { JDialog d = createDialog(parent); setApproveButtonText(approveButtonText); setDialogType(CUSTOM_DIALOG); retval = ERROR_OPTION; Insets i = d.getInsets(); d.setSize(500 + i.top + i.bottom, d.getPreferredSize().height); d.show(); return retval; }
| 6,115
|
public int showOpenDialog(Component parent) throws HeadlessException { JDialog d = createDialog(parent); // FIXME: Remove when we get ancestor property d.setTitle("Open"); setDialogType(OPEN_DIALOG); retval = ERROR_OPTION; Insets i = d.getInsets(); d.setSize(500 + i.top + i.bottom, d.getPreferredSize().height); d.show(); return retval; }
|
public int showOpenDialog(Component parent) throws HeadlessException { JDialog d = createDialog(parent); // FIXME: Remove when we get ancestor property d.setTitle("Open"); setDialogType(OPEN_DIALOG); retval = ERROR_OPTION; Insets i = d.getInsets(); d.setSize(500 + i.top + i.bottom, d.getPreferredSize().height); d.show(); return retval; }
| 6,116
|
public int showSaveDialog(Component parent) throws HeadlessException { JDialog d = createDialog(parent); setDialogType(SAVE_DIALOG); retval = ERROR_OPTION; Insets i = d.getInsets(); d.setSize(500 + i.top + i.bottom, d.getPreferredSize().height); d.show(); return retval; }
|
public int showSaveDialog(Component parent) throws HeadlessException { JDialog d = createDialog(parent); setDialogType(SAVE_DIALOG); retval = ERROR_OPTION; Insets i = d.getInsets(); d.setSize(500 + i.top + i.bottom, d.getPreferredSize().height); d.show(); return retval; }
| 6,117
|
protected void damageLineRange (int line0, int line1, Shape a, Component host) { if (a == null) return; Rectangle rec0 = lineToRect(a, line0); Rectangle rec1 = lineToRect(a, line1); if (rec0 == null || rec1 == null) // something went wrong, repaint the entire host to be safe host.repaint(); else { Rectangle repaintRec = rec0.union(rec1); host.repaint(repaintRec.x, repaintRec.y, repaintRec.width, repaintRec.height); } }
|
protected void damageLineRange (int line0, int line1, Shape a, Component host) { if (a == null) return; Rectangle rec0 = lineToRect(a, line0); Rectangle rec1 = lineToRect(a, line1); if (rec0 == null || rec1 == null) // something went wrong, repaint the entire host to be safe host.repaint(); else { Rectangle repaintRec = SwingUtilities.computeUnion(rec0.x, rec0.y, rec0.width, rec0.height, rec1); host.repaint(repaintRec.x, repaintRec.y, repaintRec.width, repaintRec.height); } }
| 6,118
|
public int getNativeFD() { return ch.getPlainSocketImpl().getNativeFD(); }
|
public int getNativeFD() { try { return ch.getVMChannel().getState().getNativeFD(); } catch (IOException ioe) { return 0; } }
| 6,120
|
public void read(long devOffset, byte[] dest, int destOffset, int length) throws IOException { if (length == 0) { return; } final int ofsMisAlign = (int)(devOffset % alignment); final int lenMisAlign = (length % alignment); /*log.debug("devOffset =" + devOffset); log.debug("length =" + length); log.debug("ofsMisAlign=" + ofsMisAlign); log.debug("lenMisAlign=" + lenMisAlign);*/ if ((ofsMisAlign != 0) || (lenMisAlign != 0)) { final byte[] buf = new byte[length + ofsMisAlign + (alignment - lenMisAlign)]; parentApi.read(devOffset - ofsMisAlign, buf, 0, buf.length); if (ofsMisAlign != 0) { System.arraycopy(buf, alignment - ofsMisAlign, dest, destOffset, length); } else { System.arraycopy(buf, 0, dest, destOffset, length); } } else { // Aligned call, pass on parentApi.read(devOffset, dest, destOffset, length); } }
|
public void read(long devOffset, byte[] dest, int destOffset, int length) throws IOException { if (length == 0) { return; } final int ofsMisAlign = (int)(devOffset % alignment); final int lenMisAlign = (length % alignment); /*log.debug("devOffset =" + devOffset); log.debug("length =" + length); log.debug("ofsMisAlign=" + ofsMisAlign); log.debug("lenMisAlign=" + lenMisAlign);*/ if ((ofsMisAlign != 0) || (lenMisAlign != 0)) { final byte[] buf = new byte[(length / alignment) + alignment]; parentApi.read(devOffset - ofsMisAlign, buf, 0, buf.length); if (ofsMisAlign != 0) { System.arraycopy(buf, alignment - ofsMisAlign, dest, destOffset, length); } else { System.arraycopy(buf, 0, dest, destOffset, length); } } else { // Aligned call, pass on parentApi.read(devOffset, dest, destOffset, length); } }
| 6,122
|
public String getName() { return (String) getAttribute(NameAttribute); }
|
public String getName() { return (String) getAttribute(StyleConstants.NameAttribute); }
| 6,123
|
protected void blockClose(HTML.Tag t) { printBuffer(); ElementSpec element = new ElementSpec(null, ElementSpec.EndTagType); parseBuffer.addElement(element); printBuffer(); }
|
protected void blockClose(HTML.Tag t) { printBuffer(); DefaultStyledDocument.ElementSpec element; element = new DefaultStyledDocument.ElementSpec(null, DefaultStyledDocument.ElementSpec.EndTagType); parseBuffer.addElement(element); printBuffer(); }
| 6,124
|
protected void blockOpen(HTML.Tag t, MutableAttributeSet attr) { printBuffer(); ElementSpec element = new ElementSpec(attr.copyAttributes(), ElementSpec.StartTagType); parseBuffer.addElement(element); printBuffer(); }
|
protected void blockOpen(HTML.Tag t, MutableAttributeSet attr) { printBuffer(); DefaultStyledDocument.ElementSpec element; element = new DefaultStyledDocument.ElementSpec(attr.copyAttributes(), DefaultStyledDocument.ElementSpec.StartTagType); parseBuffer.addElement(element); printBuffer(); }
| 6,125
|
public void flush() throws BadLocationException { ElementSpec[] elements = new ElementSpec[parseBuffer.size()]; parseBuffer.copyInto(elements); parseBuffer.removeAllElements(); insert(offset, elements); offset += HTMLDocument.this.getLength() - offset; }
|
public void flush() throws BadLocationException { DefaultStyledDocument.ElementSpec[] elements; elements = new DefaultStyledDocument.ElementSpec[parseBuffer.size()]; parseBuffer.copyInto(elements); parseBuffer.removeAllElements(); insert(offset, elements); offset += HTMLDocument.this.getLength() - offset; }
| 6,126
|
public Element getElement(Element e, Object attribute, Object value) { if (e != null) { if (e.getAttributes().containsAttribute(attribute, value)) return e; int count = e.getElementCount(); for (int j = 0; j < count; j++) { Element child = e.getElement(j); if (child.getAttributes().containsAttribute(attribute, value)) return child; return getElement(child, attribute, value); } } return null; }
|
public Element getElement(Element e, Object attribute, Object value) { if (e != null) { if (e.getAttributes().containsAttribute(attribute, value)) return e; int count = e.getElementCount(); for (int j = 0; j < count; j++) { Element child = e.getElement(j); if (child.getAttributes().containsAttribute(attribute, value)) return child; Element grandChild = getElement(child, attribute, value); if (grandChild != null) return grandChild; } } return null; }
| 6,127
|
public JFileChooser() { // TODO } // JFileChooser()
|
public JFileChooser() { // TODO } // JFileChooser()
| 6,128
|
public boolean accept(File file) { return false; // TODO } // accept()
|
public boolean accept(File file) { return false; // TODO } // accept()
| 6,129
|
public void addActionListener(ActionListener listener) { listenerList.add (ActionListener.class, listener); }
|
public void addActionListener(ActionListener l) { listenerList.add (ActionListener.class, listener); }
| 6,130
|
public void addActionListener(ActionListener listener) { listenerList.add (ActionListener.class, listener); }
|
public void addActionListener(ActionListener listener) { listenerList.add(ActionListener.class, l); }
| 6,131
|
public void addChoosableFileFilter(FileFilter filter) { // TODO } // addChoosableFileFilter()
|
public void addChoosableFileFilter(FileFilter filter) { // TODO } // addChoosableFileFilter()
| 6,132
|
public void approveSelection() { // TODO } // approveSelection()
|
public void approveSelection() { // TODO } // approveSelection()
| 6,133
|
public void cancelSelection() { // TODO } // cancelSelection()
|
public void cancelSelection() { // TODO } // cancelSelection()
| 6,134
|
public void changeToParentDirectory() { // TODO } // changeToParentDirectory()
|
public void changeToParentDirectory() { // TODO } // changeToParentDirectory()
| 6,135
|
public void ensureFileIsVisible(File file) { // TODO } // ensureFileIsVisible()
|
public void ensureFileIsVisible(File file) { // TODO } // ensureFileIsVisible()
| 6,136
|
protected void fireActionPerformed(String command) { // TODO } // fireActionPerformed()
|
protected void fireActionPerformed(String command) { // TODO } // fireActionPerformed()
| 6,137
|
public FileFilter getAcceptAllFileFilter() { return null; // TODO } // getAcceptAllFileFilter()
|
public FileFilter getAcceptAllFileFilter() { return null; // TODO } // getAcceptAllFileFilter()
| 6,138
|
public AccessibleContext getAccessibleContext() { if (accessibleContext == null) accessibleContext = new AccessibleJFileChooser(); return accessibleContext; }
|
public AccessibleContext getAccessibleContext() { if (accessibleContext == null) accessibleContext = new AccessibleJFileChooser(); return accessibleContext; }
| 6,139
|
public JComponent getAccessory() { return null; // TODO } // getAccessory()
|
public JComponent getAccessory() { return null; // TODO } // getAccessory()
| 6,140
|
public ActionListener[] getActionListeners() { return (ActionListener[]) listenerList.getListeners (ActionListener.class); }
|
public ActionListener[] getActionListeners() { return (ActionListener[]) getListeners(ActionListener.class); }
| 6,141
|
public int getApproveButtonMnemonic() { return 0; // TODO } // getApproveButtonMnemonic()
|
public int getApproveButtonMnemonic() { return 0; // TODO } // getApproveButtonMnemonic()
| 6,142
|
public String getApproveButtonText() { return null; // TODO } // getApproveButtonText()
|
public String getApproveButtonText() { return null; // TODO } // getApproveButtonText()
| 6,143
|
public String getApproveButtonToolTipText() { return null; // TODO } // getApproveButtonToolTipText()
|
public String getApproveButtonToolTipText() { return null; // TODO } // getApproveButtonToolTipText()
| 6,144
|
public FileFilter[] getChoosableFileFilters() { return null; // TODO } // getChoosableFileFilters()
|
public FileFilter[] getChoosableFileFilters() { return null; // TODO } // getChoosableFileFilters()
| 6,145
|
public boolean getControlButtonsAreShown() { return false; // TODO } // getControlButtonsAreShown()
|
public boolean getControlButtonsAreShown() { return false; // TODO } // getControlButtonsAreShown()
| 6,146
|
public File getCurrentDirectory() { return null; // TODO } // getCurrentDirectory()
|
public File getCurrentDirectory() { return null; // TODO } // getCurrentDirectory()
| 6,147
|
public String getDescription(File file) { return null; // TODO } // getDescription()
|
public String getDescription(File file) { return null; // TODO } // getDescription()
| 6,148
|
public String getDialogTitle() { return null; // TODO } // getDialogTitle()
|
public String getDialogTitle() { return null; // TODO } // getDialogTitle()
| 6,149
|
public int getDialogType() { return 0; // TODO } // getDialogType()
|
public int getDialogType() { return 0; // TODO } // getDialogType()
| 6,150
|
public FileFilter getFileFilter() { return null; // TODO } // getFileFilter()
|
public FileFilter getFileFilter() { return null; // TODO } // getFileFilter()
| 6,151
|
public int getFileSelectionMode() { return 0; // TODO } // getFileSelectionMode()
|
public int getFileSelectionMode() { return 0; // TODO } // getFileSelectionMode()
| 6,152
|
public FileSystemView getFileSystemView() { return null; // TODO } // getFileSystemView()
|
public FileSystemView getFileSystemView() { return null; // TODO } // getFileSystemView()
| 6,153
|
public FileView getFileView() { return null; // TODO } // getFileView()
|
public FileView getFileView() { return null; // TODO } // getFileView()
| 6,154
|
public Icon getIcon(File file) { return null; // TODO } // getIcon()
|
public Icon getIcon(File file) { return null; // TODO } // getIcon()
| 6,155
|
public String getName(File file) { return null; // TODO } // getName()
|
public String getName(File file) { return null; // TODO } // getName()
| 6,156
|
public File getSelectedFile() { return null; // TODO } // getSelectedFile()
|
public File getSelectedFile() { return null; // TODO } // getSelectedFile()
| 6,157
|
public File[] getSelectedFiles() { return null; // TODO } // getSelectedFiles()
|
public File[] getSelectedFiles() { return null; // TODO } // getSelectedFiles()
| 6,158
|
public String getTypeDescription(File file) { return null; // TODO } // getTypeDescription()
|
public String getTypeDescription(File file) { return null; // TODO } // getTypeDescription()
| 6,159
|
public String getUIClassID() { return uiClassID; } // getUIClassID()
|
public String getUIClassID() { return uiClassID; } // getUIClassID()
| 6,160
|
public boolean isAcceptAllFileFilterUsed() { return false; // TODO } // isAcceptAllFileFilterUsed()
|
public boolean isAcceptAllFileFilterUsed() { return false; // TODO } // isAcceptAllFileFilterUsed()
| 6,161
|
public boolean isDirectorySelectionEnabled() { return false; // TODO } // isDirectorySelectionEnabled()
|
public boolean isDirectorySelectionEnabled() { return false; // TODO } // isDirectorySelectionEnabled()
| 6,162
|
public boolean isFileHidingEnabled() { return false; // TODO } // isFileHidingEnabled()
|
public boolean isFileHidingEnabled() { return false; // TODO } // isFileHidingEnabled()
| 6,163
|
public boolean isFileSelectionEnabled() { return false; // TODO } // isFileSelectionEnabled()
|
public boolean isFileSelectionEnabled() { return false; // TODO } // isFileSelectionEnabled()
| 6,164
|
public boolean isMultiSelectionEnabled() { return false; // TODO } // isMultiSelectionEnabled()
|
public boolean isMultiSelectionEnabled() { return false; // TODO } // isMultiSelectionEnabled()
| 6,165
|
public boolean isTraversable(File file) { return false; // TODO } // isTraversable()
|
public boolean isTraversable(File file) { return false; // TODO } // isTraversable()
| 6,166
|
protected String paramString() { return null; // TODO } // paramString()
|
protected String paramString() { return null; // TODO } // paramString()
| 6,167
|
public void removeActionListener(ActionListener listener) { listenerList.remove (ActionListener.class, listener); }
|
public void removeActionListener(ActionListener l) { try { listenerList.remove(ActionListener.class, l); } catch (IllegalArgumentException e) { listenerList.remove (ActionListener.class, listener); }
| 6,168
|
public void removeActionListener(ActionListener listener) { listenerList.remove (ActionListener.class, listener); }
|
public void removeActionListener(ActionListener listener) { e.printStackTrace(); } }
| 6,169
|
public boolean removeChoosableFileFilter(FileFilter filter) { return false; // TODO } // removeChoosableFileFilter()
|
public boolean removeChoosableFileFilter(FileFilter filter) { return false; // TODO } // removeChoosableFileFilter()
| 6,170
|
public void rescanCurrentDirectory() { // TODO } // rescanCurrentDirectory()
|
public void rescanCurrentDirectory() { // TODO } // rescanCurrentDirectory()
| 6,171
|
public void resetChoosableFileFilters() { // TODO } // resetChoosableFileFilters()
|
public void resetChoosableFileFilters() { // TODO } // resetChoosableFileFilters()
| 6,172
|
public void setAcceptAllFileFilterUsed(boolean value) { // TODO } // setAcceptAllFileFilterUsed()
|
public void setAcceptAllFileFilterUsed(boolean value) { // TODO } // setAcceptAllFileFilterUsed()
| 6,173
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.