[grilo] test-ui: Inform about cancelled operations
- From: Juan A. Suarez Romero <jasuarez src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [grilo] test-ui: Inform about cancelled operations
- Date: Tue, 8 Feb 2011 15:39:57 +0000 (UTC)
commit 482a779ac5b7bd81953bf48136d078dd5500a36c
Author: Juan A. Suarez Romero <jasuarez igalia com>
Date: Tue Feb 8 12:49:19 2011 +0000
test-ui: Inform about cancelled operations
Signed-off-by: Juan A. Suarez Romero <jasuarez igalia com>
tools/grilo-test-ui/main.c | 16 ++++++++++++++--
1 files changed, 14 insertions(+), 2 deletions(-)
---
diff --git a/tools/grilo-test-ui/main.c b/tools/grilo-test-ui/main.c
index 6d15117..b1e66b7 100644
--- a/tools/grilo-test-ui/main.c
+++ b/tools/grilo-test-ui/main.c
@@ -475,7 +475,13 @@ metadata_cb (GrlMediaSource *source,
view->metadata_model);
if (error) {
- g_critical ("Error: %s", error->message);
+ if (g_error_matches (error,
+ GRL_CORE_ERROR,
+ GRL_CORE_ERROR_OPERATION_CANCELLED)) {
+ GRL_DEBUG ("Operation cancelled");
+ } else {
+ g_critical ("Error: %s", error->message);
+ }
return;
}
@@ -556,7 +562,13 @@ browse_search_query_cb (GrlMediaSource *source,
guint next_op_id;
if (error) {
- g_critical ("Error: %s", error->message);
+ if (g_error_matches (error,
+ GRL_CORE_ERROR,
+ GRL_CORE_ERROR_OPERATION_CANCELLED)) {
+ GRL_DEBUG ("Operation cancelled");
+ } else {
+ g_critical ("Error: %s", error->message);
+ }
}
state->count++;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]