load bookmarks in document_open

This commit is contained in:
Sebastian Ramacher 2011-09-03 14:21:36 +02:00
parent 390061c896
commit cf3fd3510b
2 changed files with 5 additions and 8 deletions

View file

@ -53,12 +53,4 @@ void zathura_bookmark_free(zathura_bookmark_t* bookmark);
*/
bool zathura_bookmarks_load(zathura_t* zathura, const gchar* file);
/**
* Save bookmarks for a specific file.
* @param zathura The zathura instance.
* @param file The file.
* @param true on success, false otherwise
*/
bool zathura_bookmarks_save(zathura_t* zathura, const gchar* file);
#endif // BOOKMARKS_H

View file

@ -320,6 +320,11 @@ document_open(zathura_t* zathura, const char* path, const char* password)
gtk_widget_realize(page->event_box);
}
/* bookmarks */
if (!zathura_bookmarks_load(zathura, zathura->document->file_path)) {
girara_warning("Failed to load bookmarks for %s.\n", zathura->document->file_path);
}
return true;
error_free: