private void OnSearchTextChanged() { using (MainWindow.Instance.PreventScintillaFocus()) { App.Logger.TraceExt("NotesViewHierarchical", "OnSearchTextChanged", Tuple.Create("SearchText", SearchText)); _filterData.Clear(); if (AllNotes != null) { ResyncDisplayItems(AllNotes); } SelectedFolder?.TriggerAllSubNotesChanged(); if (SelectedFolderPath != null && !SelectedFolder.IsSpecialNode_AllNotes && !SelectedFolder.AllSubNotes.Any() && DisplayItems.AllNotesViewWrapper != null) { App.Logger.TraceExt("NotesViewHierarchical", "OnSearchTextChanged (2)", Tuple.Create("SelectedFolderPath", SelectedFolderPath?.Formatted)); SelectedFolder = DisplayItems.AllNotesViewWrapper; } } }
private void OnRepoChanged(DependencyPropertyChangedEventArgs args) { App.Logger.Trace("NotesViewHierarchical", "OnRepoChanged()"); DisplayItems.ClearPermanents(); if (AllNotes != null) { ResyncDisplayItems(AllNotes); } SelectedFolder?.TriggerAllSubNotesChanged(); }
private void OnSettingsChanged(DependencyPropertyChangedEventArgs args) { App.Logger.Trace("NotesViewHierachical", "OnSettingsChanged()"); DisplayItems.ClearPermanents(); if (AllNotes != null) { ResyncDisplayItems(AllNotes); } if (args.NewValue != null && args.OldValue == null) { NotesViewFolderHeight = new GridLength(((AppSettings)args.NewValue).NotesViewFolderHeight); } SelectedFolder?.TriggerAllSubNotesChanged(); }