-
Notifications
You must be signed in to change notification settings - Fork 336
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
Add a placeholder implementation for non-mobile platforms #688
Conversation
The following PRs will need an update after this change. |
Should I increase the version numbers in |
64a1818
to
90b5ba0
Compare
@Taym95 Hi. If you have some time, could you please take a look at this change and give me some advice? |
I will review it today, sorry for not responding quickly |
@Taym95 Hi. Could you review and give some comments? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for contribution, this will be helpful for endorsed package indeed.
please update your branch |
@Taym95 Sure. I hope there will be a version bump soon after merge so that this change can be released. |
Yes |
Sets the default value of
ReactiveBlePlatform.instance
to an instance of_PlaceholderImplementation
, rather thanReactiveBleMobilePlatform
(current) which is for mobile platforms only. This is necessary so that federated implementations of this plugin (endorsed or not) can be added for non-mobile (desktop) platforms.The same approach is being used by 1st-party plugin developers as they have decided to remove default method channel implementations from their platform interface packages. For example: https://github.com/flutter/plugins/blob/2ce625f1a87e4b738f63a6f1f7e3e040e7c0b87f/packages/video_player/video_player_platform_interface/lib/video_player_platform_interface.dart#L22
After this change, a new platform implementation can be added by providing a static
registerWith
method that is used to register the plugin for that platform on app startup (documentation). Here is the example:I personally need this change to add a Tizen platform implementation of this plugin for our project. Any comments will be appreciated. Thank you!