Index: AppSrc/VdfSplat.src
===================================================================
--- AppSrc/VdfSplat.src	(revision 71)
+++ AppSrc/VdfSplat.src	(revision 72)
@@ -201,30 +201,36 @@
       Function_Return bExists
     End_Function
     
+    Procedure doOpenProgram
+      Boolean bOpen
+      Handle  hoDialog
+      String  sApplication
+
+      Move (oOpenProgramDialog(Self)) To hoDialog
+   
+      Get Show_Dialog of hoDialog to bOpen
+      If bOpen Begin
+        Get File_Name of hoDialog To sApplication
+        Send DoSetCaptionLabel Of (oVdfDbg(oClientArea(Self))) sApplication
+        Set psApplication of ghoApplication To sApplication
+      End
+      Else Send Info_Box "You did not choose a file, nothing to debug."
+    End_Procedure
+    
     Procedure doDebugRun
-      String  sApplication
-      Boolean bOpen
       Boolean bExists
       Boolean bRestartMode
       Handle  hoDebug
       Handle  hoParent
-      Handle  hoDialog
+      String  sApplication
       
       Get psApplication of ghoApplication To sApplication
       If (sApplication = "") Begin
-        Move (oOpenProgramDialog(Self)) To hoDialog
-       
-          Get Show_Dialog of hoDialog to bOpen
-          If bOpen Begin
-            Get File_Name of hoDialog To sApplication
-            // Don't tell me when I selected a file, just do it.
-            //Send Info_Box ("Selected file " + sApplication)
-          End
-          Else Send Info_Box "You did not choose a file, nothing to debug."
-        
+        Send doOpenProgram
+        Get psApplication of ghoApplication To sApplication
       End
       If (sApplication="") Begin
-        // Oh still no app? Use our hardcoded path
+        // Oh still no app? Nothing to debug then
         Procedure_Return
       End
       Get ParseApplicationDebugFile sApplication To bExists
@@ -233,6 +239,9 @@
       If (hoDebug) Begin
         Get pbDebugRestart of hoDebug to bRestartMode
         If (bRestartMode) Begin
+          If (IsComObjectCreated(hoDebug)) Begin
+            Send ReleaseComObject of hoDebug
+          End
           Send Destroy of hoDebug
           Move 0 To hoDebug
         End
@@ -251,7 +260,6 @@
         Set psApplication of ghoApplication To sApplication
         Set ApplicationFileName of hoDebug To sApplication
         // ??
-        Send DoSetCaptionLabel Of (oVdfDbg(oClientArea(Self))) sApplication
         Send DoStartDebug
       End
     End_Procedure // doDebugRun
@@ -493,50 +501,17 @@
                 Set psCaption   to "&File"
                 Set psDescription to "Find, Save, Delete, Clear information or quit this application."
                 Set psCategory to "Menus"
-
-                Object oClearMenuItem is a cCJClearMenuItem
+                
+                Object oOpenProgramButton Is a cCJOpenProgramMenuItem
                     Set pbAddToDesignerMenu to True
                 End_Object
 
-                Object oClearAllMenu is a cCJClearAllMenuItem
-                    Set pbAddToDesignerMenu to True
-                End_Object
-
-                Object oPromptMenuItem is a cCJPromptMenuItem
-                    Set pbAddToDesignerMenu to True
-                    Set pbControlBeginGroup to True
-                End_Object
-
                 Object oCJDebugPauseMenuItem is a cCJDebugPauseMenuItem
                     Set pbAddToDesignerMenu to True
                     Set pbControlBeginGroup to True
                 End_Object
 
-                Object oFindNextMenu is a cCJFindNextMenuItem
-                    Set pbAddToDesignerMenu to True
-                End_Object
 
-                Object oFindPreviousMenu is a cCJFindPreviousMenuItem
-                    Set pbAddToDesignerMenu to True
-                End_Object
-
-                Object oFindFirstMenu is a cCJFindFirstMenuItem
-                    Set pbAddToDesignerMenu to True
-                End_Object
-
-                Object oFindLastMenu is a cCJFindLastMenuItem
-                    Set pbAddToDesignerMenu to True
-                End_Object
-
-                Object oSaveMenuItem is a cCJSaveMenuItem
-                    Set pbAddToDesignerMenu to True
-                    Set pbControlBeginGroup to True
-                End_Object
-
-                Object oDeleteMenuItem is a cCJDeleteMenuItem
-                    Set pbAddToDesignerMenu to True
-                End_Object
-
                 Object oExitMenu is a cCJExitMenuItem
                     Set pbControlBeginGroup to True
                 End_Object
@@ -671,9 +646,11 @@
         End_Object
 
         Object oDebugToolBar is a cCJToolbar
-            Set psTitle to "Debugging Toolbar"
+            Set psTitle To "Debugging Toolbar"
+            
+            Object oOpenProgramButton Is a cCJOpenProgramMenuItem
+            End_Object
 
-
             Object oStartDebugButton is a cCJStartDebugMenuItem
             End_Object
 
Index: AppSrc/cDebugCJMenuItemClasses.pkg
===================================================================
--- AppSrc/cDebugCJMenuItemClasses.pkg	(revision 71)
+++ AppSrc/cDebugCJMenuItemClasses.pkg	(revision 72)
@@ -414,7 +414,7 @@
 { OverrideProperty=psCaption InitialValue=CS_CaptionAddBreakpoint}
 { OverrideProperty=psToolTip InitialValue=CS_ToolTipAddBreakpoint}
 { OverrideProperty=psDescription InitialValue=CS_DescAddBreakpoint }
-{ OverrideProperty=psImage InitialValue="brkp_obj.ico" }
+{ OverrideProperty=psImage InitialValue="brkp_obj_red.ico" }
 Class cCJAddBreakpointMenuItem is a cCJDebugMenuItem
     
     Procedure Construct_Object
@@ -422,7 +422,7 @@
         Set psCaption       To CS_CaptionAddBreakpoint
         Set psToolTip       To CS_ToolTipAddBreakpoint
         Set psDescription   To CS_DescAddBreakpoint
-        Set psImage         To "brkp_obj.ico"
+        Set psImage         To "brkp_obj_red.ico"
         //Set psImageDisabled To "brkpd_obj.ico"
         Set piShortcutKey   To xtpKey_None VK_F9
     End_Procedure
@@ -540,3 +540,34 @@
     End_Function
     
 End_Class // cCJOpenFileMenuItem
+
+
+Define CS_CaptionOpenProgram   For "Open Program"
+Define CS_TooltipOpenProgram   For "Open executable file"
+Define CS_DescOpenProgram      For "Open executable file"
+
+{ OverrideProperty=psCaption InitialValue=CS_CaptionOpenProgram}
+{ OverrideProperty=psToolTip InitialValue=CS_ToolTipOpenProgram}
+{ OverrideProperty=psDescription InitialValue=CS_DescOpenProgram }
+{ OverrideProperty=psImage InitialValue="workset.ico" }
+Class cCJOpenProgramMenuItem is a cCJDebugMenuItem
+    
+    Procedure Construct_Object
+        Forward Send Construct_Object
+        Set psCaption       To CS_CaptionOpenProgram
+        Set psToolTip       To CS_ToolTipOpenProgram
+        Set psDescription   To CS_DescOpenProgram
+        Set psImage         To "workset.ico"
+    End_Procedure
+
+    Procedure OnExecute Variant vCommandBarControl
+        Send doOpenProgram
+    End_Procedure
+    
+    Function IsEnabled Returns Boolean
+      Boolean bStarted
+      Get HasProgramStarted To bStarted
+      Function_Return (bStarted=false)
+    End_Function
+    
+End_Class
Index: AppSrc/cDebuggerEngine.pkg
===================================================================
--- AppSrc/cDebuggerEngine.pkg	(revision 71)
+++ AppSrc/cDebuggerEngine.pkg	(revision 72)
@@ -495,6 +495,32 @@
     Function_Return iPos
   End_Function
 
+  
+  //
+  // Checks the breakpoint array to see if it has any breakpoints
+  // for the filename passed and returns them as line numbers if they
+  // do.
+  //
+  Function ListBreakPointsForFile String sFile Returns UInteger[]
+    Integer iPos
+    Integer iBreak
+    Integer iCount
+    UInteger iLine
+    UInteger[] Lines
+    tBreakPoints[] BP
+    
+    Move -1 To iPos
+    Move (ResizeArray(Lines,0)) To Lines
+    Get pBreakPoints To BP
+    Move (Lowercase(sFile)) To sFile
+    Move (SizeOfArray(BP)) To iCount
+    For iBreak from 0 To (iCount-1)
+      If (lowercase(BP[iBreak].sFileName)=sFile and BP[iBreak].bEnabled=True) Begin
+        Move BP[iBreak].iLine to Lines[SizeOfArray(Lines)]
+      End
+    Loop
+    Function_Return Lines
+  End_Function
 
   Procedure AddBreakPointToArray String sFile UInteger iLine
     Integer iCount
Index: AppSrc/cSplatCodeMax.pkg
===================================================================
--- AppSrc/cSplatCodeMax.pkg	(revision 71)
+++ AppSrc/cSplatCodeMax.pkg	(revision 72)
@@ -29,9 +29,9 @@
 Define CS_TAB     for (Character(9))
 
 
-Define ICO_Brkp_obj     for $CI01 // breakpoint object icon
+Define ICO_Inst_ptr_top for $CI01 // instruction pointer top icon
 Define ICO_Inst_ptr     for $CI02 // instruction pointer icon
-Define ICO_Inst_ptr_top for $CI04 // instruction pointer top icon
+Define ICO_Brkp_obj     for $CI04 // breakpoint object icon
 
 Class cCodeMaxImageList is a cImageList32
   
@@ -47,8 +47,8 @@
     Integer iVoid
   
     Get AddImage "brkp_obj.ico"     To iVoid // bit 1 // seems the first image is ignored as a margin image
-    Get AddImage "inst_ptr_top.ico" To iVoid // bit 2
-    Get AddImage "brkp_obj.ico"     To iVoid // bit 3
+    Get AddImage "inst_ptr_top_green.ico" To iVoid // bit 2
+    Get AddImage "brkp_obj_red.ico" To iVoid // bit 3
     Get AddImage "inst_ptr.ico"     To iVoid // bit 4
   End_Procedure
 End_Class
@@ -545,10 +545,23 @@
     Forward Send OnComSelChange
   End_Procedure
   
+  Procedure DisplayBreakPoints UInteger[] BreakPoints
+    Integer  iItem
+    Integer  iCount
+    UInteger iLine
+    
+    Move (SizeOfArray(BreakPoints)) To iCount
+    For iItem From 0 To (iCount-1)
+      Move BreakPoints[iItem] To iLine
+      Send ComSetMarginImages (iLine-1) ICO_Brkp_obj // 4
+    Loop
+  End_Procedure
   
   
   Procedure doOpenSourceFile String sFileName
-    String sLanguage
+    Handle  hoDebugger
+    String  sLanguage
+    UInteger[] BreakPoints
     Variant vLanguage
     
     Send ComOpenFile  sFileName
@@ -558,6 +571,12 @@
     Set ComReadOnly To True // NO changes allowed
     Set ComColorSyntax To True
     
+    Get phoDebugger To hoDebugger
+    If (hoDebugger) Begin
+      Get ListBreakPointsForFile Of hoDebugger sFileName To BreakPoints
+      Send DisplayBreakPoints BreakPoints
+    End
+    
     // Update view hosting our control
     //Send doSetCaptionLabel sFileName
   End_Procedure // doOpenSourceFile
@@ -568,8 +587,11 @@
     Boolean bVisible
     Boolean bScrollup
     
-    Move false to bScrollup
-    Send doOpenSourceFile sFileName
+    Move false To bScrollup
+    // not optimal, but wait on codemax retirement for optimizing this
+    //If (psFileName(Self)<>sFileName) Begin
+      Send doOpenSourceFile sFileName
+    //End
     Set piCurrentLine to iLine
     Move iLine to iTopMostLine
     If (iLine>5) Begin
