private void endBox(int x, int y) {
    if (zoomBoxStartX != -1 && zoomBoxStartY != -1 && zoomBoxWidth != -1 && zoomBoxHeight != -1
        && zoomBoxWidth != 0 && zoomBoxHeight != 0) {
      resizeMe(getBoxX(), getBoxY(), getBoxWidth(), getBoxHeight());
      repaint(getBoxX(), getBoxY(), getBoxWidth(), getBoxHeight());
      zoomBoxStartX = -1;
      zoomBoxStartY = -1;
      zoomBoxWidth = -1;
      zoomBoxHeight = -1;
    }
  }
Created by IntelliJ IDEA. User: dan Date: Oct 28, 2010 Time: 10:30:40 PM To change this template
use File | Settings | File Templates.
geode-core/src/test/java/org/apache/geode/sequence/ZoomingPanel.java