diff options
author | Pablo Torregrosa Paez | 2015-12-03 13:49:39 +0000 |
---|---|---|
committer | Pablo Torregrosa Paez | 2015-12-03 13:49:46 +0000 |
commit | f9d78a0aa29bed3cdf2adbf014d3ea1cd37dc8c3 (patch) | |
tree | abce4cba861080baedc5c98f05719d71f0bfa278 /target_explorer/plugins/org.eclipse.tcf.te.tcf.ui | |
parent | 025c9108ff4165bc46ecbf4e523625c03288cdab (diff) | |
download | org.eclipse.tcf-f9d78a0aa29bed3cdf2adbf014d3ea1cd37dc8c3.tar.gz org.eclipse.tcf-f9d78a0aa29bed3cdf2adbf014d3ea1cd37dc8c3.tar.xz org.eclipse.tcf-f9d78a0aa29bed3cdf2adbf014d3ea1cd37dc8c3.zip |
Target Explorer: Make 'history_id' overridable.
Change-Id: Ic3cf4d886e8fbb643c83db0145cbff6952bfa21b
Signed-off-by: Pablo Torregrosa Paez <pablo.torregrosa@windriver.com>
Diffstat (limited to 'target_explorer/plugins/org.eclipse.tcf.te.tcf.ui')
-rw-r--r-- | target_explorer/plugins/org.eclipse.tcf.te.tcf.ui/src/org/eclipse/tcf/te/tcf/ui/handler/AbstractContextStepperCommandHandler.java | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.tcf.ui/src/org/eclipse/tcf/te/tcf/ui/handler/AbstractContextStepperCommandHandler.java b/target_explorer/plugins/org.eclipse.tcf.te.tcf.ui/src/org/eclipse/tcf/te/tcf/ui/handler/AbstractContextStepperCommandHandler.java index d8f166f15..524c4bd2f 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.tcf.ui/src/org/eclipse/tcf/te/tcf/ui/handler/AbstractContextStepperCommandHandler.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.tcf.ui/src/org/eclipse/tcf/te/tcf/ui/handler/AbstractContextStepperCommandHandler.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2013, 2014 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2013, 2015 Wind River Systems, Inc. and others. All rights reserved. * This program and the accompanying materials are made available under the terms * of the Eclipse Public License v1.0 which accompanies this distribution, and is * available at http://www.eclipse.org/legal/epl-v10.html @@ -66,7 +66,11 @@ public abstract class AbstractContextStepperCommandHandler extends AbstractStepp if (stepperOpService instanceof IStepperOperationService && ((IStepperOperationService)stepperOpService).isHandledOperation(context, operation)) { String groupId = ((IStepperOperationService)stepperOpService).getStepGroupId(context, operation); if (groupId != null) { - String history = HistoryManager.getInstance().getFirst(groupId + "@" + context.getPeerId()); //$NON-NLS-1$ + String historyId = getHistoryId(event); + if (historyId == null) { + historyId = groupId + "@" + context.getPeerId(); //$NON-NLS-1$ + } + String history = HistoryManager.getInstance().getFirst(historyId); if (history != null) { return DataHelper.decodePropertiesContainer(history); } @@ -78,6 +82,10 @@ public abstract class AbstractContextStepperCommandHandler extends AbstractStepp return getDefaultData(); } + protected String getHistoryId(ExecutionEvent event) { + return null; + } + protected IPropertiesContainer getDefaultData() { return new PropertiesContainer(); } |