if (line != -1) { if (currentWindow != null) { currentWindow.setPosition(-1); w.setPosition(w.textArea.getLineStartOffset(line-1)); } catch (BadLocationException exc) { try { w.setPosition(w.textArea.getLineStartOffset(0)); } catch (BadLocationException ee) { w.setPosition(-1);
if (line != -1) { if (currentWindow != null) { currentWindow.setPosition(-1); w.setPosition(w.textArea.getLineStartOffset(line-1)); } catch (BadLocationException exc) { try { w.setPosition(w.textArea.getLineStartOffset(0)); } catch (BadLocationException ee) { w.setPosition(-1);
if (line != -1) { if (currentWindow != null) { currentWindow.setPosition(-1); w.setPosition(w.textArea.getLineStartOffset(line-1)); } catch (BadLocationException exc) { try { w.setPosition(w.textArea.getLineStartOffset(0)); } catch (BadLocationException ee) { w.setPosition(-1);
try { if (line == -1) { w.setPosition(-1); if (currentWindow == w) { currentWindow = null; int loc = ta.getLineStartOffset(line-1); if (currentWindow != null && currentWindow != w) { currentWindow.setPosition(-1); w.setPosition(loc); currentWindow = w;
try { if (line == -1) { w.setPosition(-1); if (currentWindow == w) { currentWindow = null; int loc = ta.getLineStartOffset(line-1); if (currentWindow != null && currentWindow != w) { currentWindow.setPosition(-1); w.setPosition(loc); currentWindow = w;
try { if (line == -1) { w.setPosition(-1); if (currentWindow == w) { currentWindow = null; int loc = ta.getLineStartOffset(line-1); if (currentWindow != null && currentWindow != w) { currentWindow.setPosition(-1); w.setPosition(loc); currentWindow = w;
/** * Enables or disables the menu and tool bars with respect to the * state of script execution. */ private void updateEnabled(boolean interrupted) { ((Menubar)getJMenuBar()).updateEnabled(interrupted); for (int ci = 0, cc = toolBar.getComponentCount(); ci < cc; ci++) { boolean enableButton; if (ci == 0) { // Break enableButton = !interrupted; } else { enableButton = interrupted; } toolBar.getComponent(ci).setEnabled(enableButton); } if (interrupted) { toolBar.setEnabled(true); // raise the debugger window int state = getExtendedState(); if (state == Frame.ICONIFIED) { setExtendedState(Frame.NORMAL); } toFront(); context.setEnabled(true); } else { if (currentWindow != null) currentWindow.setPosition(-1); context.setEnabled(false); } }
/** * Enables or disables the menu and tool bars with respect to the * state of script execution. */ private void updateEnabled(boolean interrupted) { ((Menubar)getJMenuBar()).updateEnabled(interrupted); for (int ci = 0, cc = toolBar.getComponentCount(); ci < cc; ci++) { boolean enableButton; if (ci == 0) { // Break enableButton = !interrupted; } else { enableButton = interrupted; } toolBar.getComponent(ci).setEnabled(enableButton); } if (interrupted) { toolBar.setEnabled(true); // raise the debugger window int state = getExtendedState(); if (state == Frame.ICONIFIED) { setExtendedState(Frame.NORMAL); } toFront(); context.setEnabled(true); } else { if (currentWindow != null) currentWindow.setPosition(-1); context.setEnabled(false); } }
/** * Enables or disables the menu and tool bars with respect to the * state of script execution. */ private void updateEnabled(boolean interrupted) { ((Menubar)getJMenuBar()).updateEnabled(interrupted); for (int ci = 0, cc = toolBar.getComponentCount(); ci < cc; ci++) { boolean enableButton; if (ci == 0) { // Break enableButton = !interrupted; } else { enableButton = interrupted; } toolBar.getComponent(ci).setEnabled(enableButton); } if (interrupted) { toolBar.setEnabled(true); // raise the debugger window int state = getExtendedState(); if (state == Frame.ICONIFIED) { setExtendedState(Frame.NORMAL); } toFront(); context.enable(); } else { if (currentWindow != null) currentWindow.setPosition(-1); context.disable(); } }