* updating the display name apparently is expensive */
const gchar* old_name = gtk_window_get_title (window);
+ if (display_name == NULL)
+ display_name = " ";
+
if (old_name && display_name && strcmp (old_name, display_name) == 0)
return; /* don't do anything */
/* This is usually used to change the title of the main window, which
* is the one that holds the folder view. Note that this change can
* happen even when the widget doesn't have the focus. */
- if (display_name)
- gtk_window_set_title (window, display_name);
- else
- gtk_window_set_title (window, " ");
+ gtk_window_set_title (window, display_name);
}