Esempio n. 1
0
  public synchronized void dispose() {
    if (!(myInitialized)) {
      return;
    }
    myInitialized = false;

    if (myGlobalModelListener != null) {
      GlobalSModelEventsManager.getInstance().removeGlobalModelListener(myGlobalModelListener);
    }
    FileStatusManager.getInstance(myRegistry.getProject())
        .removeFileStatusListener(myFileStatusListener);
    myTree.removeTreeNodeListener(myTreeNodeListener);
    myMap.removeListener(myFeatureListener);
    myQueue.dispose();
  }
Esempio n. 2
0
  public synchronized void init() {
    if (myInitialized) {
      return;
    }
    myInitialized = true;

    myMap.addListener(myFeatureListener);
    myTree.addTreeNodeListener(myTreeNodeListener);
    FileStatusManager.getInstance(myRegistry.getProject())
        .addFileStatusListener(myFileStatusListener);
    if (myGlobalModelListener != null) {
      GlobalSModelEventsManager.getInstance().addGlobalModelListener(myGlobalModelListener);
    }

    ModelAccess.instance()
        .runReadInEDT(
            new Runnable() {
              public void run() {
                registerNodeRecursively(myTree.getRootNode());
              }
            });
  }
Esempio n. 3
0
 @Override
 public void dispose() {
   clearHighlighting();
   super.dispose();
 }