ui/src/main/java/ucar/nc2/ui/image/ScalablePicture.java
public void sourceStatusChange(int statusCode, String statusMessage, SourcePicture sp) {
    //Tools.log("ScalablePicture.sourceStatusChange: status received from SourceImage: " + statusMessage);

    switch (statusCode) {
      case SourcePicture.UNINITIALISED:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: UNINITIALISED message: " + statusMessage);
        setStatus(UNINITIALISED, statusMessage);
        break;
      case SourcePicture.ERROR:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: ERROR message: " + statusMessage);
        setStatus(ERROR, statusMessage);
        sourcePicture.removeListener(this);
        break;
      case SourcePicture.LOADING:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: LOADING message: " + statusMessage);
        setStatus(LOADING, statusMessage);
        break;
      case SourcePicture.ROTATING:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: ROTATING message: " + statusMessage);
        setStatus(LOADING, statusMessage);
        break;
      case SourcePicture.READY:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: READY message: " + statusMessage);
        setStatus(LOADED, statusMessage);
        sourcePicture.removeListener(this);
        if (scaleAfterLoad) {
          createScaledPictureInThread(Thread.MAX_PRIORITY);
          scaleAfterLoad = false;
        }
        break;
      default:
        Tools.log("ScalablePicture.sourceStatusChange: Don't recognize this status: " + statusMessage);
        break;

    }
  }
public void sourceStatusChange(int statusCode, String statusMessage, SourcePicture sp) {
    //Tools.log("ScalablePicture.sourceStatusChange: status received from SourceImage: " + statusMessage);

    switch (statusCode) {
      case SourcePicture.UNINITIALISED:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: UNINITIALISED message: " + statusMessage);
        setStatus(UNINITIALISED, statusMessage);
        break;
      case SourcePicture.ERROR:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: ERROR message: " + statusMessage);
        setStatus(ERROR, statusMessage);
        sourcePicture.removeListener(this);
        break;
      case SourcePicture.LOADING:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: LOADING message: " + statusMessage);
        setStatus(LOADING, statusMessage);
        break;
      case SourcePicture.ROTATING:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: ROTATING message: " + statusMessage);
        setStatus(LOADING, statusMessage);
        break;
      case SourcePicture.READY:
        Tools.log("ScalablePicture.sourceStatusChange: pictureStatus was: READY message: " + statusMessage);
        setStatus(LOADED, statusMessage);
        sourcePicture.removeListener(this);
        if (scaleAfterLoad) {
          createScaledPictureInThread(Thread.MAX_PRIORITY);
          scaleAfterLoad = false;
        }
        break;
      default:
        Tools.log("ScalablePicture.sourceStatusChange: Don't recognize this status: " + statusMessage);
        break;

    }
  }
method that is invoked by the SourcePictureListener interface. Usually this
will be called by the SourcePicture telling the ScalablePicture that
it has completed loading. The ScalablePicture should then change it's own
status and tell the ScalableListeners what's up.