[NET10] Marked INativeBindingService as Obsolete#29918
[NET10] Marked INativeBindingService as Obsolete#29918PureWeen merged 1 commit intodotnet:net10.0from
Conversation
|
Hey there @@kubaflo! Thank you so much for your PR! Someone from the team will get assigned to your PR shortly and we'll get it reviewed. |
There was a problem hiding this comment.
Pull Request Overview
This PR marks the INativeBindingService interface as obsolete and suppresses the resulting compiler warnings at its call sites in ApplyPropertiesVisitor.
- Added
[Obsolete]attribute toINativeBindingServicein Core. - Introduced
#pragma warning disable/restore CS0618around two usages inApplyPropertiesVisitor. - Added
using System;for theObsoleteattribute.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/Controls/src/Core/INativeBindingService.cs | Mark INativeBindingService as obsolete and import System. |
| src/Controls/src/Xaml/ApplyPropertiesVisitor.cs | Suppress CS0618 warnings around DependencyService.Get<INativeBindingService>(). |
Comments suppressed due to low confidence (1)
src/Controls/src/Core/INativeBindingService.cs:8
- Please update the public XML documentation in
/docs/to mention thatINativeBindingServiceis now obsolete and will be removed in a future release, so consumers see this deprecation in the official docs.
[Obsolete("INativeBindingService is obsolete and will be removed in a future release.")]
| #pragma warning disable CS0618 // Type or member is obsolete | ||
| var nativeBindingService = DependencyService.Get<INativeBindingService>(); | ||
| #pragma warning restore CS0618 // Type or member is obsolete | ||
|
|
There was a problem hiding this comment.
[nitpick] This pragma silences warnings for the now-obsolete INativeBindingService. Consider refactoring to the new binding API or removing these calls before the interface is removed in a future release.
| #pragma warning disable CS0618 // Type or member is obsolete | |
| var nativeBindingService = DependencyService.Get<INativeBindingService>(); | |
| #pragma warning restore CS0618 // Type or member is obsolete |
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
|
@StephaneDelcroix Thoughts? |
|
that capability was lost during the transition from XF to maui, and we didn't get much complain. I'm sure we'll reinvent it later, but let's obsolete and eventually remove |
Note
Are you waiting for the changes in this PR to be merged?
It would be very helpful if you could test the resulting artifacts from this PR and let us know in a comment if this change resolves your issue. Thank you!
Issues Fixed
Fixes #21861