diff --git a/debug/org.eclipse.cdt.debug.core/ChangeLog b/debug/org.eclipse.cdt.debug.core/ChangeLog index 63e0bac01b9..d0a9c23e0c5 100644 --- a/debug/org.eclipse.cdt.debug.core/ChangeLog +++ b/debug/org.eclipse.cdt.debug.core/ChangeLog @@ -1,3 +1,8 @@ +2005-02-02 Mikhail Khodjaiants + Fix for bug 84187: "Toggle Watchpoint" and "Toggle Method Breakpoint" don't work with C editor. + Added new "createWatchpoint" method that accepts position information. + * CDIDebugModel.java + 2005-01-19 Mikhail Khodjaiants Fix for bug 83051: Add global variables deletes existing ones when new added. * ICGlobalVariableManager.java diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/CDIDebugModel.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/CDIDebugModel.java index 2327eb3a86c..5fb4edbf9cb 100644 --- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/CDIDebugModel.java +++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/core/CDIDebugModel.java @@ -195,7 +195,6 @@ public class CDIDebugModel { attributes.put( IMarker.CHAR_START, new Integer( 0 ) ); attributes.put( IMarker.CHAR_END, new Integer( 0 ) ); attributes.put( IMarker.LINE_NUMBER, new Integer( -1 ) ); - attributes.put( IMarker.LINE_NUMBER, new Integer( -1 ) ); attributes.put( ICLineBreakpoint.ADDRESS, address.toHexAddressString() ); attributes.put( IBreakpoint.ENABLED, new Boolean( enabled ) ); attributes.put( ICBreakpoint.IGNORE_COUNT, new Integer( ignoreCount ) ); @@ -239,6 +238,53 @@ public class CDIDebugModel { return new CWatchpoint( resource, attributes, register ); } + /** + * Creates and returns a watchpoint for the source defined by the given + * source handle, at the given expression. The marker associated with the + * watchpoint will be created on the specified resource. + * + * @param sourceHandle the handle to the watchpoint source + * @param resource the resource on which to create the associated watchpoint marker + * @param charStart the first character index associated with the watchpoint, or + * -1 if unspecified, in the source file in which the watchpoint + * is set + * @param charEnd the last character index associated with the watchpoint, or -1 + * if unspecified, in the source file in which the watchpoint is + * set + * @param lineNumber the lineNumber on which the watchpoint is set, or -1 if + * unspecified - line numbers are 1 based, associated with the + * source file in which the watchpoint is set + * @param writeAccess whether this is write watchpoint + * @param readAccess whether this is read watchpoint + * @param expression the expression on which the watchpoint is set + * @param enabled whether to enable or disable this breakpoint + * @param ignoreCount the number of times this breakpoint will be ignored + * @param condition the breakpoint condition + * @param register whether to add this breakpoint to the breakpoint manager + * @return a watchpoint + * @throws CoreException if this method fails. Reasons include: + *