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 PivotPanel from returning "infinite" as desired height #1546

Merged
merged 1 commit into from
Sep 17, 2019

Conversation

carldebilly
Copy link
Member

GitHub Issue (If applicable): #

Bugfix

PivotPanel were returning the availablesize's Height as desired height, which is invalid when the available size is infinite.

This was causing a crash.

PR Checklist

Please check if your PR fulfills the following requirements:

  • Tested code with current supported SDKs
  • Docs have been added/updated which fit documentation template. (for bug fixes / features)
  • Unit Tests and/or UI Tests for the changes have been added (for bug fixes / features) (if applicable)
  • Wasm UI Tests are not showing unexpected any differences. Validate PR Screenshots Compare Test Run results.
  • Contains NO breaking changes
  • Updated the Release Notes
  • Associated with an issue (GitHub or internal)

@carldebilly carldebilly added kind/bug Something isn't working platform/wasm 🌐 Categorizes an issue or PR as relevant to the WebAssembly platform labels Sep 13, 2019
{
MeasureElement(child, availableSize);
if(child.DesiredSize.Height > maxHeight)
{
maxHeight = child.DesiredSize.Height;
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
maxHeight = child.DesiredSize.Height;
maxHeight = Math.Max(maxHeight, child.DesiredSize.Height);

Copy link
Contributor

@davidjohnoliver davidjohnoliver left a comment

Choose a reason for hiding this comment

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

Release notes, sample, test

@carldebilly carldebilly merged commit 8e16534 into master Sep 17, 2019
@carldebilly carldebilly deleted the dev/cdb/bugs/pivot-measurement branch September 17, 2019 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working platform/wasm 🌐 Categorizes an issue or PR as relevant to the WebAssembly platform
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants