Hello. The latest version of Google Play Services (7.3) on the Play Store indicates in "What's new" : "Maps API v2 for Android Wear".
However, it still doesn't seem to work. Can we expect an update of Android Wear to support this soon? Thank you. Le mercredi 4 février 2015 09:27:24 UTC+1, ps-geolives a écrit : > > Hello, > > I'm trying to display a Google map (Google Maps API V2 for Android) on my > Sony SmartWatch3. > > In my wear layout, i'm using a MapFragment with this code : > > <fragment > android:layout_width="match_parent" > android:layout_height="match_parent" > android:id="@+id/mapFragment" > class="com.google.android.gms.maps.MapFragment"/> > > My wear main activity implements OnMapReadyCallback : > > @Override > public void onMapReady(GoogleMap map) { > SupportMapFragment fragment = ( SupportMapFragment) > getSupportFragmentManager().findFragmentById(R.id.mapFragment); > // Getting Google Map > GoogleMap googleMap = fragment.getMap(); > > When I compile the program with Google Play Services for wearable in the > classpath, it doesn't compile. > > When I compile the program with full Google Play Services in the > classpath, it compiles successfully but when I execute the program on the > smartwatch, I get this exception: > > 02-03 16:44:23.456 2377-2377/com.example.andy.myfirstwearablemapapplication > E/AndroidRuntime﹕ FATAL EXCEPTION: main > Process: com.example.andy.myfirstwearablemapapplication, PID: 2377 > android.view.InflateException: Binary XML file line #7: Error inflating > class fragment > at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:763) > at android.view.LayoutInflater.rInflate(LayoutInflater.java:806) > at android.view.LayoutInflater.inflate(LayoutInflater.java:504) > at android.view.LayoutInflater.inflate(LayoutInflater.java:414) > at android.view.LayoutInflater.inflate(LayoutInflater.java:365) > at android.support.wearable.view.WatchViewStub.inflate(WatchViewStub.java: > 179) > at android.support.wearable.view.WatchViewStub.onApplyWindowInsets( > WatchViewStub.java:148) > at android.view.View.dispatchApplyWindowInsets(View.java:6514) > at android.view.ViewGroup.dispatchApplyWindowInsets(ViewGroup.java:5782) > at android.view.ViewGroup.dispatchApplyWindowInsets(ViewGroup.java:5786) > at android.view.ViewGroup.dispatchApplyWindowInsets(ViewGroup.java:5786) > at com.android.internal.policy.impl.PhoneWindow$DecorView. > dispatchApplyWindowInsets(PhoneWindow.java:2335) > at android.view.ViewRootImpl.dispatchApplyInsets(ViewRootImpl.java:1205) > at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:1423) > at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1054) > at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:5779) > at android.view.Choreographer$CallbackRecord.run(Choreographer.java:767) > at android.view.Choreographer.doCallbacks(Choreographer.java:580) > at android.view.Choreographer.doFrame(Choreographer.java:550) > at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer. > java:753) > at android.os.Handler.handleCallback(Handler.java:739) > at android.os.Handler.dispatchMessage(Handler.java:95) > at android.os.Looper.loop(Looper.java:135) > at android.app.ActivityThread.main(ActivityThread.java:5221) > at java.lang.reflect.Method.invoke(Native Method) > at java.lang.reflect.Method.invoke(Method.java:372) > at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit. > java:899) > at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:694) > Caused by: java.lang.IllegalStateException: Unable to find dynamic class > com.google.android.gms.maps.internal.CreatorImpl > at com.google.android.gms.maps.internal.x.a(Unknown > ... -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en --- You received this message because you are subscribed to the Google Groups "Android Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.