[gnome-builder] search: add some debug code
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] search: add some debug code
- Date: Wed, 17 Dec 2014 10:46:36 +0000 (UTC)
commit ab1e807af662b066638d81e6903ce59eba2d169a
Author: Christian Hergert <christian hergert me>
Date: Sun Dec 14 21:15:13 2014 -0800
search: add some debug code
src/search/gb-search-context.c | 4 ++++
src/search/gb-search-display.c | 25 ++++++++++++++++++++++---
2 files changed, 26 insertions(+), 3 deletions(-)
---
diff --git a/src/search/gb-search-context.c b/src/search/gb-search-context.c
index 9ec5d34..0b85cec 100644
--- a/src/search/gb-search-context.c
+++ b/src/search/gb-search-context.c
@@ -160,6 +160,8 @@ gb_search_context_add_results (GbSearchContext *context,
GList *results,
gboolean finished)
{
+ ENTRY;
+
g_return_if_fail (GB_IS_SEARCH_CONTEXT (context));
g_return_if_fail (GB_IS_SEARCH_PROVIDER (provider));
@@ -167,6 +169,8 @@ gb_search_context_add_results (GbSearchContext *context,
g_signal_emit (context, gSignals [RESULTS_ADDED], 0,
provider, results, finished);
+
+ EXIT;
}
const gchar *
diff --git a/src/search/gb-search-display.c b/src/search/gb-search-display.c
index aaa44f7..f30d6b3 100644
--- a/src/search/gb-search-display.c
+++ b/src/search/gb-search-display.c
@@ -16,8 +16,11 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+#define G_LOG_DOMAIN "search-display"
+
#include <glib/gi18n.h>
+#include "gb-log.h"
#include "gb-search-display.h"
#include "gb-search-provider.h"
@@ -54,13 +57,19 @@ gb_search_display_results_added (GbSearchDisplay *display,
{
GList *iter;
+ ENTRY;
+
g_return_if_fail (GB_IS_SEARCH_DISPLAY (display));
g_return_if_fail (GB_IS_SEARCH_PROVIDER (provider));
for (iter = results; iter; iter = iter->next)
- gtk_list_box_insert (display->priv->list_box, iter->data, -1);
+ {
+ gtk_list_box_insert (display->priv->list_box, iter->data, -1);
+ }
gtk_list_box_invalidate_sort (display->priv->list_box);
+
+ EXIT;
}
static void
@@ -71,6 +80,8 @@ gb_search_display_connect (GbSearchDisplay *display,
const GList *list;
const GList *iter;
+ ENTRY;
+
g_return_if_fail (GB_IS_SEARCH_DISPLAY (display));
g_return_if_fail (GB_IS_SEARCH_CONTEXT (context));
@@ -83,11 +94,11 @@ gb_search_display_connect (GbSearchDisplay *display,
G_CONNECT_SWAPPED);
list = gb_search_context_get_results (context);
-
for (iter = list; iter; iter = iter->next)
gtk_list_box_insert (priv->list_box, iter->data, -1);
-
gtk_list_box_invalidate_sort (display->priv->list_box);
+
+ EXIT;
}
static void
@@ -98,6 +109,8 @@ gb_search_display_disconnect (GbSearchDisplay *display,
GList *children;
GList *iter;
+ ENTRY;
+
g_return_if_fail (GB_IS_SEARCH_DISPLAY (display));
g_return_if_fail (GB_IS_SEARCH_CONTEXT (context));
@@ -111,12 +124,16 @@ gb_search_display_disconnect (GbSearchDisplay *display,
for (iter = children; iter; iter = iter->next)
gtk_container_remove (GTK_CONTAINER (priv->list_box), iter->data);
g_list_free (children);
+
+ EXIT;
}
void
gb_search_display_set_context (GbSearchDisplay *display,
GbSearchContext *context)
{
+ ENTRY;
+
g_return_if_fail (GB_IS_SEARCH_DISPLAY (display));
g_return_if_fail (!context || GB_IS_SEARCH_CONTEXT (context));
@@ -137,6 +154,8 @@ gb_search_display_set_context (GbSearchDisplay *display,
g_object_notify_by_pspec (G_OBJECT (display),
gParamSpecs [PROP_CONTEXT]);
}
+
+ EXIT;
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]