Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Pazderski2020-05-23 18:57:13 +0000
committerPaul Pazderski2020-06-09 09:19:53 +0000
commitbb562cb8c1b454e7914eb8c8f9ff6cf762c710b8 (patch)
tree66f88933097fd69e901401445ebcc8c7cb0699db
parentf1d8daec2fda7660657ab8753bbe4e560d7cd4a6 (diff)
downloadeclipse.platform.debug-bb562cb8c1b454e7914eb8c8f9ff6cf762c710b8.tar.gz
eclipse.platform.debug-bb562cb8c1b454e7914eb8c8f9ff6cf762c710b8.tar.xz
eclipse.platform.debug-bb562cb8c1b454e7914eb8c8f9ff6cf762c710b8.zip
Bug 344352 - [breakpoints] Error dialog when deleting a working set
In fact there is no issue with deleting working set but a regular user is most likely seeing this unnecessary error message from that action. Deleting working set give the option to remove the working set, all containing breakpoints or both. If removing breakpoints is unselected it will still perform a remove operation for zero markers and the standard remove-marker-operation will produce an error dialog because there are no markers to delete. Change-Id: If08c5f930bbdbf0236dd8a20af3f43b60b77d427 Signed-off-by: Paul Pazderski <paul-eclipse@ppazderski.de>
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/ui/DebugUITools.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/DebugUITools.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/DebugUITools.java
index 1f5a2675f..e934f3b93 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/DebugUITools.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/ui/DebugUITools.java
@@ -301,6 +301,13 @@ public class DebugUITools {
* @since 3.7
*/
public static void deleteBreakpoints(IBreakpoint[] breakpoints, final Shell shell, IProgressMonitor progressMonitor) throws CoreException {
+ if (breakpoints.length == 0) {
+ // Note: this is not only a small performance optimization but also the fix for
+ // bug 344352. When removing no breakpoints the DeleteMarkersOperation will show
+ // an error dialog about missing markers.
+ return;
+ }
+
IMarker[] markers= new IMarker[breakpoints.length];
int markerCount;
for (markerCount= 0; markerCount < breakpoints.length; markerCount++) {

Back to the top