Skip to content

Conversation

@jaeheonshim
Copy link

There was an issue where the last read page was not remembered for PDFs with more than 1500 pages (See #689).

This is because if the document has more than MAX_ICON_VIEW_PAGE_COUNT pages (currently 1500), the tree_view is used instead of the icon_view. The ev_sidebar_tree_selection_changed handler is registered on the selection object of the tree view to update the current document page when the user changes the selection. However, when gtk_list_store_clear is called, such as when the sidebar is disposed, "changed" is also emitted, causing the document page to be updated and as a result the page is always set to 0 when the long document is closed.

I added a small amount of code to block this event handler while the list is being cleared, which seems to fix the issue.

…y to avoid accidentally rewriting the last viewed page number.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant