Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prevent Dev Home crashing when widgets don't supply icons or screenshots #3868

Merged
merged 3 commits into from
Sep 18, 2024

Conversation

krschau
Copy link
Collaborator

@krschau krschau commented Sep 16, 2024

Summary of the pull request

Widget providers are required to supply icons and screenshots. However, if they don't, Dev Home shouldn't crash.
Simplify icon and screenshot services by just returning a brush. If we can't get the image to put in the brush, the image just won't show up.

References and relevant issues

Related to #2482

Detailed description of the pull request / Additional comments

Validation steps performed

PR checklist

  • Closes #xxx
  • Tests added/passed
  • Documentation updated

}

private Grid BuildNavItem(BitmapImage image, string text)
private async Task<Grid> BuildNavItem(ComSafeWidgetDefinition widgetDefinition)
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
private async Task<Grid> BuildNavItem(ComSafeWidgetDefinition widgetDefinition)
private async Task<Grid> BuildNavItemAsync(ComSafeWidgetDefinition widgetDefinition)

@AmelBawa-msft AmelBawa-msft added the Needs-Second Pull request that needs another approval label Sep 16, 2024
@krschau krschau merged commit f46a9b5 into main Sep 18, 2024
4 checks passed
@krschau krschau deleted the user/krschau/file-not-found-widgets branch September 18, 2024 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs-Second Pull request that needs another approval
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants