fix(ui): notify IsTasksEmptyRepoHintVisible on every list switch
IsTasksEmptyRepoHintVisible reads _currentList?.Kind directly, but Kind isn't itself observed — the NotifyPropertyChangedFor chain only fires when IsLetClaudeVisible's value actually changes. Switching from a Smart list to an empty User list without a WorkingDir changes Kind while IsLetClaudeVisible (and Has*) stay false in both, so the hint never notified and stayed stale.
This commit is contained in:
@@ -387,6 +387,13 @@ public sealed partial class TasksIslandViewModel : ViewModelBase, IDisposable
|
||||
if (_currentList is not null)
|
||||
_currentList.PropertyChanged += OnCurrentListPropertyChanged;
|
||||
|
||||
// IsTasksEmptyRepoHintVisible reads _currentList?.Kind directly, but Kind isn't itself an
|
||||
// observed property — the [NotifyPropertyChangedFor] chain only fires when IsLetClaudeVisible's
|
||||
// *value* changes. Switching between two lists that both resolve IsLetClaudeVisible to the
|
||||
// same bool (e.g. a Smart list -> an empty User list without a WorkingDir) changes Kind
|
||||
// without ever notifying, leaving the hint stale. Force it explicitly on every list switch.
|
||||
OnPropertyChanged(nameof(IsTasksEmptyRepoHintVisible));
|
||||
|
||||
Items.Clear();
|
||||
Rows.Clear();
|
||||
HasOverdue = false;
|
||||
|
||||
Reference in New Issue
Block a user