org.openide.nodes.NodeMemberEvent Java Examples

The following examples show how to use org.openide.nodes.NodeMemberEvent. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: GraphNode.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
private GraphNode(InputGraph graph, InstanceContent content) {
    super(Children.LEAF, new AbstractLookup(content));
    this.graph = graph;
    this.setDisplayName(graph.getName());
    content.add(graph);

    final GraphViewer viewer = Lookup.getDefault().lookup(GraphViewer.class);

    if (viewer != null) {
        // Action for opening the graph
        content.add(new GraphOpenCookie(viewer, graph));
    }

    // Action for removing a graph
    content.add(new GraphRemoveCookie(graph));

    // Action for diffing to the current graph
    content.add(new DiffGraphCookie(graph));

    // Action for cloning to the current graph
    content.add(new GraphCloneCookie(viewer, graph));

    this.addNodeListener(new NodeAdapter() {
        @Override
        public void childrenRemoved(NodeMemberEvent ev) {
            GraphNode.this.graph = null;
        }
    });
}
 
Example #2
Source File: TemplatesPanel.java    From netbeans with Apache License 2.0 5 votes vote down vote up
@Override
protected void filterChildrenRemoved (NodeMemberEvent ev) {
    super.filterChildrenRemoved (ev);
    if (getTemplateRootNode ().equals (this.getNode ())) {
        sortNodes ();
    }
}
 
Example #3
Source File: TemplatesPanel.java    From netbeans with Apache License 2.0 5 votes vote down vote up
@Override
protected void filterChildrenAdded (NodeMemberEvent ev) {
    super.filterChildrenAdded (ev);
    if (getTemplateRootNode ().equals (this.getNode ())) {
        sortNodes ();
    }
}
 
Example #4
Source File: PhadhailViews.java    From netbeans with Apache License 2.0 5 votes vote down vote up
protected void filterChildrenRemoved(final NodeMemberEvent ev) {
    Locks.event().readLater(new Runnable() {
        public void run() {
            EQReplannedChildren.super.filterChildrenRemoved(ev);
        }
    });
}
 
Example #5
Source File: PhadhailViews.java    From netbeans with Apache License 2.0 5 votes vote down vote up
protected void filterChildrenAdded(final NodeMemberEvent ev) {
    Locks.event().readLater(new Runnable() {
        public void run() {
            EQReplannedChildren.super.filterChildrenAdded(ev);
        }
    });
}
 
Example #6
Source File: TerrainEditorController.java    From MikuMikuStudio with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    boolean isTerrain = false;
    for(org.openide.nodes.Node n : ev.getSnapshot()) {
        Node node = n.getLookup().lookup(Node.class);
        if (node instanceof Terrain) {
            isTerrain = true;
            break;
        }
    }
    if (isTerrain)
        topComponent.reinitTextureTable();
}
 
Example #7
Source File: NavigatorController.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    // no operation
}
 
Example #8
Source File: NavigatorController.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenRemoved(NodeMemberEvent ev) {
    // no operation
}
 
Example #9
Source File: ProjectsRootNodePreferredFromPopupTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #10
Source File: SceneEditorController.java    From MikuMikuStudio with BSD 2-Clause "Simplified" License 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
//        setNeedsSave(true);
        toolController.refreshNonSpatialMarkers();
    }
 
Example #11
Source File: SceneEditorController.java    From MikuMikuStudio with BSD 2-Clause "Simplified" License 4 votes vote down vote up
public void childrenRemoved(NodeMemberEvent ev) {
//        setNeedsSave(true);
        toolController.refreshNonSpatialMarkers();
    }
 
Example #12
Source File: TerrainEditorTopComponent.java    From MikuMikuStudio with BSD 2-Clause "Simplified" License 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent nme) {
}
 
Example #13
Source File: TerrainEditorTopComponent.java    From MikuMikuStudio with BSD 2-Clause "Simplified" License 4 votes vote down vote up
public void childrenRemoved(NodeMemberEvent nme) {
}
 
Example #14
Source File: DefaultCategory.java    From netbeans with Apache License 2.0 4 votes vote down vote up
/** Fired when a set of new children is added.
* @param ev event describing the action
*/
public synchronized void childrenAdded(NodeMemberEvent ev) {
    items = null;
    notifyListeners();
}
 
Example #15
Source File: ProjectsRootNodePhysicalViewModeSourcesTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenRemoved(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #16
Source File: DefaultCategory.java    From netbeans with Apache License 2.0 4 votes vote down vote up
/** Fired when a set of children is removed.
* @param ev event describing the action
*/
public synchronized void childrenRemoved(NodeMemberEvent ev) {
    items = null;
    notifyListeners();
}
 
Example #17
Source File: EjbChildren.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenRemoved(NodeMemberEvent ev) {
    remove(ev.getDelta());
}
 
Example #18
Source File: ProjectsRootNodePhysicalViewModeSourcesTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #19
Source File: ProjectsRootNodePreferredFromPopupTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenRemoved(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #20
Source File: ProjectsRootNodePreferredOpenTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #21
Source File: ProjectsRootNodePreferredFromContextOpenTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenRemoved(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #22
Source File: ProjectsRootNodePreferredFromContextOpenTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #23
Source File: OpenProjectListSetMain2Test.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenRemoved(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #24
Source File: OpenProjectListSetMain2Test.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #25
Source File: ProjectsRootNodePhysicalViewTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenRemoved(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #26
Source File: ProjectsRootNodePhysicalViewTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #27
Source File: PhysicalView.java    From netbeans with Apache License 2.0 4 votes vote down vote up
@Override
public void childrenRemoved(NodeMemberEvent ev) {
}
 
Example #28
Source File: PhysicalView.java    From netbeans with Apache License 2.0 4 votes vote down vote up
@Override
public void childrenAdded(NodeMemberEvent ev) {
}
 
Example #29
Source File: ScanInProgressTest.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    assertFalse("No event in AWT thread", EventQueue.isDispatchThread());
    events.add(ev);
}
 
Example #30
Source File: EjbChildren.java    From netbeans with Apache License 2.0 4 votes vote down vote up
public void childrenAdded(NodeMemberEvent ev) {
    addChildrens(ev.getDelta());
}