Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ public ICommandBarContext? SelectedItem

field = value;
SetSelectedItem(value);

OnPropertyChanged(nameof(SelectedItem));
}
}

Expand Down Expand Up @@ -115,6 +117,10 @@ private void UpdateContextItems()
{
ShouldShowContextMenu = false;
}

OnPropertyChanged(nameof(HasSecondaryCommand));
OnPropertyChanged(nameof(SecondaryCommand));
OnPropertyChanged(nameof(ShouldShowContextMenu));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why we need to call this "ShouldShowContextMenu" twice?

}

// InvokeItemCommand is what this will be in Xaml due to source generator
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ protected override void FetchProperty(string propertyName)

Commands.ForEach(contextItem =>
{
contextItem.InitializeProperties();
contextItem.SlowInitializeProperties();
});
}
else
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ protected override void FetchProperty(string propertyName)
break;
case nameof(EmptyContent):
EmptyContent = new(new(model.EmptyContent), PageContext);
EmptyContent.InitializeProperties();
EmptyContent.SlowInitializeProperties();
break;
case nameof(IsLoading):
UpdateEmptyContent();
Expand All @@ -454,6 +454,8 @@ private void UpdateEmptyContent()
return;
}

UpdateProperty(nameof(EmptyContent));

DoOnUiThread(
() =>
{
Expand Down
Loading