maps

Display Dialog Box when i click on the maps place marker icon?

一笑奈何 提交于 2019-12-23 04:45:16
问题 When I click the certain place in the map in android it shows the alert Dialog ? You want to save the location into particular list for example My place or Favorite so that I can move that place to particular list in. Thanks in Advance...... 回答1: public class MapViewer extends MapActivity { MapView mapView; MapController mapController; GeoPoint mgeoPoint; Drawable marker; MyLocationOverlay mLocationOverlay; MotionEvent e; @Override protected void onCreate(Bundle icicle) { // TODO Auto

Maps Android V2: java.lang.noclassdeffounderror: com.google.android.gms.R$styleable

流过昼夜 提交于 2019-12-23 03:21:59
问题 As many I get the following error: java.lang.noclassdeffounderror: com.google.android.gms.R$styleable when trying to implement Maps for Android V2. Somehow I must be missing what I exactly am doing wrong, since it's not working. What I tried first is to copy the google-play-services.lib into the lib folder, but I saw somewhere I shouldn't do this. Then I tried to import addon-google_apis-google-8 as a project, but the project gives the error The import com.google cannot be resolved. I'm

add result of image.plot layer on geographic map (bing map)

无人久伴 提交于 2019-12-23 03:19:24
问题 I have a 2D footprint result for an eddy-covariance system on a 1100*1100 square meter, with the domain of domain = c(-100,1000,-100, 1000) the cell size of the domain (each grid) is 2 meters with the origin (0,0) accordingly on this location: Lon = -97.191391 #longtitude Lat = 36.055935 #latitude An example data (9.01 Mb) is attached here. FFP.rds then I can plot a Bing map on my site as this: library(OpenStreetMap) library(rgdal) map <- openmap(c(36.05778,-97.19250), c(36.05444,-97.18861)

shapefile to produce a linked micromap in R

回眸只為那壹抹淺笑 提交于 2019-12-23 02:57:19
问题 I am trying to replicate the example provided in the micromap R package of a linked map with the poverty rate for the 50 US states. I am trying to achieve the same results with a Shapefile from Germany. Here is my code: library(micromap) library(ggplot2) setwd ('C:/Users/Jesus/Dropbox/linked maps/Chapter4') ger<-readShapePoly("germany3.shp") edPov<-read.csv('gerpoverty.csv') statePolys <- create_map_table(ger, 'VARNAME_1') head(statePolys) lmplot(stat.data=edPov, map.data=statePolys, panel

Windows Phone 8 - HowTo display current position on the map

那年仲夏 提交于 2019-12-23 02:48:15
问题 As the title suggest I am struggeling with the display of the current location of the user on the map. Afaik there a two ways to display the current user location: In Code: create a ellipse, set it as content of a MapOverlay , set the GeoCoordinate of the MapOverlay, add this overlay to a MapLayer and add this to the map - but I cannot access the MapOverlay anymore and thus I cannot change (update) the position of the user. Is there a way to update the user position without having to redraw

How to create a simple draggable marker in OpenLayers

泪湿孤枕 提交于 2019-12-23 02:35:03
问题 Very simple question, how can I create a draggable marker in an OpenLayers map, and get the latlon when its been dragged. From google, it seems that you can have draggable vectors, but not draggable markers. I've seen some references to OpenLayers.Control.DragMarker , but this doesn't seem to be in the "core" library. It's used in this example but that seems to be using a custom OpenLayers JS file, so I have no idea how to go about including that in my code. Code thus far (to add a simple

Routing, polylines in iPhone Google Maps

落爺英雄遲暮 提交于 2019-12-23 01:42:14
问题 In our iPhone app we need to draw a route on Google Maps (GMaps is the only option, we can't consider other maps). We draw the route while the user walks around - GPS tracking basically. Then we display all saved routes on the map. The problem is that Google Maps is almost unusable. It is impossible to scroll the map, zoom it (everything is extremely slow). Now we draw the route on a transparent layer [UIColor clearColor] in the method - (void)drawRect:(CGRect)rect which is called using [

Good way to clear nested Maps in Java

匆匆过客 提交于 2019-12-22 14:59:15
问题 public class MyCache { AbstractMap<String, AbstractMap<String, Element>> cache = new TreeMap<String, AbstractMap<String, Element>>(); public Boolean putElement(String targetNamespace, Element element) { ... } public void clear() { cache.clear(); } // is it better this way? public void deepClear() { for(AbstractMap<String, Element> innerMap : cache.values()) { innerMap.clear(); } cache.clear(); } } Is it necessary to iterate over the values of the root map and clear all the maps nested in the

Can Google Maps be set to a slow constant pan? Like a globe revolution?

我的未来我决定 提交于 2019-12-22 10:45:33
问题 Just what the title says. I am searching for a solution but I have not found anything that has guided me to the correct documentation or articles. If you have any ideas or can point me to a possible solution I can work with, it would be greatly appreciated. Thanks 回答1: You can do this yourself like this: Use setInterval to set up a function to be run periodically. The function would call panBy on the Google map object to "rotate" it a bit. That should give you a simple animation that does

Why the difference in scale values in projection vs. tile?

旧街凉风 提交于 2019-12-22 10:34:51
问题 Using the d3.geo.tile plugin, examples all have a difference between the scale of the map projection and the scale passed to the tile() function. In particular, tile_scale = projection_scale * 2 * Math.PI . See examples here and here. What's the meaning of this 2 * PI multiplication? 回答1: To understand why there is an additional factor of 2π applied to the scales when it comes to using the d3.geo.tile plugin, it is important to know the difference between the projection used by d3.geoMercator