The XyzMapper fields on each Handler type should be 'readonly' #4870
Labels
legacy-area-controls
Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor
s/verified
Verified / Reproducible Issue ready for Engineering Triage
t/bug
Something isn't working
Milestone
Description
The various Mapper fields on the various control handlers should be made 'readonly' so they don't get overwritten.
Examples:
https://github.com/dotnet/maui/blob/main/src/Core/src/Handlers/Button/ButtonHandler.cs#L19-L41
https://github.com/dotnet/maui/blob/main/src/Core/src/Handlers/Editor/EditorHandler.cs#L16-L37
We noticed this in the BlazorWebView handler (probably because I copied the code from some other handler to begin with) and it seems to make sense to mark them
readonly
.Tagging @PureWeen .
Steps to Reproduce
N/A
Version with bug
Unknown/Other (please specify)
Last version that worked well
Unknown/Other
Affected platforms
I was not able test on other platforms
Affected platform versions
N/A
Did you find any workaround?
No response
Relevant log output
No response
The text was updated successfully, but these errors were encountered: