You have a small diretory structure:
A
+ Sub A
In folder tree of XnView browser:
1. Double-click on Folder "A" to open it
2. Double-click on Folder "Sub A" to open it
3. Click on folder name of Folder "A"
4. Then click on "-" to close folder "A"
-> Folder "A" closes, but after a short instant it opens, again.

Step 3 & 4 have to be performed quickly after each other.
This problem is surely related with the delayed opening of folders. The delayed opening is good, but should be applied when navigating with the keyboard, only. For selection with mouse, the folder should open immediately.
XnView 1.82 -