[ekiga] Fix error with recent gtk where error dialog box has empty text
- From: Eugen Dedu <ededu src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ekiga] Fix error with recent gtk where error dialog box has empty text
- Date: Wed, 24 Jul 2013 15:42:35 +0000 (UTC)
commit a951d94ccb73dc3e262fcb3028518b5c986813a4
Author: Eugen Dedu <Eugen Dedu pu-pm univ-fcomte fr>
Date: Wed Jul 24 17:40:39 2013 +0200
Fix error with recent gtk where error dialog box has empty text
The warnings shown to screen were:
(lt-ekiga:13496): GLib-GObject-WARNING **: invalid cast from `GtkBox' to `GtkLabel'
(lt-ekiga:13496): Gtk-CRITICAL **: gtk_label_set_markup: assertion `GTK_IS_LABEL (label)' failed
lib/engine/gui/gtk-frontend/main_window.cpp | 13 ++++++-------
1 files changed, 6 insertions(+), 7 deletions(-)
---
diff --git a/lib/engine/gui/gtk-frontend/main_window.cpp b/lib/engine/gui/gtk-frontend/main_window.cpp
index 0bb6cfd..3355822 100644
--- a/lib/engine/gui/gtk-frontend/main_window.cpp
+++ b/lib/engine/gui/gtk-frontend/main_window.cpp
@@ -632,15 +632,14 @@ static bool on_handle_errors (std::string error,
{
g_return_val_if_fail (data != NULL, false);
- GtkWidget *dialog = gtk_message_dialog_new (GTK_WINDOW (data),
- GTK_DIALOG_MODAL,
- GTK_MESSAGE_ERROR,
- GTK_BUTTONS_OK, NULL);
+ GtkWidget *dialog = gtk_message_dialog_new_with_markup (GTK_WINDOW (data),
+ GTK_DIALOG_MODAL,
+ GTK_MESSAGE_ERROR,
+ GTK_BUTTONS_OK,
+ error.c_str (),
+ NULL);
gtk_window_set_title (GTK_WINDOW (dialog), _("Error"));
- gtk_label_set_markup (GTK_LABEL (gtk_message_dialog_get_message_area (GTK_MESSAGE_DIALOG (dialog))),
- error.c_str ());
-
g_signal_connect_swapped (dialog, "response",
G_CALLBACK (gtk_widget_destroy),
dialog);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]