diff options
author | Sneha C | 2021-08-27 14:12:05 +0000 |
---|---|---|
committer | Sneha C | 2021-08-27 14:12:05 +0000 |
commit | 43ac28c76fc7a846abc5b39eb8ef0987b9b85948 (patch) | |
tree | 7d4c9ebb33ff2490567e09709a82cc4a64721b73 | |
parent | 1a6b86e9844d1790bce39d92790f01f058955005 (diff) | |
download | org.eclipse.tcf-43ac28c76fc7a846abc5b39eb8ef0987b9b85948.tar.gz org.eclipse.tcf-43ac28c76fc7a846abc5b39eb8ef0987b9b85948.tar.xz org.eclipse.tcf-43ac28c76fc7a846abc5b39eb8ef0987b9b85948.zip |
Bug 575341 - Pin Memory Browser to Debug Context
- enables pinning of the Memory Browser view to the selected debug context.
- this action was previously disabled for the Memory Browser view
-rw-r--r-- | plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/commands/TCFPinViewCommand.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/commands/TCFPinViewCommand.java b/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/commands/TCFPinViewCommand.java index d3f277505..8d3f994f1 100644 --- a/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/commands/TCFPinViewCommand.java +++ b/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/commands/TCFPinViewCommand.java @@ -36,6 +36,7 @@ import org.eclipse.ui.IWorkbenchPart; @SuppressWarnings("restriction") public class TCFPinViewCommand implements IPinProvider { + public static final String ID_MEMORY_BROWSER_VIEW = "org.eclipse.cdt.debug.ui.memory.memorybrowser.MemoryBrowser"; //$NON-NLS-1$ private final TCFModel model; private final ArrayList<PinnedView> list = new ArrayList<PinnedView>(); @@ -206,6 +207,7 @@ public class TCFPinViewCommand implements IPinProvider { public void run() { boolean mem = false; boolean vars = false; + boolean memBrowser = false; if (obj instanceof TCFNodeExecContext) { TCFNodeExecContext node = (TCFNodeExecContext)obj; TCFDataCache<IRunControl.RunControlContext> ctx_cache = node.getRunContext(); @@ -214,15 +216,18 @@ public class TCFPinViewCommand implements IPinProvider { if (ctx_data != null) { vars = ctx_data.hasState(); mem = vars || ctx_data.getProcessID() != null; + memBrowser = mem; } } if (obj instanceof TCFNodeStackFrame) { vars = true; mem = true; + memBrowser = false; } if (IDebugUIConstants.ID_REGISTER_VIEW.equals(id)) done(mem); else if (IDebugUIConstants.ID_VARIABLE_VIEW.equals(id)) done(vars); else if (IDebugUIConstants.ID_EXPRESSION_VIEW.equals(id)) done(mem); + else if (ID_MEMORY_BROWSER_VIEW.equals(id)) done(memBrowser); else done(false); } }.getE(); |