diff options
Diffstat (limited to 'src/ui/message.c')
-rw-r--r-- | src/ui/message.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/src/ui/message.c b/src/ui/message.c index c6a395e..c358e73 100644 --- a/src/ui/message.c +++ b/src/ui/message.c | |||
@@ -50,14 +50,14 @@ handle_file_button_click(GtkButton *button, | |||
50 | MESSENGER_Application *app = (MESSENGER_Application*) user_data; | 50 | MESSENGER_Application *app = (MESSENGER_Application*) user_data; |
51 | 51 | ||
52 | UI_MESSAGE_Handle* handle = (UI_MESSAGE_Handle*) ( | 52 | UI_MESSAGE_Handle* handle = (UI_MESSAGE_Handle*) ( |
53 | bindings_get(app->bindings, button) | 53 | g_object_get_qdata(G_OBJECT(button), app->quarks.ui) |
54 | ); | 54 | ); |
55 | 55 | ||
56 | if (!handle) | 56 | if (!handle) |
57 | return; | 57 | return; |
58 | 58 | ||
59 | struct GNUNET_CHAT_File *file = (struct GNUNET_CHAT_File*) ( | 59 | struct GNUNET_CHAT_File *file = (struct GNUNET_CHAT_File*) ( |
60 | bindings_get(app->bindings, handle->file_progress_bar) | 60 | g_object_get_qdata(G_OBJECT(handle->file_progress_bar), app->quarks.data) |
61 | ); | 61 | ); |
62 | 62 | ||
63 | if (!file) | 63 | if (!file) |
@@ -360,7 +360,7 @@ ui_message_new(MESSENGER_Application *app, | |||
360 | gtk_builder_get_object(handle->builder[1], "file_status_image") | 360 | gtk_builder_get_object(handle->builder[1], "file_status_image") |
361 | ); | 361 | ); |
362 | 362 | ||
363 | bindings_put(app->bindings, handle->file_button, handle); | 363 | g_object_set_qdata(G_OBJECT(handle->file_button), app->quarks.ui, handle); |
364 | 364 | ||
365 | handle->preview_drawing_area = GTK_DRAWING_AREA( | 365 | handle->preview_drawing_area = GTK_DRAWING_AREA( |
366 | gtk_builder_get_object(handle->builder[1], "preview_drawing_area") | 366 | gtk_builder_get_object(handle->builder[1], "preview_drawing_area") |
@@ -444,13 +444,13 @@ ui_message_update(UI_MESSAGE_Handle *handle, | |||
444 | } | 444 | } |
445 | else | 445 | else |
446 | file = (struct GNUNET_CHAT_File*) ( | 446 | file = (struct GNUNET_CHAT_File*) ( |
447 | bindings_get(app->bindings, handle->message_box) | 447 | g_object_get_qdata(G_OBJECT(handle->message_box), app->quarks.data) |
448 | ); | 448 | ); |
449 | 449 | ||
450 | if (!file) | 450 | if (!file) |
451 | return; | 451 | return; |
452 | 452 | ||
453 | bindings_put(app->bindings, handle->message_box, file); | 453 | g_object_set_qdata(G_OBJECT(handle->message_box), app->quarks.data, file); |
454 | 454 | ||
455 | uint64_t size = GNUNET_CHAT_file_get_size(file); | 455 | uint64_t size = GNUNET_CHAT_file_get_size(file); |
456 | uint64_t local_size = GNUNET_CHAT_file_get_local_size(file); | 456 | uint64_t local_size = GNUNET_CHAT_file_get_local_size(file); |
@@ -519,7 +519,11 @@ file_content: | |||
519 | 519 | ||
520 | gtk_revealer_set_reveal_child(handle->file_revealer, TRUE); | 520 | gtk_revealer_set_reveal_child(handle->file_revealer, TRUE); |
521 | 521 | ||
522 | bindings_put(app->bindings, handle->file_progress_bar, file); | 522 | g_object_set_qdata( |
523 | G_OBJECT(handle->file_progress_bar), | ||
524 | app->quarks.data, | ||
525 | file | ||
526 | ); | ||
523 | } | 527 | } |
524 | 528 | ||
525 | void | 529 | void |