Re: [android-developers] MapView (Maps V2) not working

2014-09-23 Thread ram
refer this blog for maps v2
http://ramsandroid4all.blogspot.in/2013/03/google-maps-android-api-v2.html

On 23 September 2014 17:36, saex  wrote:

> Welcome all
>
> The tiles of the map are not being updated, the only way to update them is
> to block the device (onPause called) and to unblock the device (onResume
> called). If i do that, the tiles become updated it is very strange
>
> i mean that if i move the finger doing zoom or moving the map, the map is
> frozen, and it only reresh it's state when i block and unblock the device
>
> all the permissions are fine and the api key also is fine in the manifest
>
> this is my code:
>
> public class MainActivity extends Activity {
> MapView map;
>
> @Override
> protected void onCreate(Bundle savedInstanceState) {
> super.onCreate(savedInstanceState);
> LinearLayout main = new LinearLayout(this);
> main.setLayoutParams(new 
> LayoutParams(LayoutParams.MATCH_PARENT,LayoutParams.MATCH_PARENT));
>
> GoogleMapOptions options = new GoogleMapOptions();
> options.mapType(GoogleMap.MAP_TYPE_SATELLITE)
> .compassEnabled(false)
> .rotateGesturesEnabled(false)
> .tiltGesturesEnabled(false);
>
> options.camera(new CameraPosition(new LatLng(0, 0), 1, 0, 0));
>
> map = new MapView(this, options);
> map.onCreate(savedInstanceState);
> main.addView(map);
>
> setContentView(main);
> }
>
> @Override
> protected void onPause() {
> // TODO Auto-generated method stub
> super.onPause();
> map.onResume();
> }
>
> @Override
> protected void onResume() {
> // TODO Auto-generated method stub
> super.onResume();
> map.onPause();
> }
>
> }
>
>  --
> 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.
>



-- 

Thanks& Regards,
Rambabu Mareedu
Senior Software Engineer
Roots Computer Services PVT LTD
+91 9581411199

-- 
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.


[android-developers] MapView (Maps V2) not working

2014-09-23 Thread saex


Welcome all

The tiles of the map are not being updated, the only way to update them is 
to block the device (onPause called) and to unblock the device (onResume 
called). If i do that, the tiles become updated it is very strange

i mean that if i move the finger doing zoom or moving the map, the map is 
frozen, and it only reresh it's state when i block and unblock the device

all the permissions are fine and the api key also is fine in the manifest

this is my code:

public class MainActivity extends Activity {
MapView map;

@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
LinearLayout main = new LinearLayout(this);
main.setLayoutParams(new 
LayoutParams(LayoutParams.MATCH_PARENT,LayoutParams.MATCH_PARENT));

GoogleMapOptions options = new GoogleMapOptions();
options.mapType(GoogleMap.MAP_TYPE_SATELLITE)
.compassEnabled(false)
.rotateGesturesEnabled(false)
.tiltGesturesEnabled(false);

options.camera(new CameraPosition(new LatLng(0, 0), 1, 0, 0));  

map = new MapView(this, options);
map.onCreate(savedInstanceState);
main.addView(map);

setContentView(main);
}

@Override
protected void onPause() {
// TODO Auto-generated method stub
super.onPause();
map.onResume();
}

@Override
protected void onResume() {
// TODO Auto-generated method stub
super.onResume();
map.onPause();
}

}

-- 
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.


Re: [android-developers] MapView + Multiple Markers + Pan/Zoom

2012-12-19 Thread Mark Murphy
Maps V1 didn't really have great support for that, and is now
deprecated, anyway.

Maps V2 allows you to associate an OnCameraChangeListener with a
GoogleMap, to be informed when the camera changes position, tilt, or
zoom.

On Wed, Dec 19, 2012 at 5:54 PM, Filipe Batista
 wrote:
> Hi,
>
> I have an application that should load to a MapView several markers as
> soon the zoom changes ou the map center location changes.
> I have been looking into the documentation but i have not found any
> listener for the zoom changes ou pan. Is there any to do this?
> Thanks
> Best Regards
>
> --
> 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



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

_The Busy Coder's Guide to Android Development_ Version 4.4 Available!

-- 
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


[android-developers] MapView + Multiple Markers + Pan/Zoom

2012-12-19 Thread Filipe Batista
Hi,

I have an application that should load to a MapView several markers as
soon the zoom changes ou the map center location changes.
I have been looking into the documentation but i have not found any
listener for the zoom changes ou pan. Is there any to do this?
Thanks
Best Regards

-- 
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


[android-developers] MapView showing up blank with release api key.

2012-11-08 Thread Electric Shipwright
I have an app in which I recently integrated MapView, and It's been working 
with the debug keystore ever since i added the activity showing the 
MapView, so I thought the api key bit was easy enough.
Upon signing with my release key, I find that the MapView shows only a grey 
grid. I read somewhere that It's because you have to publish the app to 
Google Play in order for anything to show up on the map,
so I did, and it did not help.

I just tried creating a blank MapView app with the 
\android-sdk\add-ons\addon-google_apis-google-10\samples, and signed that 
with the same release api key. It worked.
And it works with the debug api key on the full application, too, just not 
the release api key.
To make sure, I created an alternative release key too, based on the same 
keygen alg that the original was created from, I call it "alt". It exhibits 
the same results as my release key.

dbg | rel | alt
NewsApp yes |  no |  no
HelloMapView!   yes | yes | yes

Is it perhaps because one of the apps is associated with a com.app.id on 
Google Play,
that the issue doesn not (yet) occur with the HelloMapView app?
Otherwise, I find it really hard to make anything useful of this...
I'll try cleaning the project and rebuilding.

-- 
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

[android-developers] MapView Overlays move after returning from activity started from onTap

2012-09-23 Thread Na Yang
I have a MapView, with various markers on it. On entering the MapActivity 
the first time, I set the bounds of drawables set on the markers, and 
everything appears fine. The markers and shadows all appear correctly. But 
when I click over to another activity, and return, the shadows, or the 
markers are no longer bound correctly. Sometimes its only some of the 
markers that are affected. Can anyone tell me what is going on here? Here 
is some code. Below is where I set the bounds on the marker drawable:

InputStream is = assetManager.open(imageName);
drawable = Drawable.createFromStream(is, null);
int width = drawable.getIntrinsicWidth();
int height = drawable.getIntrinsicHeight();
drawable.setBounds(-width / 2, -height, width - (width / 2), 0);


And here is how I create/add the overlay item to the map:

GeoPoint point = createGeoPoint(lat, lon);
OverlayItem overlayItem = new OverlayItem(point, character.get_id(), 
"");
Drawable image = drawable;
overlayItem.setMarker(image);
itemizedOverlay.addOverlay(overlayItem);

>From what I can tell, the overlays are not being re-added to the map, this 
is simply a redraw after an onResume() event. Any ideas?

In addition, only images of the type tapped move, and its not the shadow, 
but the image that moves. So, of there are x images of type A, and y images 
of type B, and I tap on any image of type A, all images of type A are 
misaligned with their shadows when I return to the MapActivity, while all 
images of type B are still properly aligned.

This seems to be exclusive to the setMarker() method of setting the image, 
as using the default marker does not exhibit this problem.

-- 
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

Re: [android-developers] MapView search for nearest grocery stores, gas stations, restaurants, etc.

2012-08-13 Thread TreKing
On Mon, Aug 13, 2012 at 5:06 PM, Jason Hsu  wrote:

> Is there a way I can create an Android app that not only pulls up a map
> but ALSO does an AUTOMATIC search for the grocery stores, gas stations, or
> restaurants in my area?  Where can I find a good tutorial that actually
> works?


There is nothing built into Android that will do this automatically. Do a
google search for APIs available to do want you want. Google Places comes
to mind as something to look into.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

Re: [android-developers] MapView search for nearest grocery stores, gas stations, restaurants, etc.

2012-08-13 Thread Mark Murphy
On Mon, Aug 13, 2012 at 6:06 PM, Jason Hsu  wrote:
> Is there a way I can create an Android app that not only pulls up a map but
> ALSO does an AUTOMATIC search for the grocery stores, gas stations, or
> restaurants in my area?

No, sorry.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

_The Busy Coder's Guide to Android Development_ Version 4.0 Available!

-- 
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


[android-developers] MapView search for nearest grocery stores, gas stations, restaurants, etc.

2012-08-13 Thread Jason Hsu
I've gone through the basic MapView tutorials that display a map and even 
overlays.

Is there a way I can create an Android app that not only pulls up a map but 
ALSO does an AUTOMATIC search for the grocery stores, gas stations, or 
restaurants in my area?  Where can I find a good tutorial that actually 
works?

-- 
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

Re: [android-developers] MapView causes my app to crash

2012-07-23 Thread Mark Murphy
Use adb logcat, DDMS, or the LogCat view in Eclipse to examine LogCat
and look at the stack trace associated with your crash.

On Thu, Jul 19, 2012 at 7:15 PM, Lindsay Horst  wrote:
> I am developing and app and am trying to implement google maps as an
> activity of one my buttons. However, whenever I run the app, it crashes. The
> following code works when certain lines are commented out. Without them, I
> can't see the area i wish to zoom in on. I think i've narrowed the issue
> down to the MapView, but i am not sure. Please Help!
>
> Java code
> package com.linzayhrst.cu;
>
> import android.app.Activity;
> import android.database.Observable;
> import android.os.Bundle;
>
> import com.google.android.maps.GeoPoint;
> import com.google.android.maps.MapActivity;
> import com.google.android.maps.MapController;
> import com.google.android.maps.MapView;
> //import com.linzayhrst.cu.R;
>
> import android.widget.TextView;
>
> public class buttonTwo extends MapActivity{
> TextView textOut;
>
> MapController mControl;
> GeoPoint GeoP;
> MapView mapV;
> @Override
> protected void onCreate(Bundle savedInstanceState) {
> // TODO Auto-generated method stub
> super.onCreate(savedInstanceState);
> setContentView(R.layout.buttonscreen2);
> mapV = (MapView) findViewById(R.id.map);
> //mapV.displayZoomControls(true);
> //mapV.setBuiltInZoomControls(true);
> double lat = 43.0042;
> double longi = -88.2279;
> GeoP = new GeoPoint((int)(lat*1E6), (int)(longi*1E6));
> //mControl = mapV.getController();
> //mControl.animateTo(GeoP);
> //mControl.setZoom(18);
> }
> @Override
> protected void onPause() {
> // TODO Auto-generated method stub
> super.onPause();
> }
>
> @Override
> protected void onResume() {
> // TODO Auto-generated method stub
> super.onResume();
> }
>
>
>
> @Override
> protected boolean isRouteDisplayed() {
> // TODO Auto-generated method stub
> return false;
> }
> }
>
>
> xml code
>
> 
>xmlns:android="http://schemas.android.com/apk/res/android";
>   android:orientation="vertical"
>   android:layout_width="match_parent"
>   android:layout_height="match_parent"
>   >
>
> xmlns:android = "http://schemas.android.com/apk/res/android";
> android:id = "@+id/map_view"
>  android:layout_width="fill_parent"
>  android:enabled = "true"
>  android:clickable = "true"
>  android:layout_height="fill_parent"
>  android:apiKey="0_KT38YhEenC4phM3fr6pVM6sJP0x0GlZ2fiQCw"
>  />
>
>
>
> 
>
> --
> 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



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training in NYC: http://marakana.com/training/android/

-- 
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


[android-developers] MapView causes my app to crash

2012-07-22 Thread Lindsay Horst
I am developing and app and am trying to implement google maps as an 
activity of one my buttons. However, whenever I run the app, it crashes. 
The following code works when certain lines are commented out. Without 
them, I can't see the area i wish to zoom in on. I think i've narrowed the 
issue down to the MapView, but i am not sure. Please Help!

*Java code*
package com.linzayhrst.cu;

import android.app.Activity;
import android.database.Observable;
import android.os.Bundle;

import com.google.android.maps.GeoPoint;
import com.google.android.maps.MapActivity;
import com.google.android.maps.MapController;
import com.google.android.maps.MapView;
//import com.linzayhrst.cu.R;

import android.widget.TextView;

public class buttonTwo extends MapActivity{
 TextView textOut;

MapController mControl;
GeoPoint GeoP;
MapView mapV;
 @Override
protected void onCreate(Bundle savedInstanceState) {
// TODO Auto-generated method stub
super.onCreate(savedInstanceState);
setContentView(R.layout.buttonscreen2);
 mapV = (MapView) findViewById(R.id.map);
//mapV.displayZoomControls(true);
//mapV.setBuiltInZoomControls(true);
 double lat = 43.0042;
double longi = -88.2279;
 GeoP = new GeoPoint((int)(lat*1E6), (int)(longi*1E6));
 //mControl = mapV.getController();
//mControl.animateTo(GeoP);
//mControl.setZoom(18);
 }
 @Override
protected void onPause() {
// TODO Auto-generated method stub
super.onPause();
}

@Override
protected void onResume() {
// TODO Auto-generated method stub
super.onResume();
}



@Override
protected boolean isRouteDisplayed() {
// TODO Auto-generated method stub
return false;
}
}


*xml code*
*
*

http://schemas.android.com/apk/res/android";
  android:orientation="vertical"
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  >
 
   http://schemas.android.com/apk/res/android";
android:id = "@+id/map_view"
 android:layout_width="fill_parent"
 android:enabled = "true"
 android:clickable = "true"
 android:layout_height="fill_parent"
 android:apiKey="0_KT38YhEenC4phM3fr6pVM6sJP0x0GlZ2fiQCw"
 />
   




-- 
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

Re: [android-developers] MapView - getMapCenter() not accurate?

2012-05-03 Thread Mark Murphy
On Wed, May 2, 2012 at 10:52 AM, Schurl  wrote:
> I'll try to break down my problem to a simple example. I tried to draw
> a circle which stays exactly in the middle of the view.

Step #1: Put the MapView in RelativeLayout

Step #2: Put an ImageView as a later child in the RelativeLayout, set
to an icon that is your circle

Step #3: Set android:centerInParent="true" on the ImageView in the
layout, to center it within the MapView

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training...At Your Office: http://commonsware.com/training

-- 
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


[android-developers] MapView - getMapCenter() not accurate?

2012-05-02 Thread Schurl
Hi,

I'll try to break down my problem to a simple example. I tried to draw
a circle which stays exactly in the middle of the view. For this i
used the following code in the draw method of my Overlay:



GeoPoint mapCenter = mapView.getMapCenter();
Projection projection = mapView.getProjection();

int centerLat = mapCenter.getLatitudeE6();
int centerLong = mapCenter.getLongitudeE6();

Point pCircleCenter = new Point();

GeoPoint circleCenter = new GeoPoint(centerLat, centerLong);

projection.toPixels(circleCenter, pCircleCenter);

canvas.drawCircle(pCircleCenter.x, pCircleCenter.y, 30, testPaint);

-

When i run the code the circle is exactly in the middle of the screen.
It also stays in the mid when i scroll vertical but when i scroll
horizontal the circle moves slightly in the scrolled direction. The
circle is completely out of position after a few scrolls instead of
staying in the mid.

(This is just a simplified version of my problem but i need to get the
mid this way instead of just sticking it to the middle of the view.)

-- 
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


Re: [android-developers] MapView works on some devices and others it doesnt

2012-02-09 Thread Mark Murphy
The reasons why a MapView might not load tiles:

-- you do not have the INTERNET permission
-- you do not have an Internet connection
-- you have not used the correct Maps API key to go with the signing
key you used to sign the APK

On Thu, Feb 9, 2012 at 2:55 AM, Jim Andresakis  wrote:
> When Im developing I noticed that occasionally the mapview will not
> load tiles. Im using the debug key and I have about 12 different
> devices that I test on including tablets. The mapview usually doesnt
> load on the tmobile mytouch3g which is older hardware at this point
> and Ive never had any complaints after Ive released my app with a real
> key but I was curious if anyone has had the same problem. It just kind
> of bugs me that sometimes the mapview wont load tiles during
> development.
>
> --
> 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



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android 4.0 Programming Books: http://commonsware.com/books

-- 
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


[android-developers] MapView works on some devices and others it doesnt

2012-02-08 Thread Jim Andresakis
When Im developing I noticed that occasionally the mapview will not
load tiles. Im using the debug key and I have about 12 different
devices that I test on including tablets. The mapview usually doesnt
load on the tmobile mytouch3g which is older hardware at this point
and Ive never had any complaints after Ive released my app with a real
key but I was curious if anyone has had the same problem. It just kind
of bugs me that sometimes the mapview wont load tiles during
development.

-- 
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


Re: [android-developers] Mapview adding point

2012-01-05 Thread TreKing
On Thu, Jan 5, 2012 at 3:38 AM, Duygu Kahraman wrote:

> İ dont want to see
> http://codemagician.files.wordpress.com/2010/05/end-result-2.jpg?w=630
>

Then don't show the dialog ...

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

[android-developers] Mapview adding point

2012-01-05 Thread Duygu Kahraman
Hi All;

I am working on google maps. I am using this
http://codemagician.wordpress.com/2010/05/06/android-google-mapview-tutorial-done-right/
.

my problem is i dont want to see screen gettin dark when i add point.

İ dont want to see 
http://codemagician.files.wordpress.com/2010/05/end-result-2.jpg?w=630
.

Can anybody help me?

THX.

-- 
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


[android-developers] Mapview adding point

2012-01-05 Thread Duygu Kahraman
Hi All;

I am working on google maps. I am using this
http://codemagician.wordpress.com/2010/05/06/android-google-mapview-tutorial-done-right/
.

my problem is i dont want to see screen gettin dark when i add point.

İ dont want to see 
http://codemagician.files.wordpress.com/2010/05/end-result-2.jpg?w=630
.

Can anybody help me?

THX.

-- 
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


[android-developers] MapView, Overlay's, TextView too many onDraw

2012-01-04 Thread Wubbester
I have a mapview in RelativeLayout defined in main.xml, that also
includes another layout as a viewstub to display status message to the
users. I set the visibility of the status bar to 'gone' when I inflate
the stub. Thereafter any new message (put on the status bar by a
thread/async task) will set the visibility to 'visible' to display the
message. After the task is done, it remove the message from status bar
and set its visibility to gone. BTW GPS is on to get new lat/lng and
to move the map accordingly and display overlays

Everything is working...but

Question:
There are way to many onDraw into mapview even when the device is not
moving. I traced it to status bar, anytime new a message is put on
status bar, the postInvalidate from there trickles down into mapview,
even though the device has not moved a millimeter, lat/lng have not
changed, no new map tiles are needed etc.  If I remove the status bar,
I see normal invalidates to mapview i.e. 2-3 depending on my logic in
overlay class which I'm OK with. However when I say large
postInvalidates while device is sitting on its behind, they number
around 70-80

Any ideas as to whats going on in/with the view hierarchy, how to
prevent it ? Is this bug?

-- 
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


[android-developers] MapView. is very slow

2011-12-18 Thread DoubleCheese
Hi,
I've beeon doing some profiling to try and speed up our application
and noticed that the MapView. call takes around 4 secs to load.

Using method tracing, i found that it spends 55% of this time in the
MPView. and 45% in the com/google/android/maps/InternalR
$attr..

Is there any way to speed this up? The constructor I use when
initialising the MapView is the MapView(Context context, String
apikey).


thanks,
Dennis

-- 
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


Re: [android-developers] mapview

2011-11-10 Thread Kostya Vasilyev

You can find MapController here:

http://code.google.com/android/add-ons/google-apis/reference/com/google/android/maps/MapController.html 



( sshh, please don't tell anyone I told you... that link is top secret! 
classified! )


Oh, and when something crashes, check the logcat for an error message.

-- Kostya

10.11.2011 18:35, Omollo Ateng ?:
plis give me a full code for that controller and where to use the 
variable map

thank you

On Thu, Nov 10, 2011 at 5:25 PM, Narendra Singh Rathore 
mailto:nsr.curi...@gmail.com>> wrote:


Hey Omollo, it seems you haven't taken MapController.

MapController map = mapView.getController();

Try this, I hope you will succeed.
-- 
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




--
Be good to not only people but also machines

--
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 


--
Kostya Vasilyev

--
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

Re: [android-developers] mapview

2011-11-10 Thread Omollo Ateng
plis give me a full code for that controller and where to use the variable
map
thank you

On Thu, Nov 10, 2011 at 5:25 PM, Narendra Singh Rathore <
nsr.curi...@gmail.com> wrote:

> Hey Omollo, it seems you haven't taken MapController.
>
> MapController map = mapView.getController();
>
> Try this, I hope you will succeed.
>
> --
> 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




-- 
Be good to not only people but also machines

-- 
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

Re: [android-developers] mapview

2011-11-10 Thread Narendra Singh Rathore
Hey Omollo, it seems you haven't taken MapController.

MapController map = mapView.getController();

Try this, I hope you will succeed.

-- 
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

[android-developers] mapview

2011-11-10 Thread Omollo Ateng
hi all, i have developed a map view as explained here
http://developer.android.com/resources/tutorials/views/hello-mapview.html,
but always when i run the application, it crashes, it does not even show
the grey lines, please help me here

*main.xml*

http://schemas.android.com/apk/res/android";
android:id="@+id/map_view"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:clickable="true"
android:apiKey="0_aJsWxo9-vKzgRcVhRkzX68TcTxl5-UgB9ZH_Q"

 />

*
My Manifest file is*


http://schemas.android.com/apk/res/android";
package="com.google.maps" android:versionCode="1"
android:versionName="1.0">
















*My Java file is:*

package com.google.maps;

import com.google.android.maps.MapActivity;
import com.google.android.maps.MapView;

import android.os.Bundle;


public abstract class Campocoz extends MapActivity {
/** Called when the activity is first created. */

private MapView mapView;
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
mapView= (MapView)findViewById(R.id.map_view);
mapView.setBuiltInZoomControls(true);
}
@Override
protected boolean isRouteDisplayed(){
return false;
}
}


Please tell me where i went wrong? The application just crashes, it doesn't
even load the g*rey lines*
Thank you
-- 
Be good to not only people but also machines

-- 
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

Re: [android-developers] MapView rendering with tiles missing with an “x” in the center

2011-09-20 Thread TreKing
On Mon, Sep 19, 2011 at 8:46 PM, tampacoder  wrote:

> Was there a recent update to the Google maps that could have cause this?
>

I don't know but it's certainly possible. This seemed to happen once before
where they apparently had some server issue and many of us noticed a lack of
map tiles on many apps that used the maps library.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

[android-developers] MapView rendering with tiles missing with an “x” in the center

2011-09-20 Thread tampacoder
I posted this over at Stackoverflow; but wanted to reach out to the
developers on this group to see if you can make any suggestions as to
what could be wrong.

Here is what I am seeing in my MapView:

http://dl.dropbox.com/u/6780004/mapview_tiles.png

I'm not doing anything complicated. It just a plain mapview rendered
within a tabactivity. The same code worked for months up until last
week. Not sure if something changed; but this has got me puzzled for
the past couple of days. Somehow, I don't think it's code related
since the same code worked up until last week and I also went back a
couple of weeks in my version control and loaded the source from that
time and still see the issue. Was there a recent update to the Google
maps that could have cause this?

Here is the link to the Stackvoverflow post for those that want to
visit there as well. Thanks

http://stackoverflow.com/questions/7478952/mapview-rendering-with-tiles-missing-with-an-x-in-the-center

-- 
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


Re: [android-developers] MapView OverlayItem

2011-08-31 Thread TreKing
On Wed, Aug 31, 2011 at 12:56 AM, Stefan S  wrote:

> So han can I listen to the onTap Event in the MapActivity-Class?


Create your own callback.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

[android-developers] MapView OverlayItem

2011-08-30 Thread Stefan S
Hi

I've got the following problem:
I've implemented a mapView with some different OverlayItems on the
Map. I also can react on the onTap(int) event in my Class which
extends from ItemizedOverlay. I can send some Toast
messages and so on.
But what i want to do is to get the selected Index from the onTap-
Event back to the MainActivity which extends from the MapActivity
Class and the close this Activity and pass the index back to the
previous Actiivty.

So han can I listen to the onTap Event in the MapActivity-Class?

Thanks in advance

-- 
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


[android-developers] MapView in Fragment using compat library

2011-08-30 Thread Watcher
Some months back, someone posted a hack to the compatibility library
to get a MapView to display in a fragment (see posts by @Streets of
Boston): 
http://groups.google.com/group/android-developers/browse_frm/thread/b705bbd72d28d000/df84933c3a460c71?pli=1

Indeed this does display the mapview in the fragment but when I
replace it with another fragment and then replace that one with the
map fragment again, I get the dreaded "You are only allowed to have a
single MapView in a MapActivity".

Has anyone gotten this to work ?

Diane & the Google team, can you give us an official fix for this;
it's really a problem for people building apps using fragments.

Thanks

-- 
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


Re: [android-developers] MapView

2011-08-29 Thread Robert Thau
The most common cause of this sort of misbehavior is forgetting to request
internet access permission in the Android manifest (without which the
MapView's
background threads don't have permission to fetch the tiles).

On Tue, Aug 30, 2011 at 12:31 AM, bob  wrote:

> I'm working with maps for the first time, but all I get is this grid:
>
> http://i1190.photobucket.com/albums/z449/m75214/blankgrid.png
>
> Any ideas?
>
> Here's my code:
>
> import com.google.android.maps.GeoPoint;
> import com.google.android.maps.MapActivity;
> import com.google.android.maps.MapController;
> import com.google.android.maps.MapView;
>
> import android.app.Activity;
> import android.os.Bundle;
>
> public class hmm extends MapActivity {
>private MapController mapController;
>private MapView mapView;
>
>/** Called when the activity is first created. */
>@Override
>public void onCreate(Bundle savedInstanceState) {
>super.onCreate(savedInstanceState);
>setContentView(R.layout.main);
>mapView = (MapView) findViewById(R.id.mapview);
>
>mapView.setBuiltInZoomControls(true);
>mapView.setStreetView(true);
>mapController = mapView.getController();
>mapController.setZoom(14);
>int lat=(int) (32.969185f * 1E6);
>int lng=(int) (-96.60576f * 1E6);
>GeoPoint point = new GeoPoint(lat, lng);
>mapController.animateTo(point);
>}
>
>@Override
>protected boolean isRouteDisplayed() {
>// TODO Auto-generated method stub
>return false;
>}
> }
>
> --
> 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 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

[android-developers] MapView

2011-08-29 Thread bob
I'm working with maps for the first time, but all I get is this grid:

http://i1190.photobucket.com/albums/z449/m75214/blankgrid.png

Any ideas?

Here's my code:

import com.google.android.maps.GeoPoint;
import com.google.android.maps.MapActivity;
import com.google.android.maps.MapController;
import com.google.android.maps.MapView;

import android.app.Activity;
import android.os.Bundle;

public class hmm extends MapActivity {
private MapController mapController;
private MapView mapView;

/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
mapView = (MapView) findViewById(R.id.mapview);

mapView.setBuiltInZoomControls(true);
mapView.setStreetView(true);
mapController = mapView.getController();
mapController.setZoom(14);
int lat=(int) (32.969185f * 1E6);
int lng=(int) (-96.60576f * 1E6);
GeoPoint point = new GeoPoint(lat, lng);
mapController.animateTo(point);
}

@Override
protected boolean isRouteDisplayed() {
// TODO Auto-generated method stub
return false;
}
}

-- 
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


Re: [android-developers] MapView Tiles not loading on my device, they are in my emulator

2011-08-04 Thread TreKing
On Thu, Aug 4, 2011 at 11:40 AM, Tonez  wrote:

> Can anyone shed some light as to what it is that I'm missing to get the
> mapView tiles to load on my device for testing?
>

If you are still debugging ("debuggable = true") then that should work. If
you switched to release mode, you now need a separate key for your release /
signing certificate.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

[android-developers] MapView Tiles not loading on my device, they are in my emulator

2011-08-04 Thread Tonez
Hi Everyone,

I'm currently building an app which utilizes the mapView component -
I've gotten to the point where I need to test on an actual device but
unfortunately the mapView tiles won't load.  Steps I took to get to
this point are as follows:  I followed the instruction on the
'Obtaining a Maps API Key' Google web page and retrieved an API key
using an MD5 fingerprint from my debug certificate.  Pasted it into
the android:apiKey property of my mapView and fired up my emulator.
Works perfectly - mapView tiles load as expected.  Without touching my
project, I tried debugging on the device and doing so results in the
tiles of my mapView not loading at all.

The device I'm testing on is an LG GT540 running Android 2.1-update1.

Can anyone shed some light as to what it is that I'm missing to get
the mapView tiles to load on my device for testing?

Many thanks.

-- 
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


[android-developers] MapView get map bounds issue

2011-08-04 Thread pavel
Hello. I have a problem with MapView and getting bounds of visible map
area (in geographical units).

I am aware that I have to get this value when map is drawn, I am
reading them in a different thread, after map is drawn.

The problem is that at certain zoom point and map position,
getLatitudeSpan() method returns 0. To get this you can try zooiming
map and then srolling it to the top (the half of the screen will be
white then, the rest is an actual map).I thought that I will get
latitudeSpan, longitudeSpan, center point and simply calculate bounds,
but since latitudeSpan is 0 I will get the same top and bottom
coordinates,

I also tried with getProjection.from(x,y) method to get coordinates of
top and bottom of the screen and that substract them. But here is
similiar situation. For (0,0) point it returns latitude 80, for (0,
getHeight()) it also returns latitude 80.In fact there are different
latitudes.

I would appreciate any help.
Thanks in advance.

-- 
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


[android-developers] MapView NullPointerException / Black MapView in Fragment on Android 3.0

2011-07-14 Thread p.sturm
Unfortunately, I can't attach source code, but I will try to describe
the problem. I created a Fragment containing an instance of a class
extending MapView. The instance of this class is instantiated
programmatically, the constructor of the custom MapView calls the
MapView(Context c, String apiKey) constructor of the super class. When
starting the Activity containing the MapView (the Activity is a
MapActivity), the MapView gets displayed properly, but when I attempt
to change the orientation (configuration change), the instantiation of
the custom MapView fails with the following stacktrace:


07-13 16:51:41.270: ERROR/AndroidRuntime(20412): Caused by:
java.lang.NullPointerException
07-13 16:51:41.270: ERROR/AndroidRuntime(20412): at
com.google.android.maps.MapActivity.setupMapView(MapActivity.java:400)
07-13 16:51:41.270: ERROR/AndroidRuntime(20412): at
com.google.android.maps.MapView.(MapView.java:289)
07-13 16:51:41.270: ERROR/AndroidRuntime(20412): at
com.google.android.maps.MapView.(MapView.java:235)
07-13 16:51:41.270: ERROR/AndroidRuntime(20412): at
mypackage.MyCustomMapView.(MyCustomMapView.java:36)

As one can see, the NullPointerException happens somewhere in the SDK.
Now,  I have tried to retain the instance of the Fragment using
fragment.setRetainInstance(true). This obviously stops the code
failing at this point, but the MapView remains black after the
orientation change has been finished. Calling invalidate() on the
MapView or any of its parent views does not change the situation. My
theory is that the MapView does not resume properly, but I am not sure
how to determine if that is the case. Any suggestions would be
appreciated (either on the NullPointerException or the black MapView
when setRetainInstance(true) is used).


Patrick

-- 
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


Re: [android-developers] MapView and terms of service

2011-07-07 Thread Mark Murphy
This is a fine question to ask your attorney.

On Thu, Jul 7, 2011 at 4:18 AM, Fina Perez  wrote:
> Hi all!
>
> I use the Google API in my app and I have a question about the logo on
> the map. I don't modify it when I display the map, but If I display
> the route between two points, I paint two buttons onto the map. One of
> this buttons is drawn over the logo (left corner on the bottom of the
> screen) and this button is only visible if I'm displaying a route. Do
> you think this a violation of the terms of service (http://
> code.google.com/apis/maps/terms.html)? Exactly, this point:
>
> "9.4 Attribution.
>
> (a) Content provided to you through the Service may contain the trade
> names, trademarks, service marks, logos, domain names, and other
> distinctive brand features of Google, its partners, or other third
> party rights holders of content indexed by Google. When Google
> provides this attribution, you must display it as provided through the
> Service or as described in the Maps APIs Documentation and may not
> delete or in any manner alter these trade names, trademarks, service
> marks, logos, domain names, and other distinctive brand features"
>
>
> Thanks
>
> --
> 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
>



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training...At Your Office: http://commonsware.com/training

-- 
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


[android-developers] MapView and terms of service

2011-07-07 Thread Fina Perez
Hi all!

I use the Google API in my app and I have a question about the logo on
the map. I don't modify it when I display the map, but If I display
the route between two points, I paint two buttons onto the map. One of
this buttons is drawn over the logo (left corner on the bottom of the
screen) and this button is only visible if I'm displaying a route. Do
you think this a violation of the terms of service (http://
code.google.com/apis/maps/terms.html)? Exactly, this point:

"9.4 Attribution.

(a) Content provided to you through the Service may contain the trade
names, trademarks, service marks, logos, domain names, and other
distinctive brand features of Google, its partners, or other third
party rights holders of content indexed by Google. When Google
provides this attribution, you must display it as provided through the
Service or as described in the Maps APIs Documentation and may not
delete or in any manner alter these trade names, trademarks, service
marks, logos, domain names, and other distinctive brand features"


Thanks

-- 
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


Re: [android-developers] MapView Overlay problem

2011-06-30 Thread TreKing
On Thu, Jun 30, 2011 at 4:46 PM, Felix Garcia Lainez <
fgarcialai...@gmail.com> wrote:

> On this method i iterate over an array of GeoPoints and using a canvas y
> connect all points.
>

What's your actual code?


> It works fine more or less, but i am having issues when drawing long routes
> with many points.
>

Define "long routes" and "many points".

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

[android-developers] MapView Overlay problem

2011-06-30 Thread Felix Garcia Lainez
Hello,

The case is that i want to show a route on a MapView. Something simple
at first sight, simply i created a class that extends overlay and
implement draw method. On this method i iterate over an array of
GeoPoints and using a canvas y connect all points. It works fine more
or less, but i am having issues when drawing long routes with many
points. The problem is that application is very slow, and sometimes
MapActivity is closed simply doing a zoom in or zoom out on the map
with the route drawn...

My question is how to improve performance on this situation

Thanks!

-- 
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


Re: [android-developers] Mapview can not be resolved to a type

2011-06-23 Thread Samson Akisanya
Check ur android properties of your project...it should be set to Google api
not 2.2 etc
On 23 Jun 2011 23:43, "juhi paunikar"  wrote:
> Hi,
> i tried the project which is given belows link:
> http://developer.android.com/resources/tutorials/views/hello-mapview.html
>
> i am getting error as given below:
> Mapview can not be resolved to a type.
>
> Can anybody give me suggestion to solve this problem???
>
> --
> 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 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

Re: [android-developers] Mapview can not be resolved to a type

2011-06-23 Thread Mark Murphy
Change your build target to one that has Google Maps. In Eclipse, this
is in the Android portion of project properties. For command-line
builds, this is in default.properties.

On Thu, Jun 23, 2011 at 8:18 AM, juhi paunikar  wrote:
> Hi,
> i tried the project which is given belows link:
> http://developer.android.com/resources/tutorials/views/hello-mapview.html
>
> i am getting error as given below:
> Mapview can not be resolved to a type.
>
> Can anybody give me suggestion to solve this problem???
>
> --
> 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
>



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training in London: http://bit.ly/smand1, http://bit.ly/smand2

-- 
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


[android-developers] Mapview can not be resolved to a type

2011-06-23 Thread juhi paunikar
Hi,
i tried the project which is given belows link:
http://developer.android.com/resources/tutorials/views/hello-mapview.html

i am getting error as given below:
Mapview can not be resolved to a type.

Can anybody give me suggestion to solve this problem???

-- 
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


[android-developers] Mapview im Tab --> import com.google.* gehen nicht

2011-06-20 Thread Mathias Dorn
Hi,
habe eine App, mit ner Tab-View
MainActivity mit 2 Tab´s, die auf mapActivity und logActivity
verweisen

jetzt ist das problem ist jetzt nur, das die mapactivity (ganz simple
mapview) die googleApi nicht "kennt"
da ich die MapActivity einzeln schon getestet habe, weiß ich das die
auch läuft
ich vermute mal das das geheimnis im manifest liegt ... ich poste es
mal

1
2http://schemas.android.com/apk/res/android";
3 package="de.hsMerseburg.gesTracker"
4 android:versionCode="1"
5 android:versionName="1.0">
6 
7
8 
9 
10 
11
12 
13 
14 
18 
19 
20 
21 
22 
23
24 
25 
26
27 
28

-- 
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


[android-developers] MapView not working

2011-06-17 Thread Xanthanov
Your Activity class has to extend MapActivity.

You have to override the abstract method isRouteDisplayed() to just
return false (or true if your app actually displays routes).

~Xan

-- 
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


Re: [android-developers] MapView - infowindow

2011-04-13 Thread TreKing
On Tue, Apr 12, 2011 at 3:49 PM, Richard Sámela wrote:

> please give me some advice or link me to some tutorial.


Google "Android Map Tutorial"

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

[android-developers] MapView - infowindow

2011-04-12 Thread Richard Sámela
Hallo,
pls give me some advice how can I implement some infowindow do MapView
in my app. I think something like this:
[img]http://feromakovi.tym.sk/infowindow.png[/img]
or original infowindow, the same as is used in google maps app, in
which is for example my name.
please give me some advice or link me to some tutorial.
thank you very much.

Richard Sámela

-- 
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


Re: [android-developers] MapView

2011-04-03 Thread Mark Murphy
Use a LinearLayout as the container for the map and the TableLayout.
Give the map a height of 0 and a weight of 1. Give the table whatever
height makes sense and no weight.

Or, use a RelativeLayout as the container for the map and the
TableLayout. Anchor the TableLayout to the right/left/bottom. Anchor
the map to the right/left/top and to the top of the TableLayout.

On Sun, Apr 3, 2011 at 12:52 PM, Daniel Rindt
 wrote:
> Hello,
>
> i would build a layout where i can have on top a google map on the
> bottom should appear a table layout with some content and a button.
> How to implement such a layout, i tried it a couple of hours now, and
> my summary is that the map is all the time over the entire screen. I
> can set the height of the map for example 120dp that works, but i want
> that the map is stretching like match_parent. With the height
> definition of the table on bottom i could life.
>
> Thanks for all suggestions.
> Daniel
>
> --
> 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
>



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

_Android Programming Tutorials_ Version 3.3 Available!

-- 
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


[android-developers] MapView

2011-04-03 Thread Daniel Rindt
Hello,

i would build a layout where i can have on top a google map on the
bottom should appear a table layout with some content and a button.
How to implement such a layout, i tried it a couple of hours now, and
my summary is that the map is all the time over the entire screen. I
can set the height of the map for example 120dp that works, but i want
that the map is stretching like match_parent. With the height
definition of the table on bottom i could life.

Thanks for all suggestions.
Daniel

-- 
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


[android-developers] Mapview not touchable

2011-03-30 Thread Shreesh
Hi,

I seem to have run into a problem with the mapview not pick touchable
if setZoomControl(true) is used. The issue seems to be that anytime
this is switched on the mapview is not touchable. And this seems to be
a one time thing - anytime this zoom is switched on and even if it is
switched off later - the mapview is not touchable. Also it seems the
touch even occurs once and after that I can never trap it i.e. the
touch handler never gets called. I retrn false from the touch handler.
The overlays I have are fine and touchable.

Fundamentally we want to build in the feature where the user can touch
the map when an overlay is up to dismiss the overlay. I have a onTouch
event handler for the mapview.

Thanks,
Shreesh

-- 
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


[android-developers] Mapview ArrayIndexOutOfBoundsException in java.util.Vector.elementAt

2011-03-13 Thread Ricky
I really need some help. I have a report of a force close with this
stack trace, and I cant find any information on how to prevent this
type of error.


java.util.Vector.elementAt(Vector.java:331)
com.google.googlenav.map.Map.drawTile(Unknown Source)
com.google.googlenav.map.Map.drawMapBackground(Unknown Source)
com.google.googlenav.map.Map.drawMap(Unknown Source)
com.google.android.maps.MapView.drawMap(MapView.java:1048)
com.google.android.maps.MapView.onDraw(MapView.java:486)
android.view.View.draw(View.java:6535)
android.view.ViewGroup.drawChild(ViewGroup.java:1531)
android.view.ViewGroup.dispatchDraw(ViewGroup.java:1258)
android.view.View.draw(View.java:6538)
android.view.ViewGroup.drawChild(ViewGroup.java:1531)
android.view.ViewGroup.dispatchDraw(ViewGroup.java:1258)
android.view.View.draw(View.java:6538)
android.widget.FrameLayout.draw(FrameLayout.java:352)
android.view.ViewGroup.drawChild(ViewGroup.java:1531)
android.view.ViewGroup.dispatchDraw(ViewGroup.java:1258)
android.view.View.draw(View.java:6538)
android.widget.FrameLayout.draw(FrameLayout.java:352)
com.android.internal.policy.impl.PhoneWindow
$DecorView.draw(PhoneWindow.java:1830)
android.view.ViewRoot.draw(ViewRoot.java:1349)
android.view.ViewRoot.performTraversals(ViewRoot.java:1114)
android.view.ViewRoot.handleMessage(ViewRoot.java:1633)
android.os.Handler.dispatchMessage(Handler.java:99)
android.os.Looper.loop(Looper.java:123)
android.app.ActivityThread.main(ActivityThread.java:4363)
java.lang.reflect.Method.invokeNative(Native Method)
java.lang.reflect.Method.invoke(Method.java:521)
com.android.internal.os.ZygoteInit
$MethodAndArgsCaller.run(ZygoteInit.java:860)
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
dalvik.system.NativeStart.main(Native Method)

-- 
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


[android-developers] MapView and large number of Overlay

2011-03-07 Thread Dani
Hi,
I have a problem displaying on a MapView a large number of Overlays. I
have to draw many route paths on the map: I tried to extend Overlay
class but the method draw() is calling very often and it makes
rendering too slow.
So I tried to create a bitmap to append over the map as a OverlayItem
layer (with transparency), it works but it is a little slow on
creating the image and there's a problem about memory of the VM that I
must handle.
I'm finding the best way to draw this semi-static layer as fast as
possible, I'm glad if someone can give me some advice
thank you
Daniele

-- 
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


[android-developers] MapView out of memory exception workaround

2011-02-23 Thread Ravi
Map view has a memory leak which was discussed in this thread :
http://code.google.com/p/android/issues/detail?id=2181 .

Has it be resolved? Else is there any other workaround for the same?

-- 
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


答复: [android-developers] MapView in android emul ator white screen

2010-10-22 Thread goodwin
Hi James 
Are you sure that your emulator has an internet connection..


-邮件原件-
发件人: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] 代表 jamz_mar...@yahoo.co.jp
发送时间: 2010年10月20日 1:04
收件人: Android Developers
抄送: jamz_mar...@yahoo.co.jp
主题: [android-developers] MapView in android emulator white screen

Hi Android Developers,

I tried to use map view to load google map, i have generated the
keystore, and put in the mapview, below is my MapView, and also I have
changed the Custom debug keystore equal to default debug keystore but
still showing me a empty screen. please advise which on i am wrong. I
use google api 2.2

 

Thanks,
James

-- 
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 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


Re: [android-developers] MapView in android emulator white screen

2010-10-21 Thread Mark Murphy
Test the Maps application on the emulator. If that fails, you have a
problem accessing the maps server. If that works, then check LogCat
for error messages (use adb logcat, DDMS, or the DDMS perspective in
Eclipse).

On Tue, Oct 19, 2010 at 1:04 PM, jamz_mar...@yahoo.co.jp
 wrote:
> Hi Android Developers,
>
> I tried to use map view to load google map, i have generated the
> keystore, and put in the mapview, below is my MapView, and also I have
> changed the Custom debug keystore equal to default debug keystore but
> still showing me a empty screen. please advise which on i am wrong. I
> use google api 2.2
>
>          android:layout_width="fill_parent"
>        android:layout_height="fill_parent"
>        android:enabled="true"
>        android:clickable="true"
>        android:apiKey="07WVUg-srWUbhpkGj1mi0w56xD9nMEu0NhqJeYg"
>        />
>
> Thanks,
> James
>
> --
> 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
>



-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android App Developer Books: http://commonsware.com/books

-- 
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


[android-developers] MapView in android emulator white screen

2010-10-21 Thread jamz_mar...@yahoo.co.jp
Hi Android Developers,

I tried to use map view to load google map, i have generated the
keystore, and put in the mapview, below is my MapView, and also I have
changed the Custom debug keystore equal to default debug keystore but
still showing me a empty screen. please advise which on i am wrong. I
use google api 2.2

 

Thanks,
James

-- 
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


Re: [android-developers] MapView In Android

2010-10-06 Thread TreKing
On Tue, Sep 28, 2010 at 6:31 AM, aneesh Kamalone wrote:

> How to solve it . If needs i will put the code also.


That stack trace with the full error and the relevant parts of the code
would indeed help.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

[android-developers] MapView In Android

2010-10-06 Thread aneesh Kamalone
Hai,

I am Using a MapView in my application and showing the map according to the
longitude and latitude getting by the other part of the application. The
logintude and latitude may change according to the user input. The First
time map showing correctly but from the second time onwards it shows
"android.view.InfalteException". How to solve it . If needs i will put the
code also.

Please Help,
Thank you.

-- 
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

RE: [android-developers] MapView Points of Interest

2010-09-03 Thread Tommy
Interesting. I guess I'll have to do some digging around to find out how to
add that to the web based version. Thanks for the input/advice!

-Original Message-
From: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] On Behalf Of Mark Murphy
Sent: Friday, September 03, 2010 10:39 AM
To: android-developers@googlegroups.com
Subject: Re: [android-developers] MapView Points of Interest

On Fri, Sep 3, 2010 at 10:32 AM, Tommy  wrote:
> Is there a way to display points of interest like gas stations,
> hospitals etc using google maps?

For the Android Google Maps, there is no overlay available to
developers to add those items to a map. If you know where they are,
you could create your own overlay, but finding out where they are
could be painful (particularly given the Geocoder problems people seem
to have been having).

Now, if you integrate the Web-based Maps via a WebView widget, you may
have greater options -- I haven't used that, but others have.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

_The Busy Coder's Guide to Android Development_ Version 3.1 Available!

-- 
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 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


Re: [android-developers] MapView Points of Interest

2010-09-03 Thread Mark Murphy
On Fri, Sep 3, 2010 at 10:32 AM, Tommy  wrote:
> Is there a way to display points of interest like gas stations,
> hospitals etc using google maps?

For the Android Google Maps, there is no overlay available to
developers to add those items to a map. If you know where they are,
you could create your own overlay, but finding out where they are
could be painful (particularly given the Geocoder problems people seem
to have been having).

Now, if you integrate the Web-based Maps via a WebView widget, you may
have greater options -- I haven't used that, but others have.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

_The Busy Coder's Guide to Android Development_ Version 3.1 Available!

-- 
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


[android-developers] MapView Points of Interest

2010-09-03 Thread Tommy
Hi everyone,

Is there a way to display points of interest like gas stations,
hospitals etc using google maps?

-- 
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


Re: [android-developers] MapView + Image Overlay question

2010-08-29 Thread Frank Weiss
A simple solution: prevent zoom.

Crummy solution: scale the images.

Best solution: prescaled images on server, if possible.

-- 
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


[android-developers] MapView + Image Overlay question

2010-08-29 Thread Tommy
Hi everyone,

I currently have a mapview and I want to overlay radar images from the
NWS ontop of my mapview. Just like weatherbug does or the
weatherchannel. My problem is I can't seem to figure out how to make
the image I get lay ontop of the "box" the image is suppose to cover.
The images are 600 x 550 and when I place them on the map they don't
change size according to zoom level. Is there an example of how this
can be done any place or could anyone explain how I should go about
accomplishing this?

Thanks in advance for the help,

Tommy

-- 
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


Re: [android-developers] MapView + LocationManager Question

2010-08-26 Thread Sebastián Treu
On Tue, Aug 10, 2010 at 9:31 PM, TreKing  wrote:
> On Tue, Aug 10, 2010 at 4:40 PM, Tommy  wrote:
>>
>> So if I were to set requestLocationUpdates(String provider, 6, 0,
>> LocationListener listener, Looper looper) it would be the same on the batter
>> as if I were to set a timer for every 1 minute or whatever to call up the
>> GPS again?
>
> Yes, or better, I'd think. Having the GPS connected but not doing anything
> would probably be better than having it reconnect each time. That initial
> start up is probably a good chunk of the batter use.

I'm doing field-test with a device. And, I will not encourage people
that want a precise (about 5-8 meters) point to use minTime. Using it
so, will turn off the Gps engine (STOPPED), start it again (STARTED),
and trying to get a position. That takes about >10 seconds. After that
you can take a not so accurate point. And, if it's for a pedestrian,
the guy is 10 meters away (less than your desired accuracy).

The best solution I found so far is not using minTime, and use the
entire GPS engine during the use of the application or service. I had
to decide between battery power or precision. I choose precision, as
is a pedestrian guide for tourists. I know tourist aren't in a rush,
but you can't assume that.

I'll made a stress battery test after a full charge leaving the phone
with the application running without setting minTime or distance and
I'll let you know how much power consumes in a samsun i5700.

-- 
If you want freedom, compile the source.

Sebastián Treu
http://labombiya.com.ar

-- 
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


[android-developers] MapView singleton issue

2010-08-24 Thread SImplyG2010
Hey All,

Has anyone soon an issue with using two different sized map view on
two screens? I am getting a problem as follows.

1) Add a full screen map to a Activity with an overlay.
2) On tap for the overlay item start a new activity with a small
mapview say 1/3 of the screen. Zoom the mapview in to zoom level 21.
3) Close the new activity exposing the old activity.
4) The zoom level of the old activities map has changed and also there
is probably now a black bar at the bottom.

Any ideas why this might be happening?

-- 
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


RE: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Tommy
Awesome, I was actually planning on running two seprate tests and see which
gives me better performance, but I agree starting it up probably does use a
good chunk of the battery but I guess it would depend on how often it is set
to start up. I have a feeling that using the way it was intended to be used
will probably turn out to be the most efficent way though.

 

From: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] On Behalf Of TreKing
Sent: Tuesday, August 10, 2010 8:31 PM
To: android-developers@googlegroups.com
Subject: Re: [android-developers] MapView + LocationManager Question

 

On Tue, Aug 10, 2010 at 4:40 PM, Tommy  wrote:

So if I were to set requestLocationUpdates(String provider, 6, 0,
LocationListener listener, Looper looper) it would be the same on the batter
as if I were to set a timer for every 1 minute or whatever to call up the
GPS again?

 

Yes, or better, I'd think. Having the GPS connected but not doing anything
would probably be better than having it reconnect each time. That initial
start up is probably a good chunk of the batter use.

 

I just don't want it in constant communication with the GPS satellites.

 

It won't be.

 

I want it to check every X minutes then Shut down. I assumed that calling
requestLocaitonUpdates keeps the connection open and active but only fires
off onLocationChanged event according to the parameters inside the
requestLocationUpdates.


The documentation is not very clear, but based on my experience with the
function:

Specifying a time means there's no connection whatsoever for at least that
long (what you want) and the GPS will not check for location updates.

 

Specifying a distance means that the GPS will turn on and check periodically
for having moved that far and, if it has, will then call on the listener.

I highly recommend you just use this function instead of managing this with
your own timer. You're adding more complexity needlessly.



-
TreKing <http://sites.google.com/site/rezmobileapps/treking>  - Chicago
transit tracking app for Android-powered devices

-- 
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 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

Re: [android-developers] MapView + LocationManager Question

2010-08-10 Thread TreKing
On Tue, Aug 10, 2010 at 4:40 PM, Tommy  wrote:

> So if I were to set requestLocationUpdates(String provider, 6, 0,
> LocationListener listener, Looper looper) it would be the same on the batter
> as if I were to set a timer for every 1 minute or whatever to call up the
> GPS again?


Yes, or better, I'd think. Having the GPS connected but not doing anything
would probably be better than having it reconnect each time. That initial
start up is probably a good chunk of the batter use.


> I just don't want it in constant communication with the GPS satellites.


It won't be.


> I want it to check every X minutes then Shut down. I assumed that calling
> requestLocaitonUpdates keeps the connection open and active but only fires
> off onLocationChanged event according to the parameters inside the
> requestLocationUpdates.


The documentation is not very clear, but based on my experience with the
function:
Specifying a time means there's no connection whatsoever for at least that
long (what you want) and the GPS will not check for location updates.

Specifying a distance means that the GPS will turn on and check periodically
for having moved that far and, if it has, will then call on the listener.

I highly recommend you just use this function instead of managing this with
your own timer. You're adding more complexity needlessly.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

RE: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Tommy
Yeah I completly agree, I plan on putting that option in plus options on how
often to track so they can choose what they want.

-Original Message-
From: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] On Behalf Of Frank Weiss
Sent: Tuesday, August 10, 2010 6:17 PM
To: android-developers@googlegroups.com
Subject: Re: [android-developers] MapView + LocationManager Question

It may also be good practice to give the user the option to turn GPS
off for your application. That is, when the option is off, your
application removes location updates.

The idea is that the user can still use your application, but can
control the battery usage. Of course, in this case, the user loses the
tracking feature, which may or may not be a good thing depending on
the user's perspective.

-- 
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 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


Re: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Frank Weiss
It may also be good practice to give the user the option to turn GPS
off for your application. That is, when the option is off, your
application removes location updates.

The idea is that the user can still use your application, but can
control the battery usage. Of course, in this case, the user loses the
tracking feature, which may or may not be a good thing depending on
the user's perspective.

-- 
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


RE: RE: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Tommy
Everyone,

 

Thank you all for your input,time, and suggestions. I figured out why I was
having the issue as Kostya Vasilyev suggested I was creating a threading
problem! It is always the small things that cause me the big issues. Again
thanks to everyone who responded to this thread. As always the Android
Forums comes through with shining colors.

 

From: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] On Behalf Of Kostya Vasilyev
Sent: Tuesday, August 10, 2010 5:50 PM
To: android-developers@googlegroups.com
Subject: Re: RE: [android-developers] MapView + LocationManager Question

 

I wonder if this is a threading issue. Your code uses Timer to schedule the
next time you request a location update. I believe it's a Java SDK class,
and can invoke your runnable on its own thread.

Have you tried using a Handler? It's an Android class, and will invoke your
runnable on the UI thread. I wonder if that might make a difference.

--
Kostya Vasilyev -- http://kmansoft.wordpress.com

11.08.2010 1:41 пользователь "Tommy"  написал:

So if I were to set requestLocationUpdates(String provider, 6, 0,
LocationListener listener, Looper looper) it would be the same on the batter
as if I were to set a timer for every 1 minute or whatever to call up the
GPS again? I just don't want it in constant communication with the GPS
satellites. I want it to check every X minutes then Shut down. I assumed
that calling requestLocaitonUpdates keeps the connection open and active but
only fires off onLocationChanged event according to the parameters inside
the requestLocationUpdates. 

 

This is why I am confused as to why my onLocationChanged event only fires
the first time I call requestLocationUpdates. Thenin the onLocationChanged I
call RemoveUpdates. This removes the GPS icon in the notification bar. Then
in X minutes I want to repeat it all again, but at that time, the timer
fires but no GPS icon shows up and my events to fire in onLocationChanged.

 

Am I making enough sense in what I want to accomplish? 

 

From: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] On Behalf Of Costantinos Costa
Sent: Tuesday, August 10, 2010 5:31 PM


To: android-developers@googlegroups.com
Subject: Re: [android-developers] MapView + LocationManager...

 

Dear Tommy,



 The function requestLocationUpdates is offering the utility to set the
interval time for gps to c...



On Wed, Aug 11, 2010 at 12:13 AM, Tommy  wrote:

Hi everyone,

I am currently w...

-- 

You received this message because you are subscribed to the Google
Groups "Android Developers" group...

-- 
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 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

Re: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Costantinos Costa
Friend Tommy,

I understand that your goal is to reduce energy consuption by reduce GPS
connection needed energy .
I believe and i did a little search about this that if you have a connection
with the satellite and just don't transfer any data
the energy consumption is smaller than turn off and turn on again the GPS
.So in my opinion is better to just remove updates or turn off gps when you
don't need that any more.When a connection is inactive the energy mode is
change to "sleep mode".

-- 
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

RE: RE: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Tommy
O SHOOT! I wonder if your rightI'll give the handler or the RunOnUI
thread a try once I get back to the office!!! Thanks for mentioning that !!!

 

From: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] On Behalf Of Kostya Vasilyev
Sent: Tuesday, August 10, 2010 5:50 PM
To: android-developers@googlegroups.com
Subject: Re: RE: [android-developers] MapView + LocationManager Question

 

I wonder if this is a threading issue. Your code uses Timer to schedule the
next time you request a location update. I believe it's a Java SDK class,
and can invoke your runnable on its own thread.

Have you tried using a Handler? It's an Android class, and will invoke your
runnable on the UI thread. I wonder if that might make a difference.

--
Kostya Vasilyev -- http://kmansoft.wordpress.com

11.08.2010 1:41 пользователь "Tommy"  написал:

So if I were to set requestLocationUpdates(String provider, 6, 0,
LocationListener listener, Looper looper) it would be the same on the batter
as if I were to set a timer for every 1 minute or whatever to call up the
GPS again? I just don't want it in constant communication with the GPS
satellites. I want it to check every X minutes then Shut down. I assumed
that calling requestLocaitonUpdates keeps the connection open and active but
only fires off onLocationChanged event according to the parameters inside
the requestLocationUpdates. 

 

This is why I am confused as to why my onLocationChanged event only fires
the first time I call requestLocationUpdates. Thenin the onLocationChanged I
call RemoveUpdates. This removes the GPS icon in the notification bar. Then
in X minutes I want to repeat it all again, but at that time, the timer
fires but no GPS icon shows up and my events to fire in onLocationChanged.

 

Am I making enough sense in what I want to accomplish? 

 

From: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] On Behalf Of Costantinos Costa
Sent: Tuesday, August 10, 2010 5:31 PM


To: android-developers@googlegroups.com
Subject: Re: [android-developers] MapView + LocationManager...

 

Dear Tommy,



 The function requestLocationUpdates is offering the utility to set the
interval time for gps to c...



On Wed, Aug 11, 2010 at 12:13 AM, Tommy  wrote:

Hi everyone,

I am currently w...

-- 

You received this message because you are subscribed to the Google
Groups "Android Developers" group...

-- 
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 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

Re: RE: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Kostya Vasilyev
I wonder if this is a threading issue. Your code uses Timer to schedule the
next time you request a location update. I believe it's a Java SDK class,
and can invoke your runnable on its own thread.

Have you tried using a Handler? It's an Android class, and will invoke your
runnable on the UI thread. I wonder if that might make a difference.

--
Kostya Vasilyev -- http://kmansoft.wordpress.com

11.08.2010 1:41 пользователь "Tommy"  написал:

 So if I were to set requestLocationUpdates(String provider, 6, 0,
LocationListener listener, Looper looper) it would be the same on the batter
as if I were to set a timer for every 1 minute or whatever to call up the
GPS again? I just don't want it in constant communication with the GPS
satellites. I want it to check every X minutes then Shut down. I assumed
that calling requestLocaitonUpdates keeps the connection open and active but
only fires off onLocationChanged event according to the parameters inside
the requestLocationUpdates.



This is why I am confused as to why my onLocationChanged event only fires
the first time I call requestLocationUpdates. Thenin the onLocationChanged I
call RemoveUpdates. This removes the GPS icon in the notification bar. Then
in X minutes I want to repeat it all again, but at that time, the timer
fires but no GPS icon shows up and my events to fire in onLocationChanged.



Am I making enough sense in what I want to accomplish?



*From:* android-developers@googlegroups.com [mailto:
android-develop...@googlegroups.com] *On Behalf Of *Costantinos Costa
*Sent:* Tuesday, August 10, 2010 5:31 PM


To: android-developers@googlegroups.com
Subject: Re: [android-developers] MapView + LocationManager...



Dear Tommy,



 The function requestLocationUpdates is offering the utility to set the
interval time for gps to c...



On Wed, Aug 11, 2010 at 12:13 AM, Tommy  wrote:

Hi everyone,

I am currently w...

-- 

You received this message because you are subscribed to the Google
Groups "Android Developers" group...

-- 
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

RE: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Tommy
So if I were to set requestLocationUpdates(String provider, 6, 0,
LocationListener listener, Looper looper) it would be the same on the batter
as if I were to set a timer for every 1 minute or whatever to call up the
GPS again? I just don't want it in constant communication with the GPS
satellites. I want it to check every X minutes then Shut down. I assumed
that calling requestLocaitonUpdates keeps the connection open and active but
only fires off onLocationChanged event according to the parameters inside
the requestLocationUpdates. 

 

This is why I am confused as to why my onLocationChanged event only fires
the first time I call requestLocationUpdates. Thenin the onLocationChanged I
call RemoveUpdates. This removes the GPS icon in the notification bar. Then
in X minutes I want to repeat it all again, but at that time, the timer
fires but no GPS icon shows up and my events to fire in onLocationChanged.

 

Am I making enough sense in what I want to accomplish? 



 

From: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] On Behalf Of Costantinos Costa
Sent: Tuesday, August 10, 2010 5:31 PM
To: android-developers@googlegroups.com
Subject: Re: [android-developers] MapView + LocationManager Question

 

Dear Tommy,

 The function requestLocationUpdates is offering the utility to set the
interval time for gps to collect a location

requestLocationUpdates(String provider, long minTime, float minDistance,
LocationListener listener, Looper looper)
You can see more details at:
http://developer.android.com/reference/android/location/LocationManager.html

On Wed, Aug 11, 2010 at 12:13 AM, Tommy  wrote:

Hi everyone,

I am currently working with the MapView. When the MapView is loaded I
request a GPS fix, when I get the GPS fix I plot it on the MapView.
After that I set a timer for 1 minute. When the timer Ticks I tell it
to get my GPS location again and plot it but for some reason
locationManager.requestLocationUpdates(provider, 0, 0,
locationListener); doesn't do anything. The code gets hit but it
doesn't try to get my GPS location. I'm not getting any errors
reported back. The code for the timer is set in the onLocationChanged
event. Below is the code I have.


public void onLocationChanged(Location location){
   locationManager.removeUpdates(locationListener);
   p = new GeoPoint((int)(location.getLatitude() * 1E6),(int)
(location.getLongitude() * 1E6));
   MyOverlay myOverlay = new MyOverlay();
   mc.animateTo(p);
   mc.setCenter(p);
   mc.setZoom(17);
   overlays.clear();
   overlays.add(myOverlay);
   overlays.add(myLocationOverlay);
   myPoints.add(p);

   mapView.invalidate();

   //Set Next Timer for GPS Check. Default 5 Minutes
   checkGPS = new Timer();
   final Location myLoc = location;
   checkGPS.scheduleAtFixedRate(new TimerTask(){
   @Override
   public void run(){
 
locationManager.requestLocationUpdates(provider, 0, 0,
locationListener);
   //myLocationOverlay.onLocationChanged(myLoc);


   }
   },6,6);


Like I said, the first time around it does what it needs to. The
reason I am trying to do this is because I don't want the GPS running
constantly to track my position I just want it to check every X
minutes(currently 1 minute for testing) Is this something that I can't
do in a MapView? Does the GPS have to be on all the time in order to
work?

--
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
<mailto:android-developers%2bunsubscr...@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 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 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

Re: [android-developers] MapView + LocationManager Question

2010-08-10 Thread TreKing
>
> On Tue, Aug 10, 2010 at 4:13 PM, Tommy  wrote:
>
>> Is this something that I can't do in a MapView?
>>
>
Sorry - I misread this, I think. You can certainly get GPS updates for a
MapView (specifically a MapActivity). But it's not a function of the MapView
itself, is what I mean.

On Tue, Aug 10, 2010 at 4:27 PM, Tommy  wrote:

> Ok, but when I do RequestLocationUpdates with a 5 minute or 1 mile
> parameter the GPS signal stays on all the time(or at least the image stays
> up in the task bar, and it kills my battery). it only turns off when I call
> the RemoveUpdates


That should not be the case. You may want to post the code of how you're
doing it. I use this functionality to get GPS updates every 1 minute if the
user has moved a certain distance, and it works just dandy.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

Re: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Mark Murphy
On Tue, Aug 10, 2010 at 5:27 PM, Tommy  wrote:
> Ok, but when I do RequestLocationUpdates with a 5 minute or 1 mile parameter
> the GPS signal stays on all the time(or at least the image stays up in the
> task bar, and it kills my battery). it only turns off when I call the
> RemoveUpdates

Correct. That's what's supposed to happen.

Bear in mind that it may take over a minute just to get the initial
fix (if it ever gets one), and when you turn off the GPS radio, it has
to do all that again.

-- 
Mark Murphy (a Commons Guy)
http://commonsware.com | http://github.com/commonsguy
http://commonsware.com/blog | http://twitter.com/commonsguy

Android Training...At Your Office: http://commonsware.com/training

-- 
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


Re: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Costantinos Costa
Dear Tommy,

 The function requestLocationUpdates is offering the utility to set the
interval time for gps to collect a location

requestLocationUpdates(String provider, long minTime, float minDistance,
LocationListener listener, Looper looper)
You can see more details at:
http://developer.android.com/reference/android/location/LocationManager.html

On Wed, Aug 11, 2010 at 12:13 AM, Tommy  wrote:

> Hi everyone,
>
> I am currently working with the MapView. When the MapView is loaded I
> request a GPS fix, when I get the GPS fix I plot it on the MapView.
> After that I set a timer for 1 minute. When the timer Ticks I tell it
> to get my GPS location again and plot it but for some reason
> locationManager.requestLocationUpdates(provider, 0, 0,
> locationListener); doesn't do anything. The code gets hit but it
> doesn't try to get my GPS location. I'm not getting any errors
> reported back. The code for the timer is set in the onLocationChanged
> event. Below is the code I have.
>
>
> public void onLocationChanged(Location location){
>locationManager.removeUpdates(locationListener);
>p = new GeoPoint((int)(location.getLatitude() * 1E6),(int)
> (location.getLongitude() * 1E6));
>MyOverlay myOverlay = new MyOverlay();
>mc.animateTo(p);
>mc.setCenter(p);
>mc.setZoom(17);
>overlays.clear();
>overlays.add(myOverlay);
>overlays.add(myLocationOverlay);
>myPoints.add(p);
>
>mapView.invalidate();
>
>//Set Next Timer for GPS Check. Default 5 Minutes
>checkGPS = new Timer();
>final Location myLoc = location;
>checkGPS.scheduleAtFixedRate(new TimerTask(){
>@Override
>public void run(){
>
>  locationManager.requestLocationUpdates(provider, 0, 0,
> locationListener);
>
>  //myLocationOverlay.onLocationChanged(myLoc);
>
>
>}
>},6,6);
>
>
> Like I said, the first time around it does what it needs to. The
> reason I am trying to do this is because I don't want the GPS running
> constantly to track my position I just want it to check every X
> minutes(currently 1 minute for testing) Is this something that I can't
> do in a MapView? Does the GPS have to be on all the time in order to
> work?
>
> --
> 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 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

RE: [android-developers] MapView + LocationManager Question

2010-08-10 Thread Tommy
Ok, but when I do RequestLocationUpdates with a 5 minute or 1 mile parameter
the GPS signal stays on all the time(or at least the image stays up in the
task bar, and it kills my battery). it only turns off when I call the
RemoveUpdates

 

From: android-developers@googlegroups.com
[mailto:android-develop...@googlegroups.com] On Behalf Of TreKing
Sent: Tuesday, August 10, 2010 5:20 PM
To: android-developers@googlegroups.com
Subject: Re: [android-developers] MapView + LocationManager Question

 

On Tue, Aug 10, 2010 at 4:13 PM, Tommy  wrote:

Is this something that I can't do in a MapView?

 

No. MapView is to view a map. It has no concept of GPS in and of itself.

 

Does the GPS have to be on all the time in order to work?

 

No. That's precisely what the parameters to requesetLocationUpdates are for.
There's absolutely no need to schedule a Timer yourself.



-
TreKing <http://sites.google.com/site/rezmobileapps/treking>  - Chicago
transit tracking app for Android-powered devices

-- 
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 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

Re: [android-developers] MapView + LocationManager Question

2010-08-10 Thread TreKing
On Tue, Aug 10, 2010 at 4:13 PM, Tommy  wrote:

> Is this something that I can't do in a MapView?
>

No. MapView is to view a map. It has no concept of GPS in and of itself.


> Does the GPS have to be on all the time in order to work?
>

No. That's precisely what the parameters to requesetLocationUpdates are for.
There's absolutely no need to schedule a Timer yourself.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

[android-developers] MapView + LocationManager Question

2010-08-10 Thread Tommy
Hi everyone,

I am currently working with the MapView. When the MapView is loaded I
request a GPS fix, when I get the GPS fix I plot it on the MapView.
After that I set a timer for 1 minute. When the timer Ticks I tell it
to get my GPS location again and plot it but for some reason
locationManager.requestLocationUpdates(provider, 0, 0,
locationListener); doesn't do anything. The code gets hit but it
doesn't try to get my GPS location. I'm not getting any errors
reported back. The code for the timer is set in the onLocationChanged
event. Below is the code I have.


public void onLocationChanged(Location location){
locationManager.removeUpdates(locationListener);
p = new GeoPoint((int)(location.getLatitude() * 1E6),(int)
(location.getLongitude() * 1E6));
MyOverlay myOverlay = new MyOverlay();
mc.animateTo(p);
mc.setCenter(p);
mc.setZoom(17);
overlays.clear();
overlays.add(myOverlay);
overlays.add(myLocationOverlay);
myPoints.add(p);

mapView.invalidate();

//Set Next Timer for GPS Check. Default 5 Minutes
checkGPS = new Timer();
final Location myLoc = location;
checkGPS.scheduleAtFixedRate(new TimerTask(){
@Override
public void run(){

locationManager.requestLocationUpdates(provider, 0, 0,
locationListener);
//myLocationOverlay.onLocationChanged(myLoc);


}
},6,6);


Like I said, the first time around it does what it needs to. The
reason I am trying to do this is because I don't want the GPS running
constantly to track my position I just want it to check every X
minutes(currently 1 minute for testing) Is this something that I can't
do in a MapView? Does the GPS have to be on all the time in order to
work?

-- 
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


Re: [android-developers] Mapview in tabhost

2010-07-26 Thread TreKing
On Sat, Jul 24, 2010 at 11:37 AM, BEARbear  wrote:

> I recently want to put mapview in tabhost
>

Haven't used tabs, but I can tell you that you need a MapActivity for
MapView to work. So you will probably have to add a MapActivity to the tabs,
which I think supports multiple Activities.

-
TreKing  - Chicago
transit tracking app for Android-powered devices

-- 
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

[android-developers] Mapview in tabhost

2010-07-26 Thread BEARbear
Hello~
I recently want to put mapview in tabhost

but now is the question
i can't figure out how to do this right!

here's my source code:

TM.java
--
public class TM extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);

TabHost tabs = (TabHost) this.findViewById(R.id.my_tabhost);
tabs.setup();
TabSpec tspec1 = tabs.newTabSpec("First Tab");
 
tspec1.setIndicator("tab1",this.getResources().getDrawable(R.drawable.pencil));
tspec1.setContent(R.id.tab1content);
tabs.addTab(tspec1);
TabSpec tspec2 = tabs.newTabSpec("Second Tab");
 
tspec2.setIndicator("tab2",this.getResources().getDrawable(R.drawable.globalmap));
tspec2.setContent(R.layout.maptabview);
--->why i
can't put an xml in tab content?
tabs.addTab(tspec2);
TabSpec tspec3 = tabs.newTabSpec("Third Tab");
 
tspec3.setIndicator("Facebook",this.getResources().getDrawable(R.drawable.facebookicon));
tspec3.setContent(R.id.tab3content);
tabs.addTab(tspec3);
}
}
--

maptabview.xml
--
 
http://schemas.android.com/apk/res/
android"
android:id="@+id/maptablayout"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
 

--

please help me out !! Thank you for answering!!! :)
Hope you have a great day!

-- 
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


Re: [android-developers] MapView getLatitudeSpan

2010-06-29 Thread Brad Gies
It's saving about 2-3 seconds on loading the Mapview... and considering 
I only spent about 4 hours figuring out the formula and implementing 
it... YES.. it's WELL worth the effort.



On 29/06/2010 1:29 PM, TreKing wrote:
On Fri, Jun 25, 2010 at 1:49 PM, Brad Gies > wrote:


I want them as soon as possible to enhance the user experience.


How much time are you saving by not waiting for the mapview? Is it 
really worth the trouble you're going through?


-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking
--
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 


--
Sincerely,

Brad Gies
---
Bistro Bot - Bistro Blurb
http://www.bgies.com
http://www.bistroblurb.com
http://www.ihottonight.com
---

Never doubt that a small group of thoughtful, committed people can
change the world. Indeed. It is the only thing that ever has - Margaret Mead

--
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


Re: [android-developers] MapView getLatitudeSpan

2010-06-29 Thread TreKing
On Fri, Jun 25, 2010 at 1:49 PM, Brad Gies  wrote:

> I want them as soon as possible to enhance the user experience.
>

How much time are you saving by not waiting for the mapview? Is it really
worth the trouble you're going through?

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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

[android-developers] Mapview ConcurrentModification Exception

2010-06-28 Thread Necroline
Hello everyone,

As the title suggest i have (sometimes) a
concurrentmodificationexception while trying to create a route between
two locations ...
Here is my code (and in case you're wondering MyOverlay does not try
to access the other Overlays in the map)

private class fillRouteTask extends AsyncTask {

/**
 * create the url to call to get the route
 *
 * @param src
 * @param dest
 * @return
 */
private StringBuilder createUrl(GeoPoint src, GeoPoint dest) {
// connect to map web service
StringBuilder urlString = new StringBuilder();

urlString.append("http://maps.google.com/maps?f=d&hl=en";);
urlString.append("&saddr=");// from
urlString.append(Double
.toString((double) src.getLatitudeE6() 
/ 1.0E6));
urlString.append(",");
urlString.append(Double
.toString((double) src.getLongitudeE6() 
/ 1.0E6));
urlString.append("&daddr=");// to
urlString.append(Double
.toString((double) dest.getLatitudeE6() 
/ 1.0E6));
urlString.append(",");
urlString.append(Double
.toString((double) 
dest.getLongitudeE6() / 1.0E6));
urlString.append("&ie=UTF8&0&om=0&output=kml");
Log.d("xxx", "URL=" + urlString.toString());

return urlString;
}

/**
 * create the connection to google url
 *
 * @param src
 * @param dest
 * @return
 */
private String connectToUrl(GeoPoint src, GeoPoint dest) {

// get the kml (XML) doc. And parse it to get the
// coordinates(direction
// route).
Document doc = null;
HttpURLConnection urlConnection = null;
URL url = null;
try {
url = new URL(createUrl(src, dest).toString());
urlConnection = (HttpURLConnection) 
url.openConnection();
urlConnection.setRequestMethod("GET");
urlConnection.setDoOutput(true);
urlConnection.setDoInput(true);
urlConnection.connect();

DocumentBuilderFactory dbf = 
DocumentBuilderFactory
.newInstance();
DocumentBuilder db = dbf.newDocumentBuilder();
doc = db.parse(urlConnection.getInputStream());

if 
(doc.getElementsByTagName("GeometryCollection") != null
&& 
doc.getElementsByTagName("GeometryCollection")
.getLength() > 
0) {
return 
doc.getElementsByTagName("GeometryCollection").item(

0).getFirstChild().getFirstChild().getFirstChild()
.getNodeValue();
}

} catch (MalformedURLException e) {
Log.d("test", e.getLocalizedMessage());
} catch (IOException e) {
Log.d("test", e.getLocalizedMessage());
} catch (ParserConfigurationException e) {
Log.d("test", e.getLocalizedMessage());
} catch (SAXException e) {
Log.d("test", e.getLocalizedMessage());
}
return null;
}

protected Void doInBackground(Void... arg0) {
try {
// get the current overlays present in the map
List overs = 
Collections.synchronizedList(mapView
.getOverlays());
String path = connectToUrl(orig, dest);
if (path != null) {
Log.d("xxx", "path=" + path);
String[] pairs = path.split(" ");
String[] lngLat = pairs[0].split(",");

  

Re: [android-developers] MapView getLatitudeSpan

2010-06-25 Thread Brad Gies
That's true... I am trying to get them before the map is ready. I need 
them to call a webservice that downloads the info needed to display the 
points on the map when it is ready, and I want them as soon as possible 
to enhance the user experience. When the map is ready a function is 
called to plot them.





On 25/06/2010 11:27 AM, Frank Weiss wrote:

If it returns zero, then either it's a bug or a race condition (you're
calling getLatitudeSpan() before the map view is ready). I recommend
to verify those possibilities before applying a work around.

   


--
Sincerely,

Brad Gies
---
Bistro Bot - Bistro Blurb
http://www.bgies.com
http://www.bistroblurb.com
http://www.ihottonight.com
---

Never doubt that a small group of thoughtful, committed people can
change the world. Indeed. It is the only thing that ever has - Margaret Mead

--
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


Re: [android-developers] MapView getLatitudeSpan

2010-06-25 Thread Pedro Teixeira

PS:  Using this to get the display size

Display display = getWindowManager().getDefaultDisplay();
int width = display.getWidth();
int height = display.getHeight();

On Jun 25, 2010, at 7:27 PM, Frank Weiss wrote:


If it returns zero, then either it's a bug or a race condition (you're
calling getLatitudeSpan() before the map view is ready). I recommend
to verify those possibilities before applying a work around.

--
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


Pedro Teixeira

www.pedroteixeira.org

--
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

Re: [android-developers] MapView getLatitudeSpan

2010-06-25 Thread TreKing
On Fri, Jun 25, 2010 at 1:15 PM, Brad Gies  wrote:

> Has anyone figured out how to duplicate the getLatitudeSpan results when it
> returns zero?


When does it return 0?

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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

Re: [android-developers] MapView getLatitudeSpan

2010-06-25 Thread Frank Weiss
If it returns zero, then either it's a bug or a race condition (you're
calling getLatitudeSpan() before the map view is ready). I recommend
to verify those possibilities before applying a work around.

-- 
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


[android-developers] MapView getLatitudeSpan

2010-06-25 Thread Brad Gies


Has anyone figured out how to duplicate the getLatitudeSpan results when 
it returns zero?


My assumption is that I can figure out a formula to get the equivalent 
result to getLatitudeSpan (and longitude), by testing it for zero, and 
if it's zero, use a formula based on mapView.getMapCenter() and using 
the Zoom . It can't be that tough a formula, but I was wondering if 
anyone else has already done it, and are willing to share the info, or 
maybe knows an easier way?




--
Sincerely,

Brad Gies
---
Bistro Bot - Bistro Blurb
http://www.bgies.com
http://www.bistroblurb.com
http://www.ihottonight.com
---

Never doubt that a small group of thoughtful, committed people can
change the world. Indeed. It is the only thing that ever has - Margaret Mead

--
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


Re: [android-developers] MapView displays pages different than launching via ACTION_VIEW

2010-06-09 Thread paulb
Hello Anthony,

I am not quite sure if this is what you want, but try:

myWebView.getSettings().setUseWideViewPort(true);


On Sat, Jun 5, 2010 at 2:50 PM, Anthony Stevens  wrote:
> Help...!
>
> My web page displays properly if loaded into a WebView via an ACTION_VIEW
> Intent.  However I need more control so I need the page loaded into a
> WebView in my own Activity.
>
> Oddly, the WebView doesn't display the page in the same format.  I can't
> tell what's going wrong.  Any suggestions?  Hopefully you can see the images
> I posted.
>
> --
> 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 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


Re: [android-developers] MapView Overlay Location Way Off

2010-05-28 Thread TreKing
On Thu, May 27, 2010 at 12:36 PM, jtkendall  wrote:

> I'm not sure if I'm just calling something too early/late, or if
> I'm missing something completely.
>

Just took a cursory glance and your code looks fine - my guess is your data
is bad.
Double check the values - are you sure they are what you think they should
be?

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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

[android-developers] MapView Overlay Location Way Off

2010-05-27 Thread jtkendall
Hi,

I'm new to the Android platform (and Java) and I'm trying to get
MapView to show my overlays as well as my current (hardcoded for the
emulator) location. It shows the current location correctly; the
second location that it's supposed to show is just down the street
from the current location (a block or two away), but is rendered about
40 miles away (pic: http://twitpic.com/1rkk4u/full).

I would post my code here, but I know that discussion groups like this
don't generally show the code in a readable format, so I posted it at:
http://gist.github.com/416082.

I'm not sure if I'm just calling something too early/late, or if I'm
missing something completely. Any help would be appreciated.

Thanks,

Josh.

-- 
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


[android-developers] MapView crushes in satellite mode if android:anydensity is set true

2010-05-21 Thread Vincent
Hi,

On Android 1.6 WVGA device, a map view in satellite mode crushes when
the map zoom-in too much if I specify android:anyDensity="true" in the
manifest file.
But, if I set android:anyDensity="false", then the map does not crush.

I want my app to support a multiple densities and also do not want to
make the map crush.
Is there any way to do this?

I tried to control zoom level of the map, but getMaxZoomLevel() method
in satellite mode does not return a correct value.
Please help me out!!

Thanks

-- 
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


Re: [android-developers] MapView Marker and Parameter

2010-05-11 Thread TreKing
On Mon, May 10, 2010 at 11:39 PM, Ning  wrote:

> Is there API to draw the blue flashing circle at arbitrary location same as
> the one provided by MyLocationOverlay in Google Map API?
>

Yes, the Canvas object passed to your draw function.


> And is it possible to draw a parameter around the dot given a radius,
> like "my location" in Google Map?
>

I'm not sure what you mean by "parameter". If you mean a circle for the
"diameter", then yes, it is possible, again using the Canvas.

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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

[android-developers] MapView Marker and Parameter

2010-05-10 Thread Ning
Hi,

Is there API to draw the blue flashing circle at arbitrary location
same as the one provided by MyLocationOverlay in Google Map API? And
is it possible to draw a parameter around the dot given a radius, like
"my location" in Google Map?

Thanks.

-- 
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


Re: [android-developers] mapview on the top part of the screen ?

2010-05-08 Thread TreKing
On Thu, May 6, 2010 at 7:14 PM, jgan  wrote:

> Does anyone know how to put mapview on the top part of the screen?
>
> The map always occupies the whole screen and squeezes out the views
> below.
>

Try setting the height to 0 and weight to 1. Then it should occupy all the
space leftover from the other views.

-
TreKing - Chicago transit tracking app for Android-powered devices
http://sites.google.com/site/rezmobileapps/treking

-- 
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

[android-developers] mapview on the top part of the screen ?

2010-05-07 Thread jgan
Hi

Does anyone know how to put mapview on the top part of the screen?

The map always occupies the whole screen and squeezes out the views
below.

The explicitly specified height and width does not help either.

com.google.android.maps.MapView
android:id="@+id/myMapView"
 android:layout_width="480dip"
 android:layout_height="503dip"


It works if the other views are on the top part of the screen and the
mapview is at the bottom part.

Thanks.

Jim

-- 
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


[android-developers] MapView does not work in HTC Hero

2010-04-30 Thread Reiny Song
Hello,

I have a MapView (in MapActivity), and it works in my simulator.

The google map and the overlay I made are showed in simulator screen

After installing in HTC Hero,

the overlay is showed in phone screen, but google map is not showed in phone
screen.

I have no idea about the reason.

could anyone answer me?

thank you

-- 
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

[android-developers] MapView with rounded corners???

2010-04-13 Thread nalitzis
Hi everybody,

my question is really simpe: is it possible to define a MapView with
rounded corners? I know the way to create a(custom) view with rounded
corners: in its xml file I just set the background property of ist
enclosing layout to point to another xml file, where I define a
rounded rectangle shape:


android:background="@drawable/graph_bg_border"


this is graph_bg_border.xml:


http://schemas.android.com/apk/res/android";>





It works fine for layouts, but if I set the background of the MapView
to point to graph_bg_border, nothing happens.
What am I doing wrong?

-- 
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

To unsubscribe, reply using "remove me" as the subject.


[android-developers] MapView map elements size (e.g. street labels)

2010-03-27 Thread JP
Comparing a MapView as used in an app through Google Maps API against
the Google Maps app, I found that the granularity of all elements,
most visibly, street labels, in Google Maps is bigger than the street
labels in MapView. This is on a Nexus One, presumably other devices
show a similar behavior.
I did not find any hint in the documentation how to dial this for a
MapView. Anybody know where this can be dialed in?

-- 
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

To unsubscribe from this group, send email to 
android-developers+unsubscribegooglegroups.com or reply to this email with the 
words "REMOVE ME" as the subject.


  1   2   >