diff --git a/src/Views/Controls/Tree.cs b/src/Views/Controls/Tree.cs index ae2ed34f..95e6ecc5 100644 --- a/src/Views/Controls/Tree.cs +++ b/src/Views/Controls/Tree.cs @@ -164,6 +164,8 @@ namespace SourceGit.Views.Controls { } private void AddSelected(TreeItem item, bool removeOthers) { + if (!item.IsVisible) return; + if (removeOthers && Selected.Count > 0) { UnselectAllChildren(this); Selected.Clear();