mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
If there are no marked days on Windows the dense calendar crashes
If there are no marked days in the dense calendar add a blank one. Also make sure all pending events are processed be fore returning as the treeview did not always populate correctly.
This commit is contained in:
parent
4f9716362c
commit
9253b50210
@ -1234,6 +1234,17 @@ populate_hover_window(GncDenseCal *dcal, gint doc)
|
||||
gtk_list_store_set(model, &iter, 0, (gdcmd->name ? gdcmd->name : _("(unnamed)")), 1, gdcmd->info, -1);
|
||||
}
|
||||
|
||||
// if there are no rows, add one
|
||||
if (gtk_tree_model_iter_n_children (GTK_TREE_MODEL(model), NULL) == 0)
|
||||
{
|
||||
GtkTreeIter iter;
|
||||
gtk_list_store_insert(model, &iter, -1);
|
||||
}
|
||||
|
||||
// make sure all pending events are processed
|
||||
while(gtk_events_pending())
|
||||
gtk_main_iteration();
|
||||
|
||||
g_date_free(date);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user