Fix crash on switching branches with filter text
If there is some filter text in the line edit below project treeview, and you change a branch, the SortFilterProxyModel gets stuck in infinite recursion resulting in a crash.
The original bug reporter says that the crash happens even if there is no text in the filter LineEdit, but I haven't been able to reproduce that.