# HG changeset patch # User Thomas Wuerthinger # Date 1328416672 -3600 # Node ID 5d9c4796912d459ea573fdd2573cb570db9a516c # Parent 88f091c2232d8dd888db45355560ecc33ca578f4 Fix window modes. Open snapshot view on startup. diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/Bytecodes/src/com/sun/hotspot/igv/bytecodes/SelectBytecodesAction.java --- a/src/share/tools/IdealGraphVisualizer/Bytecodes/src/com/sun/hotspot/igv/bytecodes/SelectBytecodesAction.java Sun Feb 05 05:05:51 2012 +0100 +++ b/src/share/tools/IdealGraphVisualizer/Bytecodes/src/com/sun/hotspot/igv/bytecodes/SelectBytecodesAction.java Sun Feb 05 05:37:52 2012 +0100 @@ -24,7 +24,6 @@ package com.sun.hotspot.igv.bytecodes; import com.sun.hotspot.igv.data.services.InputGraphProvider; -import com.sun.hotspot.igv.util.LookupHistory; import org.openide.nodes.Node; import org.openide.util.HelpCtx; import org.openide.util.NbBundle; diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/OutlineTopComponent.java --- a/src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/OutlineTopComponent.java Sun Feb 05 05:05:51 2012 +0100 +++ b/src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/OutlineTopComponent.java Sun Feb 05 05:37:52 2012 +0100 @@ -29,6 +29,8 @@ import java.awt.BorderLayout; import javax.swing.Action; import org.openide.actions.GarbageCollectAction; +import org.openide.awt.ActionID; +import org.openide.awt.ActionReference; import org.openide.awt.Toolbar; import org.openide.explorer.ExplorerManager; import org.openide.explorer.ExplorerUtils; @@ -37,6 +39,11 @@ import org.openide.windows.TopComponent; import org.openide.windows.WindowManager; +@TopComponent.Description(preferredID = OutlineTopComponent.PREFERRED_ID, persistenceType = TopComponent.PERSISTENCE_ALWAYS) +@TopComponent.Registration(mode = "explorer", openAtStartup = true) +@ActionID(category = "Window", id = "com.oracle.graal.visualizer.outline.OutlineTopComponent") +@ActionReference(path = "Menu/Window") +@TopComponent.OpenActionRegistration(displayName = "Outline", preferredID = OutlineTopComponent.PREFERRED_ID) public final class OutlineTopComponent extends TopComponent implements ExplorerManager.Provider { public static final String GLOBAL_ACTIONS_FOLDER = "Actions/Outline/Global"; diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/OutlineTopComponentSettings.xml --- a/src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/OutlineTopComponentSettings.xml Sun Feb 05 05:05:51 2012 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,8 +0,0 @@ - - - - - - - - diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/OutlineTopComponentWstcref.xml --- a/src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/OutlineTopComponentWstcref.xml Sun Feb 05 05:05:51 2012 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,7 +0,0 @@ - - - - - - - diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/actions/OutlineAction.java --- a/src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/actions/OutlineAction.java Sun Feb 05 05:05:51 2012 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,45 +0,0 @@ -/* - * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - * - */ - -package com.oracle.graal.visualizer.outline.actions; - -import com.oracle.graal.visualizer.outline.OutlineTopComponent; -import java.awt.event.ActionEvent; -import java.awt.event.ActionListener; -import org.openide.awt.ActionID; -import org.openide.awt.ActionReference; -import org.openide.awt.ActionRegistration; -import org.openide.windows.TopComponent; - -@ActionID(id = "com.oracle.graal.visualizer.outline.actions.OutlineAction", category = "Window") -@ActionRegistration(displayName = "Compilations") -@ActionReference(path = "Menu/Window", name = "OutlineAction") -public class OutlineAction implements ActionListener { - @Override - public void actionPerformed(ActionEvent evt) { - TopComponent win = OutlineTopComponent.findInstance(); - win.open(); - win.requestActive(); - } -} diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/customLeftWsmode.xml --- a/src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/customLeftWsmode.xml Sun Feb 05 05:05:51 2012 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,14 +0,0 @@ - - - - - - - - - - - - - - diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/layer.xml --- a/src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/layer.xml Sun Feb 05 05:05:51 2012 +0100 +++ b/src/share/tools/IdealGraphVisualizer/OutlineView/src/com/oracle/graal/visualizer/outline/layer.xml Sun Feb 05 05:37:52 2012 +0100 @@ -158,17 +158,4 @@ - - - - - - - - - - - - - diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/SnapshotsView/manifest.mf --- a/src/share/tools/IdealGraphVisualizer/SnapshotsView/manifest.mf Sun Feb 05 05:05:51 2012 +0100 +++ b/src/share/tools/IdealGraphVisualizer/SnapshotsView/manifest.mf Sun Feb 05 05:37:52 2012 +0100 @@ -1,5 +1,6 @@ Manifest-Version: 1.0 OpenIDE-Module: com.oracle.graal.visualizer.snapshots +OpenIDE-Module-Layer: com/oracle/graal/visualizer/snapshots/layer.xml OpenIDE-Module-Localizing-Bundle: com/oracle/graal/visualizer/snapshots/Bundle.properties OpenIDE-Module-Requires: org.openide.windows.WindowManager OpenIDE-Module-Specification-Version: 1.0 diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/SnapshotsView/src/com/oracle/graal/visualizer/snapshots/SnapshotTopComponent.java --- a/src/share/tools/IdealGraphVisualizer/SnapshotsView/src/com/oracle/graal/visualizer/snapshots/SnapshotTopComponent.java Sun Feb 05 05:05:51 2012 +0100 +++ b/src/share/tools/IdealGraphVisualizer/SnapshotsView/src/com/oracle/graal/visualizer/snapshots/SnapshotTopComponent.java Sun Feb 05 05:37:52 2012 +0100 @@ -39,11 +39,11 @@ import org.openide.windows.TopComponent; import org.openide.windows.WindowManager; -@TopComponent.Description(preferredID = SnapshotTopComponent.PREFERRED_ID, persistenceType = TopComponent.PERSISTENCE_NEVER) -@TopComponent.Registration(mode = "output", openAtStartup = true) +@TopComponent.Description(preferredID = SnapshotTopComponent.PREFERRED_ID, persistenceType = TopComponent.PERSISTENCE_ALWAYS) +@TopComponent.Registration(mode = "belowExplorer", openAtStartup = true) @ActionID(category = "Window", id = "com.oracle.graal.visualizer.snapshots.SnapshotTopComponent") @ActionReference(path = "Menu/Window") -@TopComponent.OpenActionRegistration(displayName = "Snapshot", preferredID = "SnapshotTopComponent") +@TopComponent.OpenActionRegistration(displayName = "Snapshot", preferredID = SnapshotTopComponent.PREFERRED_ID) public final class SnapshotTopComponent extends TopComponent { public static final String PREFERRED_ID = "SnapshotTopComponent"; @@ -76,7 +76,6 @@ this.rangeSlider = new RangeSlider(null); this.setLayout(new BorderLayout()); this.add(new JScrollPane(rangeSlider), BorderLayout.CENTER); - LookupUtils.lookupActions("Actions/View"); update(); } diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/SnapshotsView/src/com/oracle/graal/visualizer/snapshots/belowExplorerWsmode.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/share/tools/IdealGraphVisualizer/SnapshotsView/src/com/oracle/graal/visualizer/snapshots/belowExplorerWsmode.xml Sun Feb 05 05:37:52 2012 +0100 @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff -r 88f091c2232d -r 5d9c4796912d src/share/tools/IdealGraphVisualizer/SnapshotsView/src/com/oracle/graal/visualizer/snapshots/layer.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/share/tools/IdealGraphVisualizer/SnapshotsView/src/com/oracle/graal/visualizer/snapshots/layer.xml Sun Feb 05 05:37:52 2012 +0100 @@ -0,0 +1,9 @@ + + + + + + + + +