diff options
author | Eugene Tarassov | 2015-03-10 19:21:26 +0000 |
---|---|---|
committer | Eugene Tarassov | 2015-03-10 19:21:26 +0000 |
commit | 4904421444e5f3cb06871c5216c2666d82450cff (patch) | |
tree | 49a84146747f1a2c6500273840f12519e08a37b3 /plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse | |
parent | 872f9220e07e37b6ca615fca561becbf24ed3222 (diff) | |
download | org.eclipse.tcf-4904421444e5f3cb06871c5216c2666d82450cff.tar.gz org.eclipse.tcf-4904421444e5f3cb06871c5216c2666d82450cff.tar.xz org.eclipse.tcf-4904421444e5f3cb06871c5216c2666d82450cff.zip |
TCF Debugger: code cleanup
Diffstat (limited to 'plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse')
2 files changed, 11 insertions, 9 deletions
diff --git a/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/breakpoints/TCFWatchpointTarget.java b/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/breakpoints/TCFWatchpointTarget.java index 47fceaaa3..f372cbabe 100644 --- a/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/breakpoints/TCFWatchpointTarget.java +++ b/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/breakpoints/TCFWatchpointTarget.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2011, 2012 Wind River Systems, Inc. and others. + * Copyright (c) 2011, 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 @@ -22,10 +22,10 @@ import org.eclipse.tcf.util.TCFTask; */ public class TCFWatchpointTarget implements ICWatchpointTarget { - private final TCFNodeExpression fNode; + private final TCFNodeExpression node; public TCFWatchpointTarget(TCFNodeExpression node) { - fNode = node; + this.node = node; } public void canSetWatchpoint(CanCreateWatchpointRequest request) { @@ -34,8 +34,8 @@ public class TCFWatchpointTarget implements ICWatchpointTarget { } public String getExpression() { - final TCFDataCache<String> expressionText = fNode.getExpressionText(); - String expr = new TCFTask<String>(fNode.getChannel()) { + final TCFDataCache<String> expressionText = node.getExpressionText(); + String expr = new TCFTask<String>(node.getChannel()) { public void run() { if (!expressionText.validate(this)) return; done(expressionText.getData()); @@ -45,7 +45,7 @@ public class TCFWatchpointTarget implements ICWatchpointTarget { } public void getSize(final GetSizeRequest request) { - final TCFDataCache<ISymbols.Symbol> expressionType = fNode.getType(); + final TCFDataCache<ISymbols.Symbol> expressionType = node.getType(); Protocol.invokeLater(new Runnable() { public void run() { if (!expressionType.validate(this)) return; diff --git a/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/commands/AddWatchpointHandler.java b/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/commands/AddWatchpointHandler.java index e34a80fb3..8f6c7522e 100644 --- a/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/commands/AddWatchpointHandler.java +++ b/plugins/org.eclipse.tcf.cdt.ui/src/org/eclipse/tcf/internal/cdt/ui/commands/AddWatchpointHandler.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2011, 2014 Wind River Systems, Inc. and others. + * Copyright (c) 2011, 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 @@ -31,14 +31,16 @@ public class AddWatchpointHandler extends AbstractHandler { IToggleBreakpointsTargetCExtension cToggleTarget = null; if (toggleTarget instanceof IToggleBreakpointsTargetCExtension) { cToggleTarget = (IToggleBreakpointsTargetCExtension)toggleTarget; - } else { + } + else { CDebugUIPlugin.errorDialog("Cannot add watchpoint.", (Throwable) null); return null; } try { cToggleTarget.createWatchpointsInteractive(part, selection); - } catch (CoreException e) { + } + catch (CoreException e) { CDebugUIPlugin.errorDialog("Cannot add watchpoint.", e); } return null; |