Branch: refs/heads/master Author: Dimitar Zhekov dimitar.zhekov@gmail.com Committer: Dimitar Zhekov dimitar.zhekov@gmail.com Date: Sun, 23 Dec 2012 16:22:36 UTC Commit: a8349f057f3d6359657776256a3aa4cecfb926a6 https://github.com/geany/geany-plugins/commit/a8349f057f3d6359657776256a3aa4...
Log Message: ----------- scope - option to keep exec marker and Threads location on resume
Modified Paths: -------------- scope/ChangeLog scope/NEWS scope/docs/scope.html scope/src/prefs.c scope/src/prefs.h scope/src/scope.c scope/src/thread.c
Modified: scope/ChangeLog 8 files changed, 8 insertions(+), 0 deletions(-) =================================================================== @@ -1,3 +1,11 @@ +2012-12-23 Dimitar Zhekov dimitar.zhekov@gmail.com + + * docs/scope.html, src/prefs.c, src/prefs.h, src/thread.c: + Added option "keep_exec_point" to keep the execution point marker + and Threads location columns when a thread execution is resumed. + * docs/scope.html, src/scope.c: + Increased version to 0.78. + 2012-12-22 Dimitar Zhekov dimitar.zhekov@gmail.com
* NEWS:
Modified: scope/NEWS 5 files changed, 5 insertions(+), 0 deletions(-) =================================================================== @@ -1,3 +1,8 @@ +Scope 0.78 (2012-12-23) + + * Added option "keep_exec_point" to keep the execution point marker + and Threads location columns when a thread execution is resumed. + Scope 0.77 (2012-12-16)
* Support for " and \ in evaluate expressions.
Modified: scope/docs/scope.html 7 files changed, 5 insertions(+), 2 deletions(-) =================================================================== @@ -477,7 +477,10 @@ asynchronous break messages. If true, only <tt>=breakpoint-deleted</tt> will be handled.</p>
<p><em>auto_view_source</em> - seek in source on single click in threads, breakpoints -and stack. Default = Off</p> +and stack.</p> + +<p><em>keep_exec_point</em> - do not clear the execution point marker and <em>Threads</em> +location columns when a thread execution is resumed.</p>
<p><em>visual_beep_length</em> - hundreds of seconds to flash the state label on Scope errors. Default = 25.</p> @@ -670,7 +673,7 @@
<b><a name="copyright">Copyright</a></b>
-<p>Scope 0.77, Copyright (C) 2012 Dimitar Toshkov Zhekov</p> +<p>Scope 0.78, Copyright (C) 2012 Dimitar Toshkov Zhekov</p>
<p>The menu and toolbar icons are from <a href="http://netbeans.org">Netbeans</a>, except for BreakPoint.</p>
Modified: scope/src/prefs.c 2 files changed, 2 insertions(+), 0 deletions(-) =================================================================== @@ -36,6 +36,7 @@ #endif
gboolean pref_auto_view_source; +gboolean pref_keep_exec_point; gint pref_visual_beep_length; #ifdef G_OS_UNIX gboolean pref_debug_console_vte; @@ -271,6 +272,7 @@ void prefs_init(void) stash_group_add_boolean(group, &pref_async_break_bugs, "async_break_bugs", TRUE); #endif stash_group_add_boolean(group, &pref_auto_view_source, "auto_view_source", FALSE); + stash_group_add_boolean(group, &pref_keep_exec_point, "keep_exec_point", FALSE); stash_group_add_integer(group, &pref_visual_beep_length, "visual_beep_length", 25); #ifdef G_OS_UNIX stash_group_add_boolean(group, &pref_debug_console_vte, "debug_console_vte", TRUE);
Modified: scope/src/prefs.h 1 files changed, 1 insertions(+), 0 deletions(-) =================================================================== @@ -29,6 +29,7 @@ #endif
extern gboolean pref_auto_view_source; +extern gboolean pref_keep_exec_point; extern gint pref_visual_beep_length; #ifdef G_OS_UNIX extern gboolean pref_debug_console_vte;
Modified: scope/src/scope.c 2 files changed, 1 insertions(+), 1 deletions(-) =================================================================== @@ -32,7 +32,7 @@ PLUGIN_VERSION_CHECK(215)
PLUGIN_SET_TRANSLATABLE_INFO(LOCALEDIR, GETTEXT_PACKAGE, _("Scope Debugger"), - _("Simple GDB front-end."), "0.77" , "Dimitar Toshkov Zhekov dimitar.zhekov@gmail.com") + _("Simple GDB front-end."), "0.78" , "Dimitar Toshkov Zhekov dimitar.zhekov@gmail.com")
/* Keybinding(s) */ enum
Modified: scope/src/thread.c 24 files changed, 13 insertions(+), 11 deletions(-) =================================================================== @@ -211,17 +211,19 @@ static void thread_iter_unmark(GtkTreeIter *iter, gpointer gdata) gtk_tree_model_get(model, iter, THREAD_FILE, &file, THREAD_LINE, &line, THREAD_STATE, &state, -1); stopped = !strcmp(state, STOPPED); - thread_prompt += gdata ? !stopped : -stopped; - utils_mark(file, line, FALSE, MARKER_EXECUTE); + thread_prompt += gdata ? -stopped : !stopped; + + if (GPOINTER_TO_INT(gdata) != 2) + utils_mark(file, line, FALSE, MARKER_EXECUTE); }
static void thread_iter_running(GtkTreeIter *iter, const char *tid) { - thread_iter_unmark(iter, NULL); + thread_iter_unmark(iter, GINT_TO_POINTER(TRUE + pref_keep_exec_point));
- gtk_list_store_set(store, iter, THREAD_FILE, NULL, THREAD_LINE, 0, THREAD_STATE, - RUNNING, THREAD_BASE_NAME, NULL, THREAD_FUNC, NULL, THREAD_ADDR, NULL, - THREAD_CORE, NULL, -1); + gtk_list_store_set(store, iter, THREAD_STATE, RUNNING, pref_keep_exec_point ? -1 : + THREAD_FILE, NULL, THREAD_LINE, 0, THREAD_BASE_NAME, NULL, THREAD_FUNC, NULL, + THREAD_ADDR, NULL, THREAD_CORE, NULL, -1);
if (thread_id) { @@ -279,7 +281,7 @@ static void thread_parse_frame(GArray *frame, const char *tid, GtkTreeIter *iter if (!loc.addr) loc.addr = "??";
- thread_iter_unmark(iter, GINT_TO_POINTER(TRUE)); + thread_iter_unmark(iter, NULL); gtk_list_store_set(store, iter, THREAD_FILE, loc.file, THREAD_LINE, loc.line, THREAD_STATE, STOPPED, THREAD_BASE_NAME, loc.base_name, THREAD_FUNC, loc.func, THREAD_ADDR, loc.addr, -1); @@ -467,7 +469,7 @@ void on_thread_exited(GArray *nodes) { gboolean was_selected = !g_strcmp0(tid, thread_id);
- thread_iter_unmark(&iter, NULL); + thread_iter_unmark(&iter, GINT_TO_POINTER(TRUE)); gtk_list_store_remove(store, &iter); if (was_selected && thread_select_on_exited) auto_select_thread(); @@ -557,7 +559,7 @@ void threads_mark(GeanyDocument *doc)
void threads_clear(void) { - model_foreach(model, (GFunc) thread_iter_unmark, NULL); + model_foreach(model, (GFunc) thread_iter_unmark, GINT_TO_POINTER(TRUE)); array_clear(thread_groups, (GFreeFunc) thread_group_free); gtk_list_store_clear(store); thread_count = 0; @@ -829,8 +831,8 @@ void thread_init(void) GTK_TREE_VIEW_COLUMN(get_object("thread_base_name_column")));
thread_groups = array_new(ThreadGroup, 0x10); - RUNNING = _("running"); - STOPPED = _("stopped"); + RUNNING = _("Running"); + STOPPED = _("Stopped"); g_signal_connect(tree, "key-press-event", G_CALLBACK(on_view_key_press), thread_seek_selected); g_signal_connect(tree, "button-press-event", G_CALLBACK(on_view_button_1_press),
-------------- This E-Mail was brought to you by github_commit_mail.py (Source: TBD).
plugins-commits@lists.geany.org