mirror of
https://github.com/Microsoft/calculator.git
synced 2025-08-22 14:13:30 -07:00
check status before registering callback
This commit is contained in:
parent
8870e55edd
commit
c40191fe8b
1 changed files with 1 additions and 2 deletions
|
@ -188,10 +188,9 @@ void CurrencyDataLoader::ResetLoadStatus()
|
||||||
#pragma optimize("", off) // Turn off optimizations to work around DevDiv 393321
|
#pragma optimize("", off) // Turn off optimizations to work around DevDiv 393321
|
||||||
void CurrencyDataLoader::LoadData()
|
void CurrencyDataLoader::LoadData()
|
||||||
{
|
{
|
||||||
RegisterForNetworkBehaviorChanges();
|
|
||||||
|
|
||||||
if (!LoadFinished())
|
if (!LoadFinished())
|
||||||
{
|
{
|
||||||
|
RegisterForNetworkBehaviorChanges();
|
||||||
create_task([this]() -> task<bool> {
|
create_task([this]() -> task<bool> {
|
||||||
vector<function<future<bool>()>> loadFunctions = {
|
vector<function<future<bool>()>> loadFunctions = {
|
||||||
[this]() { return TryLoadDataFromCacheAsync(); },
|
[this]() { return TryLoadDataFromCacheAsync(); },
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue