fix an issue where tabs would not be closed when their parent folders we...

Fix an issue where tabs would not be closed when their parent folders were deleted (fixes #917).

@dinhviethoa