Commit 28444e9
msftbot[bot]
Switch ColorPicker to Derive from WinUI Controls (#4010)
## Fixes #
Fixes some potential crashes with the built-in Windows 10 ColorSpectrum by switching to the WinUI version instead with the latest bug fixes.
* ColorPicker and ColorSpectrum now derive from the WinUI equivalent controls
<!-- Add a brief overview here of the feature/bug & fix. -->
## PR Type
What kind of change does this PR introduce?
<!-- Please uncomment one or more that apply to this PR. -->
- Bugfix
<!-- - Feature -->
<!-- - Code style update (formatting) -->
- Refactoring (no functional changes, no api changes)
<!-- - Build or CI related changes -->
<!-- - Documentation content changes -->
<!-- - Sample app changes -->
<!-- - Other... Please describe: -->
## What is the current behavior?
<!-- Please describe the current behavior that you are modifying, or link to a relevant issue. -->
## What is the new behavior?
<!-- Describe how was this issue resolved or changed? -->
## PR Checklist
Please check if your PR fulfills the following requirements:
- [x] Tested code with current [supported SDKs](../readme.md#supported)
- [ ] ~Pull Request has been submitted to the documentation repository [instructions](..\contributing.md#docs). Link:~ <!-- docs PR link -->
- [ ] ~Sample in sample app has been added / updated (for bug fixes / features)~
- [ ] ~Icon has been created (if new sample) following the [Thumbnail Style Guide and templates](https://github.com/windows-toolkit/WindowsCommunityToolkit-design-assets)~
- [ ] ~New major technical changes in the toolkit have or will be added to the [Wiki](https://github.com/windows-toolkit/WindowsCommunityToolkit/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
**Anyone customizing the Spectrum shape or components directly in C# will need to switch to Microsoft.UI.Xaml namespace**
<!-- If this PR contains a breaking change, please describe the impact and migration path for existing applications below.
Please note that breaking changes are likely to be rejected within minor release cycles or held until major versions. -->
## Other information
See discussion in #3943 #3943 (comment)File tree
3 files changed
+31
-28
lines changed- Microsoft.Toolkit.Uwp.UI.Controls.Input/ColorPicker
3 files changed
+31
-28
lines changedLines changed: 11 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
18 | 19 | | |
19 | 20 | | |
20 | 21 | | |
| |||
52 | 53 | | |
53 | 54 | | |
54 | 55 | | |
55 | | - | |
| 56 | + | |
56 | 57 | | |
57 | 58 | | |
58 | 59 | | |
| |||
122 | 123 | | |
123 | 124 | | |
124 | 125 | | |
| 126 | + | |
125 | 127 | | |
126 | 128 | | |
127 | 129 | | |
| |||
486 | 488 | | |
487 | 489 | | |
488 | 490 | | |
489 | | - | |
490 | | - | |
| 491 | + | |
| 492 | + | |
491 | 493 | | |
492 | 494 | | |
493 | 495 | | |
494 | 496 | | |
495 | 497 | | |
496 | | - | |
497 | | - | |
| 498 | + | |
| 499 | + | |
498 | 500 | | |
499 | 501 | | |
500 | 502 | | |
501 | 503 | | |
502 | 504 | | |
503 | | - | |
504 | | - | |
| 505 | + | |
| 506 | + | |
505 | 507 | | |
506 | 508 | | |
507 | 509 | | |
| |||
1125 | 1127 | | |
1126 | 1128 | | |
1127 | 1129 | | |
1128 | | - | |
| 1130 | + | |
1129 | 1131 | | |
1130 | 1132 | | |
1131 | 1133 | | |
| |||
1226 | 1228 | | |
1227 | 1229 | | |
1228 | 1230 | | |
1229 | | - | |
| 1231 | + | |
1230 | 1232 | | |
1231 | 1233 | | |
1232 | 1234 | | |
| |||
Lines changed: 19 additions & 18 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
| 8 | + | |
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
| |||
120 | 121 | | |
121 | 122 | | |
122 | 123 | | |
123 | | - | |
124 | | - | |
125 | | - | |
126 | | - | |
127 | | - | |
128 | | - | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | | - | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | | - | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
140 | 141 | | |
141 | 142 | | |
142 | 143 | | |
| |||
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
145 | | - | |
| 145 | + | |
146 | 146 | | |
147 | 147 | | |
148 | 148 | | |
| |||
0 commit comments