[nemiver] Disassemble breakpoint locations on demand



commit a33e25480976223b68039afe74c2c9ef330b0770
Author: Dodji Seketeli <dodji redhat com>
Date:   Sun Sep 5 17:42:21 2010 +0200

    Disassemble breakpoint locations on demand
    
    	* src/persp/dbgperspective/nmv-dbg-perspective.cc
    	(on_breakpoint_go_to_source_action): In disassembly mode, if the
    	user double clicks on a breakpoint descriptor in the status
    	notebook and if that breakpoint address is not within the range of
    	addresses currently displayed, disassemble the memory aroung the
    	breakpoint address and scroll to there.

 src/persp/dbgperspective/nmv-dbg-perspective.cc |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)
---
diff --git a/src/persp/dbgperspective/nmv-dbg-perspective.cc b/src/persp/dbgperspective/nmv-dbg-perspective.cc
index 70c865d..0c9f17c 100644
--- a/src/persp/dbgperspective/nmv-dbg-perspective.cc
+++ b/src/persp/dbgperspective/nmv-dbg-perspective.cc
@@ -1689,13 +1689,16 @@ DBGPerspective::on_breakpoint_go_to_source_action
                 source_editor->scroll_to_line (a_breakpoint.line ());
                 break;
             case SourceEditor::BUFFER_TYPE_ASSEMBLY:
-                source_editor->scroll_to_address
-                                        (a_breakpoint.address ());
+                if (source_editor->scroll_to_address
+                    (a_breakpoint.address ()) == false)
+                    source_editor = 0;
                 break;
             case SourceEditor::BUFFER_TYPE_UNDEFINED:
                 break;
         }
-    } else {
+    }
+
+    if (source_editor == 0) {
         IDebugger::DisassSlot scroll_to_address;
         scroll_to_address =
             sigc::bind (sigc::mem_fun



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]