Another situation which also needs to be handled is when the user himself has selected a directory and a file/directory directly/indirectly within it.
Another situation which also needs to be handled is when the user himself has selected a directory and a file/directory directly/indirectly within it.