android-maps-v2

How to temporarily disable map marker clustering?

﹥>﹥吖頭↗ 提交于 2019-12-14 03:46:28
问题 I am using Google Maps V2 for Android together with maps utils extension library for marker clustering. Some parts of app does not need to get clustered markers. Is there any way to forbid clusterManager to cluster markers and after certain conditions let it cluster items again? 回答1: I found myself another solution. I figured out that on DefaultClusterRenderer method shouldRenderAsCluster is responsible for whether the marker will be rendered as cluster or not. So I created a CustomRenderer

setFastestInterval(long milis) not working

时间秒杀一切 提交于 2019-12-14 02:38:37
问题 I want to slow the update rates as soon as I got a location precise enough for my needs: @Override public void slowUpdateRate() { /* * Set the update interval */ Dbg.v(TAG,"****************************"); Dbg.e(TAG, "-- SLOW update rate"); Dbg.v(TAG,"****************************"); stopUpdates(); mLocationRequest.setInterval(1500000); mLocationRequest.setFastestInterval(150000); mLocationClient.requestLocationUpdates(mLocationRequest, this); The method is called but I still got updates every

How to enable traffic information along a specific route in Google Maps V2?

旧街凉风 提交于 2019-12-13 13:10:11
问题 Google Navigation shows the traffic layer only for a given route. With GoogleMap.setTrafficEnabled(true) I'll get the traffic information for the whole map. I know how to draw polylines for a route from Google Directions, but how can I turn on the traffic layer only for that route? 回答1: Not possible as of API v2 version 3.1.36. You may want to post a feature request on gmaps-api-issues. 回答2: The difference between these two values (duration and a duration in traffic) indicates how delayed

Google map Android API v2 - InfoWindow on polyline?

。_饼干妹妹 提交于 2019-12-13 13:07:42
问题 I am drawing polyline on my map,I need to show some data to user now. How I can draw text or InfoWindow on each polyline ? I add polyline like : ArrayList<LatLng> points = null; PolylineOptions lineOptions = null; MarkerOptions markerOptions = new MarkerOptions(); // Traversing through all the routes for(int i=0;i<result.size();i++){ points = new ArrayList<LatLng>(); lineOptions = new PolylineOptions(); String color = colors[i % colors.length]; // Fetching i-th route List<HashMap<String,

Google Map Android API v2 getMap() error

主宰稳场 提交于 2019-12-13 09:07:42
问题 Hi I'm trying to implement Google Maps display in my app using Google Map Android API v2, and I am trying to follow the solution in here. Codes seem to be okay except when I tried this part: public class MapFragment extends SherlockMapFragment { private GoogleMap mMap; @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { View root = super.onCreateView(inflater, container, savedInstanceState); mMap = getMap(); return root; } } The getMap

Android google map v2 errors [closed]

瘦欲@ 提交于 2019-12-13 08:50:58
问题 Closed . This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 5 years ago . i'm following this tutorial : http://www.tutos-android.com/introduction-a-google-map-v2 Here is the source code : http://www.tutos-android.com/wp-content/uploads/2013/03/GmapV2.zip and i get this errors : 02-18 18:51:05.699: E/Trace(774): error opening trace file: No such file or directory (2) 02

Importing AndroidMapsExtensions into Android Studio

邮差的信 提交于 2019-12-13 06:14:22
问题 I have been trying relentlessly to use this library. Everytime I add it, I lose all android.support.v4 and com.google.android.gms.maps cababilities. There is very little documentation for this library. Is there any tutorial that I have overlooked in my extensive Google searching? Here's my gradle file: dependencies { compile fileTree(dir: 'libs', include: ['*.jar']) compile 'com.android.support:appcompat-v7:21.0.3' compile 'com.google.android.gms:play-services:6.5.87' compile 'com

Trouble Importing android-support-v4.jar

半腔热情 提交于 2019-12-13 04:58:56
问题 I am trying to do the tutorial Sample Code from the https://developers.google.com/maps/documentation/android/intro page.I import the google-play-services_lib just fine, then I import the /extras/google/google_play_services/samples/maps At this point I have 2 errors: The type android.support.v4.app.Fragment cannot be resolved. It is indirectly referenced from required .class files RetainMapActivity.java /MainActivity/src/com/example/mapdemo line 45 Java Problem The project was not built since

android Retrieving current position on mapsv2 dynamically

我们两清 提交于 2019-12-13 03:39:47
问题 Well , I have couple of topic related with this issue but still did not got the logic besides nobody provides a clear solution. Anyway, I will try to ask it again clearly and provide a screenshot (from a sample app) hope it would do the magic. As you can see below there is a custom marker on google maps, I can implement it to my scenario by adding an Imageview . On above of the maps there is a TextView . In there address change dynamically when the markers position change on the maps. BUT we

Adding Map to Android TAB - Error

安稳与你 提交于 2019-12-13 02:46:39
问题 I have created an application where I have 3 tabs and in the last one I have added a map, and here is the error because I get an error navigating with the tabs. Take a look below the code Tab fragment: public class Tab3 extends Fragment { @Override public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) { View v = inflater.inflate(R.layout.tab_3, container, false); return v; } } xml: <?xml version="1.0" encoding="utf-8"?>