Branch: refs/heads/master Author: Alexander Petukhov devel@apetukhov.ru Committer: Alexander Petukhov devel@apetukhov.ru Date: Thu, 12 Apr 2012 13:19:53 Commit: 2fb87402aabeab4b4893d4154457f910bcc350b7 https://github.com/geany/geany-plugins/commit/2fb87402aabeab4b4893d4154457f9...
Log Message: ----------- Merge pull request #29 from cesspit/debugger_bugfixing
Debugger bugfixing
Modified Paths: -------------- debugger/ChangeLog debugger/TODO debugger/src/callbacks.c debugger/src/dbm_gdb.c
Modified: debugger/ChangeLog 9 files changed, 9 insertions(+), 0 deletions(-) =================================================================== @@ -1,3 +1,12 @@ +08-04-2012 Alexander Petukhov devel@apetukhov.ru + + * fixed a bug with wrong error message when a breakpoint condition/hitscounr can't be set + * fixed a bug when gdb exits without a stop reason + +07-04-2012 Alexander Petukhov devel@apetukhov.ru + + * fixed a bug with calltips still being shown when a pointer leaves editor window + 04-04-2012 Alexander Petukhov devel@apetukhov.ru
* fixing exiting with code case that was unhandled and caused SIGSEGV (gdb)
Modified: debugger/TODO 36 files changed, 20 insertions(+), 16 deletions(-) =================================================================== @@ -1,23 +1,27 @@ BUGS: -- tooltip appears even if a pointer in no longer inside editor window
FEATURES: -- custom tooltip with sticking facilities -- don't hide a tooltip until run hasn't happent, move it if document is being scrolled -- use lexer to lookup for a symbol under cursor when presenting a tooltip -- geany menu integration -- toolbar buttons -- margin context menu -- step back -- tree views column width/autowidth -- attach functionality: dbm_ methods providing target lists, common dialog -- android support -- bashdb support -- windows support + +- debug callbacks names (refactoring) - gdb backend step speed -- debug callbacks names +- windows support + +- attach functionality: dbm_ methods providing target lists, common dialog - interrupt thread using stack window -- custom tooltip on breaks and stack trace windows with code snippet around break or frame +- step back + +- margin context menu +- editor context menu (add watch, add/remove breakpoint) + - font from the geany settings for a message window -- a button in the upper right path of a right notebook for a hiding/showing button panel - use left/right keys to collapse/expand in breakpoints tree +- use lexer to lookup for a symbol under cursor when presenting a tooltip +- a button in the upper right path of a right notebook for a hiding/showing button panel +- minimum width of the debug panel notebooks +- tree views column width/autowidth +- custom tooltip on breaks and stack trace windows with code snippet around break or frame +- custom tooltip(in an editor in debug mode) with sticking facilities +- don't hide a tooltip until run hasn't happent, move it if document is being scrolled + +- android support +- bashdb support
Modified: debugger/src/callbacks.c 24 files changed, 22 insertions(+), 2 deletions(-) =================================================================== @@ -155,6 +155,21 @@ void on_document_open(GObject *obj, GeanyDocument *doc, gpointer user_data) }
/* + * Handles mouse leave event to check if a calltip is still present and hides it if yes + */ +static gint leave_signal; +static gboolean on_mouse_leave(GtkWidget *widget, GdkEvent *event, gpointer user_data) +{ + ScintillaObject *so = (ScintillaObject*)widget; + if (scintilla_send_message (so, SCI_CALLTIPACTIVE, 0, 0)) + { + g_signal_handler_disconnect(G_OBJECT(widget), leave_signal); + scintilla_send_message (so, SCI_CALLTIPCANCEL, 0, 0); + } + return FALSE; +} + +/* * Occures on notify from editor. * Handles margin click to set/remove breakpoint */ @@ -194,7 +209,7 @@ gboolean on_editor_notify( { if (DBS_STOPPED != debug_get_state ()) break; - + /* get a word under the cursor */ GString *word = get_word_at_position(editor->sci, nt->position);
@@ -203,6 +218,7 @@ gboolean on_editor_notify( gchar *calltip = debug_get_calltip_for_expression(word->str); if (calltip) { + leave_signal = g_signal_connect(G_OBJECT(editor->sci), "leave-notify-event", G_CALLBACK(on_mouse_leave), NULL); scintilla_send_message (editor->sci, SCI_CALLTIPSHOW, nt->position, (long)calltip); } } @@ -216,7 +232,11 @@ gboolean on_editor_notify( if (DBS_STOPPED != debug_get_state ()) break;
- scintilla_send_message (editor->sci, SCI_CALLTIPCANCEL, 0, 0); + if (scintilla_send_message (editor->sci, SCI_CALLTIPACTIVE, 0, 0)) + { + g_signal_handler_disconnect(G_OBJECT(editor->sci), leave_signal); + scintilla_send_message (editor->sci, SCI_CALLTIPCANCEL, 0, 0); + } break; } case SCN_MODIFYATTEMPTRO:
Modified: debugger/src/dbm_gdb.c 5 files changed, 3 insertions(+), 2 deletions(-) =================================================================== @@ -497,7 +497,7 @@ static gboolean on_read_from_gdb(GIOChannel * src, GIOCondition cond, gpointer d else { /* somehow, sometimes there can be no stop reason */ - stop_reason = SR_END_STEPPING_RANGE; + stop_reason = SR_EXITED_NORMALLY; } if (SR_BREAKPOINT_HIT == stop_reason || SR_END_STEPPING_RANGE == stop_reason || SR_SIGNAL_RECIEVED == stop_reason) @@ -817,7 +817,6 @@ gboolean run(const gchar* file, const gchar* commandline, GList* env, GList *wit commands = add_to_queue(commands, NULL, command->str, error_message->str, TRUE);
g_string_free(command, TRUE); - g_string_free(error_message, TRUE);
if (bp->hitscount) { @@ -841,6 +840,8 @@ gboolean run(const gchar* file, const gchar* commandline, GList* env, GList *wit g_string_free(command, TRUE); }
+ g_string_free(error_message, TRUE); + bp_index++; biter = biter->next; }
@@ Diff output truncated at 100000 characters. @@
-------------- This E-Mail was brought to you by github_commit_mail.py (Source: TBD).