/*.................................................................................................................*/ public void windowResized() { super.windowResized(); if (MesquiteWindow.checkDoomed(this)) return; setExplanation( "Configuration of modules loaded: " + MesquiteTrunk.mesquiteTrunk.getConfiguration()); if (browser != null) { browser.setSize(getWidth(), getHeight() - searchHeight); browser.setLocation(0, 0); } if (searchStrip != null) { searchStrip.setLocation(4, getHeight() - searchHeight); searchStrip.setSize(getWidth() - 4, searchHeight); } MesquiteWindow.uncheckDoomed(this); }
public void crement(int i) { if (MesquiteWindow.getQueryMode(this)) { MesquiteWindow.respondToQueryMode("Mini scroll", command, this); return; } if (i <= maxValue && (i >= minValue) && command != null) { currentValue = i; command.doItMainThread( Long.toString(currentValue), CommandChecker.getQueryModeString("Mini scroll", command, this), this); tf.setText(Long.toString(currentValue)); decrementButton.setEnabled(i > minValue); incrementButton.setEnabled(i < maxValue); } }
public void decrement() { if (MesquiteWindow.getQueryMode(this)) { MesquiteWindow.respondToQueryMode("Mini scroll", command, this); return; } if (currentValue > minValue && command != null) { currentValue--; tf.setText(Long.toString(currentValue)); command.doItMainThread( Long.toString(currentValue), CommandChecker.getQueryModeString("Mini scroll", command, this), this); enterButton.setEnabled(false); decrementButton.setEnabled(currentValue > minValue); incrementButton.setEnabled(currentValue < maxValue); } }
public void increment() { // have interface incrementable and pass object to this miniscroll so it can // notify object if (MesquiteWindow.getQueryMode(this)) { MesquiteWindow.respondToQueryMode("Mini scroll", command, this); return; } if (currentValue < maxValue && command != null) { currentValue++; command.doItMainThread( Long.toString(currentValue), CommandChecker.getQueryModeString("Mini scroll", command, this), this); tf.setText(Long.toString(currentValue)); enterButton.setEnabled(false); decrementButton.setEnabled(currentValue > minValue); incrementButton.setEnabled(currentValue < maxValue); } }
public void paint(Graphics g) { // ^^^ if (g instanceof PrintGraphics) return; if (MesquiteWindow.checkDoomed(this)) return; /**/ if (getParent() == null) { MesquiteWindow.uncheckDoomed(this); return; } if (neverCalculated) { if (recalcPositions(g)) { MesquiteWindow.uncheckDoomed(this); neverCalculated = false; return; } } /**/ /* This stuff below seems unnecessary, but for some reason on MacOS 8.1/MRJ 2.0 it was leaving garbage around; likewise for components*/ g.setColor(getBackground()); g.fillRect(getBounds().x, getBounds().y, getBounds().width, getBounds().height); g.setColor(Color.black); // tf.repaint(); MesquiteWindow.uncheckDoomed(this); }
public void contentsChanged() { setExplanation( "Configuration of modules loaded: " + MesquiteTrunk.mesquiteTrunk.getConfiguration()); super.contentsChanged(); }