Patch from Anders Betn�- enable changing breakpoints while debugging.
[phpeclipse.git] / net.sourceforge.phpeclipse.debug.core / src / net / sourceforge / phpdt / internal / debug / core / PHPDBGProxy.java
index a0ba1f6..4f665aa 100644 (file)
@@ -142,11 +142,14 @@ public class PHPDBGProxy {
   }
 
   protected void setBreakPoints() throws IOException, CoreException {
-    IBreakpoint[] breakpoints = DebugPlugin.getDefault().getBreakpointManager().getBreakpoints();
-    for (int i = 0; i < breakpoints.length; i++) {
-      addBreakpoint(breakpoints[i]);
-    }
-  }
+               IBreakpoint[] breakpoints = DebugPlugin.getDefault()
+                               .getBreakpointManager().getBreakpoints();
+               for (int i = 0; i < breakpoints.length; i++) {
+                       if (breakpoints[i].isEnabled()) {
+                               addBreakpoint(breakpoints[i]);
+                       }
+               }
+       }
 
   private String MapPath(PHPLineBreakpoint phpLBP) {
                IPath filename;
@@ -168,7 +171,7 @@ public class PHPDBGProxy {
                        }
                }
                if (pathtranslation && remote) {
-                       if (path.substring(0, 1).equals("/"))
+                       if (remoteSourcePath.toString().substring(0, 1).equals("/"))
                                path = path.replace('\\', '/');
                        else
                                path = path.replace('/', '\\');