NavCategory | Partial refactor and perf optimization (#1820)

* Partially refactor NavCategory

* Lazy load the states of GraphingMode Category

* code cleanup

* find_if to any_of

* remove Windows.System

* resolve warning WMC1507

* resolve comments

* fix indentations
This commit is contained in:
Tian L 2022-04-18 14:10:15 +08:00 committed by GitHub
parent 6a5b93cab6
commit 8e7ac87f01
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
23 changed files with 913 additions and 981 deletions

View file

@ -203,7 +203,7 @@ namespace CalculatorApp
if (value != nullptr)
{
auto currentCategory = value->GetModelCategory();
IsCurrencyCurrentCategory = currentCategory.id == CalculatorApp::ViewModel::Common::NavCategory::Serialize(CalculatorApp::ViewModel::Common::ViewMode::Currency);
IsCurrencyCurrentCategory = currentCategory.id == CalculatorApp::ViewModel::Common::NavCategoryStates::Serialize(CalculatorApp::ViewModel::Common::ViewMode::Currency);
}
RaisePropertyChanged("CurrentCategory");
}