android-maps

Moving MapFragment (SurfaceView) causes black background flickering

半世苍凉 提交于 2019-11-27 17:14:50
I'm trying to implement new Android Google Maps API (v2). However it doesn't seem to go well with SlidingMenu . As you may know, MapFragment implementation is based on SurfaceView . The problem is that the SurfaceView doesn't like moving it around - I mean placing it in movable views: ViewPager , ScrollView , ListView , or the aforementioned SlidingMenu . When you move it, it leaves a black hole in the place where its pixels originally layed. It looks something like this . This problem can be partially solved by specifying a transparent background on the SurfaceView or even placing a

Map API v2 Authorisation Failure

本秂侑毒 提交于 2019-11-27 15:03:22
Alright, here is what I did using the example Got the debug key via keytool (made sure it is the the debug key is used by eclipse in Preferences -> Android -> Build) Generated the key by the command $ keytool -list -v -keystore debug.keystore -alias androiddebugkey -storepass android -keypass android Copy pasted the SHA1 sum in the Google API Console + my packagename: sum;com.my.package Enabled Google Map API v2 in the same project in Google API Console Copied it to the Manifest application in meta-data. Downloaded via SDK manager and Imported the google-play-services_lib project and

How to show a balloon above a marker in a MapActivity? Isn't there a widget?

可紊 提交于 2019-11-27 08:07:19
I dont get the point, why I have to code so much for it. Like, I dont want to care about... the position of the balloon (I just want to assign a geopoint) the layout of a basic balloon (Later on I might want to implement a xml based layout) the number of shown balloons (only display one at a time) the open/close behaviour of the balloon (close, when an other bollon is tabbed) Update Solved it! See my answer below... Here is the "the missing widget"... Balloons without icons: https://github.com/jgilfelt/android-mapviewballoons#readme Balloons with icons (extends Jeff Gilfelt's project): https:/

Google map for android my location custom button

谁都会走 提交于 2019-11-27 06:50:29
How can I change google map my location default button? I set my location enable and map draw standard image to find location, is it possible to change default image? See below xml file to custom button: <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" > <fragment android:id="@+id/maps" android:name="pl.mg6.android.maps.extensions.SupportMapFragment" android:layout_width="match_parent" android:layout_height="match_parent" />

How to center the camera so that marker is at the bottom of screen? (Google map api V2 Android)

自闭症网瘾萝莉.ら 提交于 2019-11-27 06:29:55
When a marker is clicked, the default behavior for the camera is to center it on screen, but because I usually have long text description in the info window, it's more convenient to actually change the camera position so that the marker is on the bottom of screen(making the info window in the center of screen). I think I should be able to do that by overriding onMarkerClick function like below (the default behavior is cancelled when this function return true) @Override public boolean onMarkerClick(final Marker marker) { // Google sample code comment : We return false to indicate that we have

Google Maps API v2: How to make markers non-clickable?

孤街醉人 提交于 2019-11-27 06:00:07
问题 I mean if i click marker OnMarkerClickListener is called, so the OnMapClickListener did not. Even if i set mMap.setOnMarkerClickListener(null); marker object still masks all click events for underlying map and objects. How can i set Marker transparent for all user interractions? 回答1: This is indeed a "limitation" of markers as of 3.1.59 version of the library. If you really need them to be markers, please post a feature request on gmaps-api-issues for MarkerOptions.clickable and Marker

Google Maps works fine on Android but I still get an error “Could not find class 'maps.i.k', referenced from method maps.z.ag.a”

家住魔仙堡 提交于 2019-11-27 05:53:55
问题 I got Google Maps Android API v2 to work perfectly on my Android Application by downloading the library, adding it to workspace, then referencing it as a library. But I still get this error as soon as the activity containing the Map Fragment starts Could not find class 'maps.i.k', referenced from method maps.z.ag.a By the way I'm using support map fragment This error does not seem to affect me in anyway nor crash the application nor anything, should I bother fixing it ? Added the manifest P.S

Google Maps api v2 class not found

守給你的承諾、 提交于 2019-11-27 05:20:09
I am using google maps api v2 and everything was working fine . today morning i updated the sdk and now maps are not working. Tried a lot of things like importing the lib project again and all but nothing seems to work . Plz help. This is the logcat output 05-16 08:53:34.327: E/dalvikvm(3422): Could not find class 'com.google.android.gms.maps.model.LatLng', referenced from method com.apptree.de_luxe.InfoActivity.<clinit> 05-16 08:53:34.327: W/dalvikvm(3422): VFY: unable to resolve new-instance 170 (Lcom/google/android/gms/maps/model/LatLng;) in Lcom/apptree/de_luxe/InfoActivity; 05-16 08:53:34

image not loading from URL in custom infoWindow using Picasso image loading library in android

老子叫甜甜 提交于 2019-11-27 02:30:00
问题 I am trying to load an image from the URL in custom infoWindow when the user click on the marker. I was able to load the other details but the image is not loading int it. i'm using Picasso library to do this for me. I have search many related topics and see the solutions but was not able to understand which solution to apply to solve my problem. I am using an web service call to get the required data. This is my code: @Override public View getInfoContents(Marker arg0) { //marker

How to animate marker in android map api V2?

蹲街弑〆低调 提交于 2019-11-27 00:27:59
I want to implement smooth transition to emulate car marker moving on the map. Is it possible to animate marker in android map api v2? Try out the below code to animate the marker on Google Map V2. You need to use the Interpolator class to apply the animation on the Marker and handle it in the Handler for the animation as below: public void animateMarker(final Marker marker, final LatLng toPosition, final boolean hideMarker) { final Handler handler = new Handler(); final long start = SystemClock.uptimeMillis(); Projection proj = mGoogleMapObject.getProjection(); Point startPoint = proj