flutter_wear_plugin
flutter_wear_plugin copied to clipboard
Use the wear_plus plugin instead
I've been unofficially maintaining this plugin for myself and partners for the past 2 years. Since no one is responding to issues in this repository, I have released wear_plus with the necessary changes to be compatible with a modern Flutter application.
I've been unofficially maintaining this plugin for myself and partners for the past 2 years. Since no one is responding to issues in this repository, I have released wear_plus with the necessary changes to be compatible with a modern Flutter application.
@Rexios80
Hi,
I am developing a launcher for a smart watch that OS is android 8.1.0.
in both plugin (wear:1.1.0 and wear_plus:1.2.0), I got those exceptions, so I think the usage of methodChannel in native implementation is incorrect, if not? tell me how fix that.
and I have one question about ambient Mode in watch.
What is the ambient mode in the watch and when does it occur?
E/flutter ( 6715): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: MissingPluginException(No implementation found for method getShape on channel wear)
E/flutter ( 6715): #0 MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:332:7)
E/flutter ( 6715): <asynchronous suspension>
E/flutter ( 6715): #1 Wear.getShape (package:wear_plus/src/wear.dart:63:15)
E/flutter ( 6715): <asynchronous suspension>
E/flutter ( 6715): #2 _WatchShapeState.initState.<anonymous closure> (package:wear_plus/src/shape_widget.dart:55:35)
E/flutter ( 6715): <asynchronous suspension>
E/flutter ( 6715):
E/flutter ( 6715): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: MissingPluginException(No implementation found for method isAmbient on channel wear)
E/flutter ( 6715): #0 MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:332:7)
E/flutter ( 6715): <asynchronous suspension>
E/flutter ( 6715): #1 Wear.isAmbient (package:wear_plus/src/wear.dart:74:15)
E/flutter ( 6715): <asynchronous suspension>
E/flutter ( 6715): #2 _AmbientModeState._updateMode (package:wear_plus/src/ambient_widget.dart:90:3)
E/flutter ( 6715): <asynchronous suspension>
Do not depend on both plugins.
wear_plus is a drop in replacement for the wear plugin
If you aren't depending on both, the issue is probably that you need to call WidgetsFlutterBinding.ensureInitialized() first
Ambient mode is when the screen is "inactive" but still on. If you play with the example app and the hand cover gesture this should become obvious.
Do not depend on both plugins.
wear_plus is a drop in replacement for the wear plugin
I know. I only use one of them at a time. not both
If you aren't depending on both, the issue is probably that you need to call WidgetsFlutterBinding.ensureInitialized() first
I added this before. but still not working.
Ambient mode is when the screen is "inactive" but still on. If you play with the example app and the hand cover gesture this should become obvious.
thanks
Does the example app work?
Does the example app work?
Unfortunately not.
The wear_plus example app works as expected for me. Please create an issue in the wear_plus repo with more information. https://github.com/Rexios80/wear_plus
The wear_plus example app works as expected for me. Please create an issue in the wear_plus repo with more information. https://github.com/Rexios80/wear_plus
I tried to create issue in your repo. but I cant find any way to do that(there is not issue tab in repo).
Issues are disabled by default in forked repos, my bad. Please try now.
@Rexios80 thank you so much for doing this! I've just got started with Flutter and was battling with getting this repo to work, yours worked perfectly without needing to modify the project beyond adding the plugin 😄