Commit fa90bc83 authored by Andre Miranda's avatar Andre Miranda

Safer code

parent f1c4a91b
......@@ -337,11 +337,13 @@ thunar_dialogs_show_error (gpointer parent,
if (G_LIKELY (error != NULL))
gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog), "%s.", error->message);
children = gtk_container_get_children (GTK_CONTAINER (gtk_message_dialog_get_message_area (dialog)));
children = gtk_container_get_children (
GTK_CONTAINER (gtk_message_dialog_get_message_area (GTK_MESSAGE_DIALOG (dialog))));
/* the assumption here is that all children are labels */
/* enable wrap for labels */
for (lp = children; lp != NULL; lp = lp->next)
gtk_label_set_line_wrap_mode (GTK_LABEL (lp->data), PANGO_WRAP_WORD_CHAR);
if (GTK_IS_LABEL (lp->data))
gtk_label_set_line_wrap_mode (GTK_LABEL (lp->data), PANGO_WRAP_WORD_CHAR);
/* display the dialog */
gtk_dialog_run (GTK_DIALOG (dialog));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment