wear-os

Get battery level of connected smartwatches

孤者浪人 提交于 2019-12-22 05:17:17
问题 Is it possible to get the battery level of connected smartwatches as part of the Wear API? (Preferably without having to deploy an actual wear-component onto the smartwatch and then communicating back-and-forth between the watch and the device). I've seen some wear-apps that show the battery level of the watch on the watch itself, but I'd simply like to find out the current battery level of the watch using the phone . 回答1: You're more than likely going to need a wear app, but it should be

Is it possible to create an Android Wear app with react native

独自空忆成欢 提交于 2019-12-22 02:07:33
问题 I have had a play with react native creating ios apps but have not tried android yet. With android you also get 'android wear' for watches etc, will react native work creating apps for those devices? 回答1: React Native does not run on Android Wear at the current time, so you would have to do that code native. 回答2: Actually, you can try React native vanilla 来源: https://stackoverflow.com/questions/34926013/is-it-possible-to-create-an-android-wear-app-with-react-native

CapabilityApi does not return any Nodes

主宰稳场 提交于 2019-12-21 21:25:26
问题 I'm attempting to communicate between my handheld and wearable app and I am trying to find the correct Node by using the CapabilityApi . I know that the devices are connected - other apps and samples work just fine - but when I run my wearable app neither calls to getCapability() or getAllCapabilities() return any Nodes at all. Everything else seems to work properly - in fact I can find the handheld device just fine if I use the NodeApi and sending messages with the MessageApi also seems to

How to run a Xamarin.Forms Application on an Android Wear Device

↘锁芯ラ 提交于 2019-12-21 20:52:53
问题 How can I run a Xamarin.Forms.Platform.Android.FormsApplicationActivity on an Android Wear device? The call base.OnCreate(bundle) inside the onCreate method of my class always throws a RuntimeException "You cannot use indeterminate progress on a watch". Here is my code: namespace Test { [Activity (Label = "Temp.Droid", Icon = "@drawable/icon", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation)] public class MainActivity : global::Xamarin.Forms

Android Wear CapabilityApi cannot find handheld capabilities

两盒软妹~` 提交于 2019-12-21 17:39:10
问题 I'm attempting to use MessageAPI to communicate back and forth between my handheld app and wearable app. I can't get the communication to work. I can confirm the devices are connected, but when my code executes, it acts like neither app has registered the Capability I am requesting. notifications are successfully sent from handheld to the wear device Wearable.NodeApi.getConnectedNodes(mGoogleApiClient).await() returns a list showing the handheld or wearable is indeed connected Wearable

In Android Studio, building an Android Wear project, how can I include the same file in both modules

元气小坏坏 提交于 2019-12-21 05:41:34
问题 I am successfully building an Android Wear watch face and connected app on the mobile device. The problem is that I have several resource and class files that are referenced in both the mobile and wear modules. The skeleton app I built this from also created a (non-building) DigitalWatch module and I'm guessing I could move these common files in there and then reference them from my Gradle build files. I've reviewed some of the ideas on Stackoverflow, but the comments suggest they don't work.

Android Wear Launcher

情到浓时终转凉″ 提交于 2019-12-21 04:57:20
问题 I am wondering how the Android Wear launchers like Swipify and Wear Mini Launcher intercept touch events on the android wear home screen . I have tried adding the onTouch and onClick listeners to the Watch View Stub in my app so far, but I can not figure out how to get touches that occur outside of my app. 回答1: In fact, the views are directly added in the WindowManager in a Service . You can take a look at this thread to understand how it works: Creating a system overlay window (always on top

Wear settings list items

亡梦爱人 提交于 2019-12-21 03:02:46
问题 I am trying to replicate the wear settings list for my wear app. I want to use a list of checkbox items like this. The problem is I have to use CircledImageView if I want the zoom in animation to work properly. I am not able to use the Checkbox to animate properly as the list scrolls. What is the right way to do this? Is there a way to use CircledListItem in a way that will show two images based on checked.unchecked? Or is there a way to use Checkbox to manage the focus zoom properly? 回答1: It

W/GooglePlayServicesUtil: Google Play services out of date. Requires 8298000 but found 8107534

不想你离开。 提交于 2019-12-20 04:52:55
问题 As many other questions here on SO, I encounter a similar error message. Unlike other questions, this is regarding a hardware debugged device. My gradle wear-build file looks like this: dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) compile 'com.google.android.support:wearable:1.2.0' compile 'com.google.android.gms:play-services-wearable:8.3.0' compile 'com.android.support:appcompat-v7:23.1.0' } Debuggin the app within the emulator works fine but as soon as I release the app

Getting “more than one library with package name 'com.google.android.gms'” when running wear module

烂漫一生 提交于 2019-12-20 04:42:23
问题 I'm adding a wear module to an app. (using this sample code as a reference) So I have 3 modules, each one depends on a version of com.google.android.gms:play-services: app - compile 'com.google.android.gms:play-services:6.1.11' wear - 'com.google.android.gms:play-services-wearable:6.5.+' shared - compile 'com.google.android.gms:play-services:6.1.11' When compiling the Wear module, I get this error: Error:Execution failed for task ':wear:processDebugResources'. Error: more than one library