Fix DataTable crash on resize when columns don't fit#599
Conversation
08c2fbf to
3eadb5a
Compare
Head branch was pushed to by a user without write access
1c52238 to
6cc6525
Compare
6cc6525 to
dc8741a
Compare
0d73135 to
65d4c84
Compare
Head branch was pushed to by a user without write access
65d4c84 to
075b815
Compare
11f292a to
6ac81c4
Compare
6ac81c4 to
e375d9a
Compare
e375d9a to
6aab97d
Compare
Suggested in code review, see !599 Co-authored-by: Andrii Chebukin <XperiAndri@Outlook.com>
6aab97d to
e89df6e
Compare
|
@Arlodotexe, @michael-hawker, @xperiandri Could you please take a look at this MR when you have time? It's been reviewed a while ago, but seems to be stuck because of missing pipeline checks. |
Apply PR Feedback
|
@pcfist sorry about that, GitHub holds things for new contributors. FYI @Arlodotexe. I've checked this locally. Saw it again and thought I remember seeing a fix before. We'll get this merged today. Thanks for the contribution! 🦙❤️ |
|
When will the DataTable be avaliable? The bug is still there because it's in the lab for a old version. @michael-hawker @Arlodotexe |
|
@hoshiizumiya Labs packages are available on NuGet now, so you should be able to grab it from there, the packages are relatively new so they should contain this fix. |
|
@michael-hawker It has no update since 2023. Wait a minute, Why haven't I detected any updates? I just noticed that I need to check on prerelease box. Thank you anyway. But the crash bug wasn't fixed😕 |
|
@hoshiizumiya ah yes, pre-release checkbox is a must. Surprised there's any packages showing up otherwise on the feed as they should go stale and fall off, maybe an old local cache? Anyway, if there's still an issue, please file a new bug with reproduction steps, could be a slightly different scenario than this one. Thanks! |
DataTablesometimes crashes on resize, typically when it gets narrow enough for its columns not to fit. Crash happens inMeasureOverridebecause of negative value passed toSizector.The easiest way to reproduce is to set
DataTable'sHorizontalAlignmenttoLeftto disable "stretching" behavior. The following code snippet may be used (slightly modified version ofDataTableSample.xaml):This PR adds a check to make sure width value used in
MeasureOverride()are non-negative.