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

SampleApp fix. BitmapFileFormat moved assemblies. #3785

Merged
merged 3 commits into from Mar 11, 2021

Conversation

azchohfi
Copy link
Contributor

Fixes Sample App

Sample app was failing to load .bind files that used, for example, the AlphaMode enum.

PR Type

What kind of change does this PR introduce?

  • Bugfix

What is the current behavior?

Using AlphaMode on .bind files doesn't load the sample properly.

What is the new behavior?

Using AlphaMode on .bind files now works.

PR Checklist

Please check if your PR fulfills the following requirements:

  • Tested code with current supported SDKs
  • Pull Request has been submitted to the documentation repository instructions. Link:
  • Sample in sample app has been added / updated (for bug fixes / features)
  • New major technical changes in the toolkit have or will be added to the Wiki e.g. build changes, source generators, testing infrastructure, sample creation changes, etc...
  • Tests for the changes have been added (for bug fixes / features) (if applicable)
  • Header has been added to all new source files (run build/UpdateHeaders.bat)
  • Contains NO breaking changes

@ghost
Copy link

ghost commented Feb 24, 2021

Thanks azchohfi for opening a Pull Request! The reviewers will test the PR and highlight if there is any conflict or changes required. If the PR is approved we will proceed to merge the pull request 🙌

@Rosuavio
Copy link
Contributor

Rosuavio commented Feb 24, 2021

Interesting, I am not noticing an issue with the SampleApp. I see that RadialGradientBrush, CameraHelper and CameraPreview are the only samples using that enum and I see no issues with those samples on master.

The existing implementation should allow the function to search threw Microsoft.Toolkit.Uwp.UI.Controls.Media where the type lives already. Even though it uses BitmapFileFormat.Bmp, both BitmapFileFormat and AlphaMode exists in the Microsoft.Toolkit.Uwp.UI.Controls.Media assembly. Personally I would like to look for a way to reference the assembly directly.

@michael-hawker michael-hawker added this to the 7.0 milestone Mar 2, 2021
@michael-hawker
Copy link
Member

Talked to @azchohfi about this. This may stem from the fact that we had references to Win2D before everywhere across the packages. So what we probably need is both values one for the Uwp.UI.Controls.Media package and one for the Uwp.UI.Media package?

azchohfi and others added 2 commits March 10, 2021 20:20
Co-authored-by: Michael Hawker MSFT (XAML Llama) <24302614+michael-hawker@users.noreply.github.com>
Copy link
Member

@michael-hawker michael-hawker left a comment

Choose a reason for hiding this comment

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

Tested this in my local bits for 7.0.0, doesn't hurt, wasn't sure which samples were failing specifically, but no harm in having both.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants