Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding file monitoring and the ability to recursively open folders #40

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

sjoblomj
Copy link
Contributor

@sjoblomj sjoblomj commented Sep 7, 2018

Introducing file and folder monitoring. Regardless if a single uri or a uri list was opened, Viewnior will now use file monitors to automatically update when related files are added, deleted or updated.

Also adding the optional ability to open folders recursively (i.e. open all images in a folder as well as its subfolders). This is done via a checkbox in the Open File / Open Folder dialogs. Where there used to be a GList *file_list that stored all opened files, there is now a GNode *tree that can be arbitrarily deep. When traversing the tree, it will go from image to image, possibly from one branch of the tree to another.

Adding an extensive test suite for the changed code. This can be run with ninja test. If a suitable tool, such as gcovr is installed, one can also generate a code coverage report with ninja coverage:

meson builddir -Db_coverage=true
cd builddir
ninja test
ninja coverage

gcovr reports that vnr-tree.c and vnr-file.c both have 100% line coverage and over 90% branch coverage.

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.

2 participants