forked from AuroraMiddleware/gtk
Allow not setting a changed callback on GtkBookmarksManager
This commit is contained in:
parent
489000ba9a
commit
eecda25d64
@ -152,7 +152,8 @@ save_bookmarks (GFile *bookmarks_file,
|
||||
static void
|
||||
notify_changed (GtkBookmarksManager *manager)
|
||||
{
|
||||
manager->changed_func (manager->changed_func_data);
|
||||
if (manager->changed_func)
|
||||
manager->changed_func (manager->changed_func_data);
|
||||
}
|
||||
|
||||
static void
|
||||
@ -193,8 +194,6 @@ _gtk_bookmarks_manager_new (GtkBookmarksChangedFunc changed_func, gpointer chang
|
||||
GFile *bookmarks_file;
|
||||
GError *error;
|
||||
|
||||
g_return_val_if_fail (changed_func != NULL, NULL);
|
||||
|
||||
manager = g_new0 (GtkBookmarksManager, 1);
|
||||
|
||||
manager->changed_func = changed_func;
|
||||
|
Loading…
Reference in New Issue
Block a user