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

Remove IPlatformInvalidate and Device.Invalidate() #4479

Merged
merged 11 commits into from
Feb 4, 2022

Conversation

mattleibow
Copy link
Member

@mattleibow mattleibow commented Feb 2, 2022

Description of Change

This PR removes the API that basically finds the renderer and triggers a invalidation/layout/redraw. Instead of exposing this as a property and something to implement, it is just a service that can be removed at a later stage.

Implements #1965

Additions made

  • Removes Device.Invalidate(VisualElement visualElement)
  • Removes Device.PlatformInvalidator
  • Replaces Device.Invalidate with Removes DependencyService usage

PR Checklist

  • Targets the correct branch
  • Tests are passing (or failures are unrelated)
  • Targets a single property for a single control (or intertwined few properties)
  • Adds the property to the appropriate interface
  • Avoids any changes not essential to the handler property
  • Adds the mapping to the PropertyMapper in the handler
  • Adds the mapping method to the WinUI, Android, iOS, and Standard aspects of the handler
  • Implements the actual property updates (usually in extension methods in the Platform section of Core)
  • Tags ported renderer methods with [PortHandler]
  • Adds an example of the property to the sample project (MainPage)
  • Adds the property to the stub class
  • Implements basic property tests in DeviceTests

Does this PR touch anything that might affect accessibility?

  • Does this PR introduce a new control? (If yes, add an example using SemanticProperties to the SemanticsPage)
  • APIs that modify focusability?
  • APIs that modify any text property on a control?
  • Does this PR modify view nesting or view arrangement in anyway?
  • Is there the smallest possibility that your PR will change accessibility?
  • I'm not sure, please help me

If any of the above checkboxes apply to your PR, then the PR will need to provide testing to demonstrate that accessibility still works.

Removes:
 - `Device.Invalidate(VisualElement visualElement)`
 - `Device.PlatformInvalidator`
 - `IPlatformInvalidate`
@mattleibow mattleibow changed the title Remove IPlatformInvalidate and Device.Invalidate() Remove IPlatformInvalidate and Device.Invalidate() Feb 2, 2022
@rmarinho rmarinho merged commit 6c4f1f4 into main Feb 4, 2022
@rmarinho rmarinho deleted the dev/device-invalidator branch February 4, 2022 19:25
@samhouts samhouts added the migration-compatibility Xamarin.Forms to .NET MAUI Migration, Upgrade Assistant, Try-Convert label Aug 28, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Dec 22, 2023
@samhouts samhouts added the fixed-in-6.0.200-preview.14.2 Look for this fix in 6.0.200-preview.14.2! label Aug 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
fixed-in-6.0.200-preview.14.2 Look for this fix in 6.0.200-preview.14.2! migration-compatibility Xamarin.Forms to .NET MAUI Migration, Upgrade Assistant, Try-Convert
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

4 participants