Re: [android-developers] Nexus 4 Drivers

2013-01-02 Thread Ken H
I'm using the latest version of Eclipse (actually they call it the Android 
Developer Tools, Build: v21.0.0-531062). When I plug it in I get 
nothing...at least in Eclipse. I can see it as a harddrive on the computer 
and surf the folders, but that's it.

Ken

On Wednesday, January 2, 2013 10:36:23 AM UTC-8, Mark Murphy (a Commons 
Guy) wrote:
>
> Usually the Nexus series only needs the standard ADB driver that's 
> available in the SDK Manager. 
>
>
> On Wed, Jan 2, 2013 at 1:32 PM, Ken H > 
> wrote: 
> > Has anyone seen where I can get drivers for the Nexus 4 so I can see it 
> in 
> > Eclipse? I'm having a peculiar problem in an app that only happens on 
> the 
> > Nexus 4, but Eclipse can't talk to it, so I can't see the Logcat. 
> > 
> > Ken 
> > 
> > -- 
> > You received this message because you are subscribed to the Google 
> > Groups "Android Developers" group. 
> > To post to this group, send email to 
> > android-d...@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] Nexus 4 Drivers

2013-01-02 Thread Ken H
Has anyone seen where I can get drivers for the Nexus 4 so I can see it in 
Eclipse? I'm having a peculiar problem in an app that only happens on the 
Nexus 4, but Eclipse can't talk to it, so I can't see the Logcat.

Ken

-- 
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] SlidingDrawer backgrounds

2012-07-30 Thread Ken H
This may be a stupid question (I just started getting into SlidingDrawers), 
but I have some buttons at the bottom of my drawer in a LinearLayout, and I 
want to set the background area around the buttons to a solid color -- the 
draw slides over a map and I can see the map behind the buttons...I don't 
want to see the map behind the buttons.

I know this should be simple, but simple things elude me.

Ken

-- 
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] Re: Cannot get TTS to work

2012-03-01 Thread Ken H
Fixed it.

FYI ~ I moved the whole TTS process from my activity to a class by
itself (other activities are going to be using it anyway), but then,
instead of using "this" for the first parameter of the TextToSpeech()
function, I used getApplicationContext(). I also initialized mTts
after initializing all my sensors and gps and stuff.

Ken

On Mar 1, 11:25 am, Ken H  wrote:
> I've tested the APIDemo TestToSpeech example code on my phone (Galaxy
> S2) and it works fine, but when I take the *same code* and paste it
> into my app the TTS fails. I see an error in the LogCat saying
> "intTts() failed to bind to service".
>
> I suspect the problem is in the line:
>
> mTts = new TextToSpeech(this, this);
>
> because this is the intitialization line, and the status I see
> returned in the onInit() is always -1. I'm initializing WiFi, gps, the
> phonestatelistener, among other things in this app. Is there a
> sequence I need to follow? Should I start TTS before/after something?
>
> What is the second arguement in the TestToSpeech() arguement really?
> The documentation says it's OnInitListener that gets call after
> initialization, but that just confuses me further (I'm using "this"
> for both parts). I'm completely stumped.
>
> Ken

-- 
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] Cannot get TTS to work

2012-03-01 Thread Ken H
I've tested the APIDemo TestToSpeech example code on my phone (Galaxy
S2) and it works fine, but when I take the *same code* and paste it
into my app the TTS fails. I see an error in the LogCat saying
"intTts() failed to bind to service".

I suspect the problem is in the line:

mTts = new TextToSpeech(this, this);

because this is the intitialization line, and the status I see
returned in the onInit() is always -1. I'm initializing WiFi, gps, the
phonestatelistener, among other things in this app. Is there a
sequence I need to follow? Should I start TTS before/after something?

What is the second arguement in the TestToSpeech() arguement really?
The documentation says it's OnInitListener that gets call after
initialization, but that just confuses me further (I'm using "this"
for both parts). I'm completely stumped.

Ken

-- 
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] Re: first time developer

2012-01-30 Thread Ken H
Read "Professional Android 2 Application Development" to understand
Android (if you know Java you have 70% of it already). Get your feet
wet with something simple. My first Android program was basically a
reference app. Nothing fancy, didn't use anything on the internet or
graphics or anything. But it got me use to working with activities and
such.

While Kristopher was a little dickish in his response (it's not off
topic) he is basically right. Again, get your feet, start simple,
build on your experience.

Ken

On Jan 28, 5:57 am, Raymond Evans 
wrote:
> Hey everyone I am an amateur developer and I am attempting a side
> scroller game. I know c++ and java but have never had to make anything
> from scratch with either only class assignments. Any advice for a
> first time developer starting out?

-- 
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] Re: How to calculate the distance between two degree values? (for example: 350º to 15º = 25º / 250º to 190º = 60º)

2011-09-29 Thread Ken H
I would like to reiterate what JackN said -- you don't have enough
info. But a good place to start would here: 
http://www.movable-type.co.uk/scripts/latlong.html

For those interested, a routine for the distance between two points
(on Earth) in kilometers is:

public double gps2m(double lat_a, double lng_a, double lat_b, double
lng_b) {
double R = 6371;//km
double dLat = (lat_b - lat_a) * (Math.PI / 180.0);
double dLon = (lng_b - lng_a) * (Math.PI / 180.0);
double a = Math.sin(dLat/2) * Math.sin(dLat/2) + Math.cos(lat_a *
(Math.PI / 180.0))
* Math.cos(lat_b * (Math.PI / 180.0)) * Math.sin(dLon/2) *
Math.sin(dLon/2);
double c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1-a));
return R * c;
}

where lat_a and lng_a are your start coordinates and lat_b and lng_b
are your stop coordinates.

Ken H

-- 
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] Re: CDMA getCellLocation() does not work

2011-07-08 Thread Ken H
Yeah, I've read the reference pages, it doesn't help...that's why I
asked.

The reference page doesn't explain why the LAT/LON is not known. The
Base Station ID is known, the Network ID is known. Almost everything
in the telephonymanager returns a valid result but this. Why? If you
Google this you will see that nobody actually gets a result from this
method. A simple note from the Android team explaining that they hope
to implement this sometime in the future would help, rather then let
us spin our wheels trying to fix something that doesn't work in the
first place.

And the other question is why is the result an integer? LAT/LON is not
an integer.

Oh well, I never expected a real answer, but I had to ask...thanks.

Ken

On Jul 8, 11:58 am, Raghav Sood  wrote:
> These features exist API level 5 onwards. You will receive Integer.MAX_VALUE
> if the location is not known.
>
> BTW it was the second result on Google when searching for "android
> getBaseStationLatitude()".

-- 
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] CDMA getCellLocation() does not work

2011-07-08 Thread Ken H
Does anyone know why getCellLocation() for cdma will not return the
cell site locations? If I use:

TelephonyManager tm = (TelephonyManager)
getSystemService(Context.TELEPHONY_SERVICE);
CdmaCellLocation cd = (CdmaCellLocation) tm.getCellLocation();
int cdmaLat = cd.getBaseStationLatitude();
int cdmaLon = cd.getBaseStationLongitude();

I get Integer.MAX_VALUE for both the cdmaLat & cdmaLon. Why? Has this
not been implemented yet in Android? If not, will it ever? Why is the
value an integer in the first place? LAT/LON should be a float or
double.

Ken

-- 
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] Re: MediaPlayer.isPlaying() question

2011-03-13 Thread Ken H
What I'm really asking is for a way to test if the MediaPlayer was
paused. I think my app is being paused by the OS for maybe a
notification or something. It drives me up the wall when it
just...stops.

On Mar 13, 11:25 am, Ken H  wrote:
> Will android.media.MediaPlayer.isPlaying() return true if the
> MediaPlayer is paused?
>
> Ken

-- 
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] Re: "Installation unsuccesfull" messages

2011-03-13 Thread Ken H
> Any suggestions on where to look?

A possible quick fix, tell your users to:

1. Go to Settings
2. Select "Applications"
3. Select "Manage Applications"
4. Select the "Market" app
5. Select "clear cache" & "clear data" & "uninstall updates"
6. Back out and select "Download Manager"
7. Select "clear data"

This might help, but like TreKing said, it's an ongoing issue.

Ken

-- 
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] MediaPlayer.isPlaying() question

2011-03-13 Thread Ken H
Will android.media.MediaPlayer.isPlaying() return true if the
MediaPlayer is paused?

Ken

-- 
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] Phantom Gingerbread update

2011-03-02 Thread Ken H
Last night I saw a notification for an OTA update for my Nexus One. I
checked and it was Gingerbread (2.3.3 yea!). So I click update and the
phone does it's thing (reboot and all), but when I check the version
number afterwards in About Phone I still see 2.2.2...anybody else get
a phantom update recently?

-- 
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] Marketplace download failure -- anybody else seen this?

2011-01-31 Thread Ken H
I've had a couple users say they can't download two of my apps. The
apps are 1.2 to 2.3Mb in size and the users seemed to imply that the
size was an issue since they could download smaller apps ok. One user
has a Cliq, not sure of the others. I told them to clear the cache and
data in the Market and Download manager apps, but the one that tried
that says no joy -- it didn't work.

Should they force close the Market app & Download Manager too? Is
there something else to try? I've uninstalled, downloaded and
installed both apps onto my Nexus One...everything's fine. Anybody
seen this before?

Ken

-- 
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] Re: Will no longer support Android 1.5

2011-01-17 Thread Ken H
> Holy crap - why is awesome information like this not clearly documented
> somewhere!? (Or is it ...?)
>

You crystalized my thoughts...although I usually find I just didn't
read the documnetation deeply :)

-- 
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] Turning off "save to SD Card"...problem?

2011-01-17 Thread Ken H
What will happen if I turn off the ability to move an app to the sd
card for an app that currently has that feature? Will it just move the
app to the phone...no problems?

I asked because I turned it on not realizing some things would break
or not work consistently. REALLY need the read the docs better :)

Ken

-- 
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] BOOT_COMPLETED not being heard

2011-01-15 Thread Ken H
Figured out the problem...a little pissed by it.

Apparently, if your app is designed to listen for the BOOT_COMPLETED
broadcast, and you allow it to be moved to the SD card, it will not
hear the BOOT_COMPLETED message. Annoying to say the least.

Just out of curiosity, after spending several hours trying to fix it,
does anybody know why this is?

Ken H

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

2011-01-11 Thread Ken H
It's been about a year since I've done anything with
the .BootStrapService. Has anything changed? My service no longer
seems to set its alarm after the phone restarts -- it use to.

I have my broadcast receiver set:


@Override
public void onReceive(Context context, Intent intent) {
BootStrapService.getLock(context).acquire();
context.startService(new Intent(context, 
BootStrapService.class));
}

and the service is defined in the manifest:



The build target is Google APIs 2.2 and the minSdkVersion=4.
BootStrapService class creates an alarm. Anything basic I've missed?

Ken

-- 
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] Reading the native Music Player

2010-12-06 Thread Ken H
Is it possible to read the database that the native music player uses
to store the users playlist definitions? If so how?

Ken

-- 
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] Re: What is Cursor??

2010-12-06 Thread Ken H
CURrent Set Of Records = CURSOR

This is more of a SQL term then a Java or Android thing. When you
query a database you get a list of records back (think Excel
spreadsheet). A CURSOR would be one row or record from that list. The
important thing about them is they let you walk through your query
result set.

Ken

-- 
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] Re: Market has the "All" option disabled :)

2010-11-30 Thread Ken H
On Nov 30, 1:51 pm, "Maps.Huge.Info (Maps API Guru)"
 wrote:
> If you use location services, you're minimum is pre-teen. That was
> explained in the e-mail I believe.

Actually it was in the detailed page link included in the
email...guess I should start reading that stuff.

Ken

-- 
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] Re: Can you detect a touch to the screen when the screen is off? (Wake up screen with a touch)

2010-11-30 Thread Ken H
> anyone out there got any ideas?

Use your other sensors like the accelerometer...shake it awake.

Ken

-- 
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] Re: Market has the "All" option disabled :)

2010-11-30 Thread Ken H
Yeah, what's up with that? It's enabled on some of my apps, but
disabled on others.

Ken

-- 
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] Can I turn the flash on?

2010-10-12 Thread Ken H
Is it possible to turn the flash on on an un-rooted phone (if so
equipped)? I've been looking around and can't find anything specific,
but I know it can be done...I found an app that does it.

Ken

-- 
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] Re: Android Market update bug?

2010-10-11 Thread Ken H
Thank You!

On Oct 11, 11:02 am, TreKing  wrote:
> On Mon, Oct 11, 2010 at 12:34 PM, Ken H  wrote:
> > Anyone seen this?
>
> http://market.android.com/support/bin/search.py?ctx=en%3Asearchbox&qu...
>
> --- 
> --
> 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


[android-developers] Android Market update bug?

2010-10-11 Thread Ken H
I have a Nexus One using 2.2.1 and was notified that four apps had
updates, so I opened Market and clicked "Update All", exited Market,
hit the power button to put the phone to sleep and put it away. The
next day I look in the Market and those apps still say "Installing..."
I can't cancel them and rebooting the phone did nothing. They just
show the progress bar with the hash marks scrolling by...

I can still use the apps though. I don't want to see what happens if I
uninstall mostly because I'd loose the data in the apps. The battery
doesn't seem effected, so right now it appears to be just an
uncomfortable curiousity.

Anyone seen this?

Ken

-- 
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] Re: Can android support more than one sdcard?

2010-09-10 Thread Ken H
No Android device can hold more than one sd card so why would there be
support for it?

Ken

-- 
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] Re: android doesn't recognize battery

2010-09-10 Thread Ken H
"which part of android source supposed to handle this behaviour?"

Handle what behavior? You're not doing anything a user would ever do.

Ken

-- 
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] Re: How do you handle a pound sign (#) in a string?

2010-07-23 Thread Ken H
Sweet and simple. That did the trick, thanks!

Ken

-- 
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] How do you handle a pound sign (#) in a string?

2010-07-23 Thread Ken H
I built a music player in my app and just discovered a little quark
while trying to play "#1 Crush" by Garbage. When I send the songs path
to the MediaPlayer, everything from the # sign on gets dropped off. I
tried inserting a "\" in front of it, but that causes everything
*after* the pound sign to get dropped. And I'm having trouble
inserting "\\" in there.

I know this is a simple fix, but, Friday afternoon, I can't think of
it.

Ken

-- 
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] Re: App Not Showing Up for Some Devices (1.5?)

2010-07-20 Thread Ken H
What version of Android are they using? Users with v1.5 won't see apps
with minSdkVersion="4" in the manifest, for example. That way they
don't download apps that will not work on their device.

Ken

-- 
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] from FRF50 to FRF91

2010-07-02 Thread Ken H
Anyone know where (or if) I can manually update from FRF50 to FRF91?
I've got files for going from FRF50 to FRF83, and from FRF85B to
FRF91, but nothing in between.

Ken

-- 
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] Re: Accuracy of location.getAccuracy() GSM and GPS - exact Meaning?

2010-07-02 Thread Ken H
> But what does that mean exactly?

You already answered your question -- it's the accuracy of the fix in
meters. If it returns "4" your position is accurate to +/- 4m. If
you've ever used the Google map and seen the blue circle around your
position (which should quickly shrink to your flashing dot position),
then you are seeing your GPS accuracy graphically. As the phone's GPS
refines its calculation and acquires more satellites the accuracy will
increase.

Ken

-- 
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] Replicating fastscroll like in contacts

2010-07-02 Thread Ken H
I'm looking for a tutorial on implementing the fastscroll feature
found in the contacts view. I'm using a ListActivity with a custom
array adapter to display my list (I use subtext under the main text
info).

I've seen the List9.java class in the samples directory, but it's not
the easiest example for me to follow -- I'm not ashamed to admit the
concept of the subclassed array adapter baffles me, even though it
works quite nicely. All my attempts to use this have ended with a FC
and an unceremonious boot to the desktop.

Is there one good example out there that explains things? Failing
that, maybe different examples? I'm listing songs on the sd card...you
know, the usual.

Ken

-- 
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] Re: Are there default permissions added to apps?

2010-06-30 Thread Ken H
Ahhh, makes sense. I did search, but if you don't stumble on the right
word combo you'll just spin your wheels. Thanks.

On Jun 30, 9:20 am, TreKing  wrote:
> On Wed, Jun 30, 2010 at 11:17 AM, Ken H  wrote:
> > What's going on?
>
> For backward compatibility, some permissions that didn't previously exists
> (like th SD card one) are automatically granted if you target an older API
> (1.5).
>
> This has been discussed at length in this forum. Just search for it.
>
> --- 
> --
> TreKing - Chicago transit tracking app for Android-powered 
> deviceshttp://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] Are there default permissions added to apps?

2010-06-30 Thread Ken H
I wrote an app in which the only permission I give in the manifest is
internet access,



but when I check the list of permissions in the Application Info it
says:

Storage
modify/delete SD card contents

Network communications
full internet access

Phone calls
read phone state and identity

My app is a simple reference doc that has a few outside web links
embedded in it. It does nothing to the sd card, let alone the phone.
What's going on?

Ken

-- 
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] Re: Eclipse shows error, but no error found

2010-05-21 Thread Ken H
Yes, exactly! I've had this happen before but was able to get rid of
it by toggling the build project (for some reason that worked). This
time it wouldn't go away.

I did just upgrade to the SDK for 2.2 though. Maybe that had something
to do with it. I don't know.

> do some or all of these long enough and it eventually comes back. there
> is *absolutely*
> no consistency to what actually causes it to start working, or I'd have
> filed
> a bug.
>
> MIke

-- 
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] Re: Eclipse shows error, but no error found

2010-05-21 Thread Ken H
Ok, I opened a Window > Show views > Problems, and it said something
about an "Unparsed aapt error(s)!..." whatever the devil that is.

So I deleted it...and got the emulator up and running. What did I
actually do? Not worried, just curious? Thanks, by the way...

Ken

On May 21, 4:02 pm, Xavier Ducrohet  wrote:
> Look at the Problems view, it may be a project config issue.
>
> xav

-- 
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] Eclipse shows error, but no error found

2010-05-21 Thread Ken H
Eclipse is showing an error (little red "x" next to my project name),
but there is no error shown in any files -- meaning there is no
corresponding "x" next to any file...nothing. When I try to run it, it
says, "Your project contains error(s), please fix them before running
your application."

What's going on?? This is driving me crazy.

Ken

-- 
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] Re: Cannot see device in DDMS

2010-04-15 Thread Ken H
FYI ~

I guess they just issued a new update to the ADT Plugin in March. I
updated (Help -> Software Updates, check developer tools), restarted
Eclipse and now I see my phone in the Devices tab.

All is right with the world :)

Ken

On Apr 15, 12:33 am, schwiz  wrote:
> make sure you have the latest driver installed and for the correct os
> (32 vs 64 bit) I have had this problem with some but not all devices
> at once.  I can't think of what else it could be but drivers though.
>
> On Apr 15, 12:42 am, Ken H  wrote:
>
>
>
> > I have Windows XP and use Eclipse v3.4.1.
>
> > Under Device Manager I see Android Phone -> Android Composite ADB
> > Interface when my Nexus One is plugged into the computer (Disk drives -> 
> > HTC Android Phone USB Device when my myTouch is plugged in), so I
>
> > believe my  USB drivers are there.
>
> > On my phone under Settings -> Applications -> Development, USB
> > debugging is checked.
>
> > When I connect the phone I see "USB debugging connected" in the
> > notification window.
>
> > When I select the DDMS perspective I see nothing. When I type "adb
> > devices" in a command window I get back nothing in the list of
> > attached devices.
>
> > I can run the emulator just fine, but I cannot see any physical
> > devices (Nexus One or myTouch). What am I doing wrong?
>
> > Ken

-- 
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] Cannot see device in DDMS

2010-04-14 Thread Ken H
I have Windows XP and use Eclipse v3.4.1.

Under Device Manager I see Android Phone -> Android Composite ADB
Interface when my Nexus One is plugged into the computer (Disk drives -
> HTC Android Phone USB Device when my myTouch is plugged in), so I
believe my  USB drivers are there.

On my phone under Settings -> Applications -> Development, USB
debugging is checked.

When I connect the phone I see "USB debugging connected" in the
notification window.

When I select the DDMS perspective I see nothing. When I type "adb
devices" in a command window I get back nothing in the list of
attached devices.

I can run the emulator just fine, but I cannot see any physical
devices (Nexus One or myTouch). What am I doing wrong?

Ken

-- 
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] Re: Activating Bluetooth

2010-04-05 Thread Ken H
Thank you! I was starting to think I only seem to ask questions no one
knows the answer to. :)

Ken

-- 
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] Activating Bluetooth

2010-04-03 Thread Ken H
Is there a simple way to activate/deactivate bluetooth without having
some dialog popup requesting the user's permission every time?

I have an app that plays music (it's actually part of a scheduled
alarm). I want to play music through some bluetooth speakers I have
already paired the phone with, but I don't want bluetooth to run while
I am not using that app or after the app has shut down -- I want to
reduce any unnecessary load on the battery.

Ken

-- 
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] Re: how to implement musicplayer as service in android

2010-04-02 Thread Ken H
This might get you started...

http://marakana.com/forums/android/android_examples/60.html

Ken

-- 
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] Re: onSignalStrengthsChanged bug?

2010-04-02 Thread Ken H
Just holding out hope someone has had this problem too...

Ken

-- 
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] Re: Android 1.5 on CDMA phones and OEM non-conformance documentation...

2010-04-02 Thread Ken H
> Just reporting that I was successful in building my application
> against the Android 2.1 SDK and running it without issue on several
> Android 1.5 CDMA phones.
>

Just curious, how are you doing that? You can't check CDMA features on
a phone who's OS doesn't have a CDMA package...or maybe you are,
that's what I'd like to know.

Ken

-- 
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] Re: Fastest and most reliable Location provider

2010-04-02 Thread Ken H
This is great information. Now one last stupid question (again, if
they put this in the docs I wouldn't ask it). Does
ACCESS_COARSE_LOCATION = Network and ACCESS_FINE_LOCATION = GPS?

Ken

-- 
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] Re: GsmCellLocation.getCid() returns very large numbers.

2010-04-01 Thread Ken H
That's a hex number. I just do this:

GsmCellLocation cl = (GsmCellLocation)
myTelephonyManager.getCellLocation();
int CELLID = cl.getCid();
int ci = CELLID & 0x;

and ci contains a "normal" 4-5 digit cell id. The GsmCellLocation is
from Eclair, but I originally wrote this for Donut...works fine.

Ken

-- 
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] Re: Installing apps to Nexus One device

2010-04-01 Thread Ken H
Also you can lookup "Apps Installer" on the Android Market. No
hassels.

On Mar 31, 5:08 am, oriharel  wrote:
> IT WORKS
> Thanks (again) Mark!
>
> On Mar 31, 2:47 pm, Mark Murphy  wrote:
>
>
>
> > oriharel wrote:
> > > it was turned on (even before the first time I installed the driver)
> > > still doesn't work
>
> > adb kill-server
> > adb start-server
> > adb devices
>
> > See if that helps. If not, reboot and see if that helps.
>
> > If not, plug in your N1 and see if you see any evidence that Windows is
> > actually recognizing it and associating the driver to it.
>
> > --
> > Mark Murphy (a Commons 
> > Guy)http://commonsware.com|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

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


[android-developers] Re: Playlist Content Provider

2010-04-01 Thread Ken H
Here are a couple links that solved this mystery for me:

http://www.anddev.org/viewtopic.php?p=12404

http://androidsamples.blogspot.com/2009/06/displaying-list-of-music-files-stored.html

Ken

On Mar 31, 9:58 am, Fossum  wrote:
> I'm making a media player, but my code doesn't show all my playlists
> and for many others it does not show any...
> Why doesn't the code below work completely?
>
> cursor = getContentResolver().query(
>
> android.provider.MediaStore.Audio.Playlists.EXTERNAL_CONTENT_URI,
>         null, null, null, null);

-- 
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] Re: Fastest and most reliable Location provider

2010-04-01 Thread Ken H
That's not a bad idea actually. I was going to ask what happens when
the "loser" gets a solution but answered myself while typing :)

Not to get off topic, but would you know what the difference is
between POWER_LOW, POWER_MEDIUM, and POWER_HIGH...besides the obvious?

Ken

On Apr 1, 12:40 pm, "Maps.Huge.Info (Maps API Guru)"
 wrote:
> The method I use, which seems fairly effective, is to start two
> listeners, one for coarse and one for fine and let them both try and
> get a position. The first one to get it, "wins." One of my apps
> continues to report location updates to move a location pin on a map,
> as far as I can tell, it is just as fast as the Google map.
>
> -John Coryat
>
> "Radar Now!"

-- 
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] Re: Writing Current Time

2010-04-01 Thread Ken H
Just pulling stuff outta my code...

/* create a date format object that you like */
SimpleDateFormat tsFormat = new SimpleDateFormat("d MMM 
HH:mm:ss");

/* get the time */
Calendar timeStamp = Calendar.getInstance();

/* convert that time to a string */
String ts = tsFormat.format(timeStamp.getTime());

That's it. Using this method you would end up with a string that looks
like this:

"1 Apr 2010 07:41:10"

Remember, most of this junk is just Java. There are gobs of
'cookbooks' out on the web for this sort of thing.

Ken H

-- 
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] onSignalStrengthsChanged bug?

2010-04-01 Thread Ken H
I have an app for measuring a lot of phone stats including signal
strength, and it works fine. I'm using the new
onSignalStrengthsChanged method in Eclair (the old
onSignalStrengthChanged was depracated in v2.0.1) and I've updated my
app to include a service to continue recording that rssi value after
you've exited the app (mostly to save the battery, but also for
monitoring the phone state while making calls, etc.)

Anyway, I've tested the service out on my way to work and notice that
if I let the phone go to sleep (hit the power button and the screen
goes off) the signal strength value does not change -- it continues to
hold the value it had when the phone went to sleep. I know the
PhoneStateListener is working because I'm seeing updates for the
cellID which comes from the onCellLocationChanged method in the
PhoneStateListener.

This services works as expected if I keep the phone awake by using
Google Maps or just tapping the screen periodically while at the
desktop -- in other words not letting the phone fall asleep. When I do
that the data collected shows the cellID being updated *and* the
signal strength changing as I drive.

I know not a lot of people do this sort of thing (RF stuff), but has
anybody else seen this? Is this a bug?

Ken

-- 
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] Re: Get unique ID of phone - Settings.Secure.ANDROID_ID not working on N1?

2010-03-26 Thread Ken H
Can't say anything about the ANDROID_ID thing. What's wrong with the
TelephonyManager? You can get the device ID, subscriber ID, Sim serial
number, etc. I think the only permission you need is



in the manifest.

Ken

On Mar 25, 6:28 am, Anna PS  wrote:
> Odd - I posted this message yesterday and got sent a copy, but it
> doesn't seem to have shown up in the group... Here it is again.
>
> 
>
> This seems to be a bit of a vexed issue: 
> seehttp://groups.google.com/group/android-developers/browse_thread/threa...
>
> Like the person who started that thread, I need to get a unique ID for
> a device, without using scary permissions for TelephonyManager. I've
> tried
>
>    id =
> android.provider.Settings.Secure.getString(getContentResolver(),
> android.provider.Settings.Secure.ANDROID_ID);
>
> but that just produces "android_id" on my phone. Anyone know a way
> that works? I'm using a Nexus One and Android 2.1.

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


[android-developers] Re: Nexus one

2010-03-26 Thread Ken H
The greatest phone ever.

On Mar 26, 11:20 am, ernie  wrote:
> Just got the Nexus One via FedEx, in Southern California. Thank you
> Google.

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


[android-developers] Re: Get current track from music player?

2010-03-26 Thread Ken H
I believe that music player is actually a separate application. Just
because it came with the phone doesn't mean it's part of the API (or
ever will be). Banged my head against a wall for 2-weeks before I
figured that one out.

Ken


On Mar 26, 9:50 am, Jesper Majland  wrote:
> Hi
>
> I'm working on a application that, while it's running, should be able
> collect and save information about the music played by the Phones
> MediaPlayer.
>
> There are not any public API for this at the moment, do you have any
> plans for this in the future?
>
> It would be nice if my application just could use the default Music
> player, instead of implement a new player.
>
> So far the only solution I can find is this this link 
> here:http://www.alexc.me/android-music-app-service-currently-playing-song/...
>
> ,but this is not a nice way to do it.
> It will only work with phones that use exactly same version of the
> interface file IMediaPlaybackService.aidl
>
> Does you Android experts, have any good solutions?
>
> -Jesper

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


[android-developers] Re: How to indicate to user that a row is long-clickable?

2010-03-26 Thread Ken H
I just put a short Toast up when the activity launches, but I like
Marks idea...basically give the user two or more paths to do the same
thing. One when 'power users' would figure out on their own to do
this, and another that basically takes the user by the hand.

Ken

> IMHO, long-click should be a "power user" thing. Make sure anything that
> can be done by that mechanism can be done by some other means that is
> more discoverable.
>
> For example, in the Contacts app, you can long-tap to delete a contact,
> but you can also tap on the contact, bring up the contact details
> activity, and do a delete from the option menu. The option menu is a bit
> more discoverable because there's a button for it.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> _Beginning Android_ from Apress Now 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

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.


[android-developers] Android Market updating in error

2010-03-11 Thread Ken H
Has anyone had users complain that their app is being updated too
much? I issued an update to one of my apps January 17th, and saw a
comment from a user a couple days ago complaining that he gets update
notifications every week. I had this complaint a couple months back
but just ignored it.

Just wondering if it's the Market (which never gets the number of
updates correct by the way), or the phone.

Ken

-- 
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] Re: Persisting alarms

2010-02-23 Thread Ken H
Figured it out. Just needed to create a service dedicated to setting
the users defined alarm time, which I save in a preference. After
reboot the service is called, pulls the preference, creates the alarm,
and stop itself. Simple.

Ken

On Feb 23, 8:44 am, Ken H  wrote:
> But how can you then set the alarm to fire at a specific time? Every
> example I've come across has the alarm fire a certain amount of time
> after reboot. I want to set a specific time used in my app and the
> onReceive method seems pretty limited in what it will let you do.
>
> Ken
>
> On Feb 2, 1:26 pm, Mike Novak  wrote:
>
>
>
> > register to receive the BOOT_COMPLETED broadcast.
>
> > and register with theAlarmManagerthen.
>
> > Mike
>
> > On Feb 2, 2010, at 4:17 PM, Chris wrote:
>
> > > Hello everyone
>
> > > TheAlarmManagerAPI states that alarms created with this API are
> > > removed when the phone is turned off and rebooted.
>
> > > Is there a way to persist the alarms?
>
> > > If I knew how to start a process immediately on bootup, I could
> > > recreate the alarms, but I haven't had much luck finding this
> > > information.
>
> > > If anyone knows how to persist an alarm after bootup or at least auto-
> > > execute an activity or intent after bootup, I would greatly appreciate
> > > it.
>
> > > Thanks
> > > Chris
>
> > > --
> > > 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] Re: Persisting alarms

2010-02-23 Thread Ken H
But how can you then set the alarm to fire at a specific time? Every
example I've come across has the alarm fire a certain amount of time
after reboot. I want to set a specific time used in my app and the
onReceive method seems pretty limited in what it will let you do.

Ken

On Feb 2, 1:26 pm, Mike Novak  wrote:
> register to receive the BOOT_COMPLETED broadcast.
>
> and register with theAlarmManagerthen.
>
> Mike
>
> On Feb 2, 2010, at 4:17 PM, Chris wrote:
>
>
>
> > Hello everyone
>
> > TheAlarmManagerAPI states that alarms created with this API are
> > removed when the phone is turned off and rebooted.
>
> > Is there a way to persist the alarms?
>
> > If I knew how to start a process immediately on bootup, I could
> > recreate the alarms, but I haven't had much luck finding this
> > information.
>
> > If anyone knows how to persist an alarm after bootup or at least auto-
> > execute an activity or intent after bootup, I would greatly appreciate
> > it.
>
> > Thanks
> > Chris
>
> > --
> > 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] Re: Petition: Google, please improve the Android Market.

2010-02-23 Thread Ken H
1. A real website

God, yes. Why is there not one?? There's Cyrket and AndroLib, but
Google should have done this first.

3. A way for developers to reply to comments

This is very frustrating to me too, but I think this is a stupid/lazy
user issue, not Google's fault. It's just as easy to email the
developer as to leave a silly, easily explained comment, but they
don't. Maybe if they put the "email developer" item under the
"comments" item?

4. App description..."Also can we please at least have clickable links
on the app description? Expecting a user to re-type a URL on a mobile
device is absurd."

The "Visit the developers web page" is clickable. I think if your
asking for clickable links "inside" your description then that may be
asking too much. I mean if you want to say more then do it on the
webpage.

5. Multiple versions of an app

Think this would be a big mistake. You may be thinking too much like a
developer and not like a common user :)
I think users would be completely confused by multiple versions of the
same app. Remember, Apple is successful because they simplify things.

6. Statistics "...what does "active" exactly mean anyway?"

An "active" install is an app that on a phone. 76% active installs
means 76% of the people who downloaded your app still have it on there
phone, 24% uninstalled it.

"Also, when a user uninstalls an app, they're asked why they did it.
Really, we'd like to know too!"

Yes, absolutely.

7. Other features?..."a way for users to easily send log files and
screenshots, to report a problem with an app"

It's called email. I'm not trying to be funny but any user that could
send that sort of thing is going to know to send it in an email.
Common users would never think or bother doing that so why make it
"easy".



But overall I think this is good idea. I think Google is a little too
slow in it's fixes/improvements.

Ken

On Feb 23, 9:18 am, Disconnect  wrote:
> What carrier does that go to on nexus and such? Those devices don't have
> assigned carriers, and the software load is created by google. (That 30% was
> explained as incentive/payment for shipping the market, passing
> compatibility tests, etc.)
>
> On Tue, Feb 23, 2010 at 11:36 AM, Streets Of Boston 
>
>
> > wrote:
> > Well,
>
> > This is what Google told us at the Android Developers Lab. The bulk of
> > the 30% goes to the carriers, a fraction of this 30% goes to google to
> > run Google Checkout and the payment processor.
>
> > I guess the bulk of the 30% that goes to the carrier is an incentive
> > to have Android Market (and not other markets?) installed.
>
> > On Feb 23, 10:49 am, Disconnect  wrote:
> > > Google has been very vague about where that 30% goes when you're on a
> > nexus,
> > > adp, etc.
>
> > > On Tue, Feb 23, 2010 at 10:37 AM, Hekki  wrote:
> > > > Hi,
>
> > > > Are you sure about the carrier thing ?
>
> > > > I don't see when they are involved :
>
> > > > Clients only use the carrier as a dumb pipe here to get internet
> > > > access, they pay using google checkout which have their credit card
> > > > information(much like itunes does).
> > > > So google handle the payment itself.
>
> > > > When is the carrier involved at all ? I don't understand.
>
> > > > Yahel
>
> > > > On 23 fév, 15:58, Streets Of Boston  wrote:
> > > > > Yep, you're correct.
> > > > > Google gets only a small portion of the 30% to cover the costs of the
> > > > > payment transactions. The bulk of the 30% goes to the carriers. At an
> > > > > Android Dev Lab Google told us Google's share just covers their cost.
>
> > > > > On Feb 22, 9:16 pm, "Maps.Huge.Info (Maps API Guru)"
>
> > > > >  wrote:
> > > > > > You might want to drop the "let's not forget" clause as it's
> > something
> > > > > > that wouldn't help any petition and could keep people from agreeing
> > > > > > with you.
>
> > > > > > Google doesn't get 30% of your app sales, the carrier's cut, taxes,
> > > > > > fees for the merchant account and other costs eat that up to
> > probably
> > > > > > zero profit or near to it.
>
> > > > > > -John Coryat
>
> > > > > > On Feb 22, 7:56 pm, Matthew LeMieux  wrote:
>
> > > > > > > Has anybody else noticed that it is very difficult for many users
> > to
> > > > go
> > > > > > > through the flow to even be able to purchase an app?  I would
> > like to
> > > > see
> > > > > > > getting a paid app be as easy as getting a free app.  Perhaps
> > giving
> > > > users
> > > > > > > the opportunity to register and add apps to their phone on a
> > desktop
> > > > rather
> > > > > > > than only on the phone (similar to the experience iPhone users
> > have).
>
> > > > > > > When I originally went through the flow on my G1, I found that
> > the
> > > > > > > registration data was in a small dialog where I couldn't really
> > see
> > > > what was
> > > > > > > being entered while I was entering it.  I was a highly motivated
> > user
> > > > and
> > > > > > > hence completed the whole process, but what about a casual user?
>
> > > > > >

[android-developers] Re: Android Market Changed ranking

2010-02-19 Thread Ken H
My stuff hasn't changed. Have you checked your Downloads/Active
Installs? Maybe your app is the new hot thing :)

Ken

On Feb 19, 1:44 am, Mr Pants  wrote:
> Hi
>
> Erm did something happen to the ranking system today? My app seems to
> have shot up a bunch of places in it's category. Obviously I'm not
> complaining - just curious:)
>
> Anyone else noticed anything?
>
> Thanks
>
> Ps - I'm in UK (not sure if this makes a difference)

-- 
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] Re: Unable to get map overly to show

2010-02-19 Thread Ken H
Are you sure the overlay isn't just being drawn someplace else? Have
you tried zooming out? I like to center my new overlay item with
something like

mapView.getController().setCenter(p);

The only thing I don't understand is the Location class (just never
used it...). That's the only thing I saw you did different from my
mapping activity.

Ken

On Feb 19, 10:55 am, "AndroidRef.com"  wrote:
> Obviously the URL is "http://www.androidref.com";.  Sorry for the typo.
>
> Jay
>
> On Feb 19, 12:54 pm, "AndroidRef.com"  wrote:
>
>
>
> > Andrew,
>
> > Take a look at "Using the Google Maps API tomapa location and add a
> > marker to themap." at "http://www.anroidref.com/";.
>
> > From a quick glance, our code seem similar, though you're obviously
> > drawing on themapand I'm dropping an image.  If you still can't get
> > it to work after reviewing my code snippets, I'll take a closer look.
>
> > Jay
>
> > On Feb 9, 10:44 am, andrew android  wrote:
>
> > > Bump)
>
> > > On Feb 6, 7:16 am, andrew android  wrote:
>
> > > > Can anyone help?  Thanks!
>
> > > > On Feb 2, 7:42 pm,andrewandroid wrote:
>
> > > > > 
> > > > >  > > > >   xmlns:android="http://schemas.android.com/apk/res/android";
> > > > >  android:layout_width="wrap_content"
> > > > >  android:layout_height="wrap_content">
> > > > >   
> > > > >  > > > >  dth="fill_parent"
> > > > >  android:layout_height="fill_parent"android:enabled="true"android:clickable=
> > > > >  "true"android:apiKey="0lrZO7CweoTib-Xc4lzUlx2BLruXNt6rHvl0-TA"
> > > > > />
> > > > > 
>
> > > > > On Feb 2, 2:57 am, Kevin Duffey  wrote:
>
> > > > > > Oddly enough, I copied/pasted your code and I am getting a class 
> > > > > > not found
> > > > > > issue.. for some reason I can't get the Launcher to start. Can you 
> > > > > > paste
> > > > > > your layout xml and string resources as well?
>
> > > > > > On Mon, Feb 1, 2010 at 8:32 
> > > > > > PM,andrewandroidwrote:
>
> > > > > > > Any example of what I may be missing?  Thanks!
>
> > > > > > > On Jan 31, 12:10 pm, Kevin Duffey  wrote:
> > > > > > > > Hmm.. I don't know.. I did not set the overlay position.. I 
> > > > > > > > just added it
> > > > > > > to
> > > > > > > > my mapView and mine shows up. Try working with your location 
> > > > > > > > settings. I
> > > > > > > am
> > > > > > > > not sure why the Location is needed tho. I use an 
> > > > > > > > ItemizedOverlay for a
> > > > > > > list
> > > > > > > > of items I pull down from a server, which works fine. Mymapthen
> > > > > > > responds
> > > > > > > > to a click on an item, and puts another overlay above it with 
> > > > > > > > text.
>
> > > > > > > > On Sun, Jan 31, 2010 at 9:44 
> > > > > > > > AM,andrewandroid > > > > > > >wrote:
>
> > > > > > > > > Mymapoverlay is not showing up after several attempts
>
> > > > > > > > > Here is my Overlay class code:
>
> > > > > > > > > public class myOverlay extends Overlay{
>
> > > > > > > > >        private final int mRadius = 6;
> > > > > > > > >                       �...@override
> > > > > > > > >                public void draw(Canvas canvas, MapView 
> > > > > > > > > mapView, boolean
> > > > > > > > > shadow) {
> > > > > > > > >                                super.draw(canvas, mapView, 
> > > > > > > > > shadow);
> > > > > > > > >                                Projection projection =
> > > > > > > > > mapView.getProjection();
> > > > > > > > >        //      if (shadow == false) {
> > > > > > > > >                        Double latitude = 
> > > > > > > > > location.getLatitude()*1E6;
> > > > > > > > >                        Double longitude = 
> > > > > > > > > location.getLongitude()*1E6;
> > > > > > > > >                        GeoPoint geoPoint;
> > > > > > > > >                        geoPoint = new
> > > > > > > > > GeoPoint(latitude.intValue(),longitude.intValue
> > > > > > > > > ());
> > > > > > > > >                        Point point = new Point();
> > > > > > > > >                        projection.toPixels(geoPoint, point);
> > > > > > > > >                        RectF oval = new RectF(point.x - 
> > > > > > > > > mRadius,
> > > > > > > point.y -
> > > > > > > > > mRadius,
> > > > > > > > > point.x + mRadius, point.y + mRadius);
> > > > > > > > >                        // Setup the paint
> > > > > > > > >                        Paint paint = new Paint();
> > > > > > > > >                        paint.setARGB(250, 255, 0, 0);
> > > > > > > > >                        paint.setAntiAlias(true);
> > > > > > > > >                        paint.setFakeBoldText(true);
> > > > > > > > >                        Paint backPaint = new Paint();
> > > > > > > > >                        backPaint.setARGB(175, 50, 50, 50);
> > > > > > > > >                        backPaint.setAntiAlias(true);
> > > > > > > > >                        RectF backRect = new RectF(point.x + 2 
> > > > > > > > > +
> > > > > > > mRadius,
> > > > > > > > > point.y -
> > > > > > > > > 3*mRadius,      point.x + 65, point.y + mRadius);
> > > > > > > > >     

[android-developers] Re: MediaPlayer song array

2010-02-19 Thread Ken H
I put all the songs I want to play into a hasharray. When one song
finishes it calls setOnCompletionListener by setting up,

mMediaPlayer.setOnCompletionListener(new OnCompletionListener(){
public void onCompletion(MediaPlayer mp) {
selectNextSong();
}
});

after mMediaPlayer.start(). My 'selectNextSong' method just picks a
random song from the hasharray and plays it.

That said, I would love see what you or anybody else does. Always like
to see if my wheel is rounder than yours :)

Ken

On Feb 19, 1:27 pm, MarcC  wrote:
> I figured this out no need for an array. If anyone wants to know
> the solution reply to the thread then I'll post it.
>
> On Feb 9, 3:37 pm, MarcC  wrote:
>
>
>
> > Trying to get one mediaplayer button to cycle through a few mp3 files.
>
> > Here is what I have so far:
>
> > First declared my array:
>
> > final int[] songs = {R.raw.ef101a, R.raw.ef101b, R.raw.ef101c,
> > R.raw.ef101d, R.raw.ef101e};
>
> > Then called MediaPlayer:
>
> > public void onClick(View arg0) {
> >                  MediaPlayer mp = MediaPlayer.create(efaustusa.this,
> > songs);
> >                  mp.start();
>
> > I cannot call the array through this mediaplayer call anyone know
> > how to do this?

-- 
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] Re: What is stopSelf() doing?

2010-02-19 Thread Ken H
Cool, then I'm doing it right. Thanks.

Ken

On Feb 19, 2:00 pm, Mark Murphy  wrote:
> Ken H wrote:
> > If I call stopSelf() in a service, does it call onDestroy?
>
> It triggers onDestroy().
>
> > I want to
> > clean up after myself, but I'm a little vague on this process and the
> > docs don't help much.
>
> stopSelf() would be used in the case where something else called
> startService() to start up the service, and the service is the one who
> knows when it is time to stop.
>
> For example, IntentService calls stopSelf() when there is no more work
> to be done by the background thread.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> Android Training in US: 26-30 April 2010:http://onlc.com

-- 
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] Re: To Be Loved As To Love

2010-02-19 Thread Ken H
...but an ice storm or falling tree can doom your relationship.
Therefore, he says, base your relationship on fiberoptic cable buried
deep under ground...were no one can touch it...or get a cell phone.

And never touch a live relationship or you may meet Him sooner than
you would like...

On Feb 19, 11:04 am, olipolus  wrote:
> If you picture yourself as a telephone pole, he says, and the other
> person as a telephone pole, you can see your relationship as the line
> strung between you. You can't hold up both ends by 
> yourself.http://relationship-olipolus.blogspot.com/

-- 
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] What is stopSelf() doing?

2010-02-19 Thread Ken H
If I call stopSelf() in a service, does it call onDestroy? I want to
clean up after myself, but I'm a little vague on this process and the
docs don't help much.

Ken

-- 
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] Re: Can't show ProgressDialog during listview update

2010-02-18 Thread Ken H
Just tried the asynctask again, and it works. Basically I put the time
consuming part in doInBackground(), and then launched a progressDialog
in onProgressUpdate() to let users know nothing froze, and finally
dismissed the progrssDialog in onPostExecute(). Also added the final
refresh of the listview there.

Thanks again guys.

Ken

On Feb 18, 10:10 pm, Ken H  wrote:
> Wow, dude...thanks! That was a thorough answer. Usually get a vague,
> one sentence response that leaves me more confused than before.
>
> I don't know why I said that thing about the custom adapter...I think
> because I don't truly understand what it's doing and this activity
> revolves around it.
>
> Well, I need to digest all this and try it out. Thanks again.
>
> Ken
>
> On Feb 18, 5:24 pm, Bob Kerns  wrote:
>
>
>
> > Using a custom ArrayAdapter doesn't seem to me to relate to your
> > question, unless your problem is that it's broken. For example, if
> > yours doesn't notify the registered DataSetObservers that the data has
> > changed.
>
> > As for async tasks -- what you're describing IS a one-shot task, in
> > any sense that applies here. sure, you'll have more than one shot. But
> > in between those shots, with an ASyncTask, that thread and all the
> > memory required for its stack, will be available for use by OTHER
> > AsyncTasks, including ones possibly launched by the SDK. You do have
> > to create a new AsyncTask each time -- but that's a small price to pay
> > for significantly smaller memory usage.
>
> > So it's going to be more efficient than creating your own thread. Use
> > your own thread if you have something that has continuously evolving
> > state -- say some recursive process. Even then, you can generally
> > modify it to work with an ASync task.
>
> > I've read, on this list, I think, that early versions of ASyncTask
> > limit the pool of threads it uses to one. If that's the case, and you
> > run very long tasks, they may prevent other tasks from running. I
> > wouldn't worry about that unless you run into it as a problem; then
> > would be a time to either move your task into its own thread, or to
> > split your task up so it operates as a series of smaller pieces. And
> > it's my understanding that the pool is no longer limited to one
> > thread, so this is a limitation that will fade.
>
> > Still, if you are usually consuming one of those ASyncTask threads,
> > you're really not getting any benefit from using an ASyncTask other
> > than a convenient interface to moving that final action back to the UI
> > thread. But it's not hard to do that yourself, either.
>
> > If you DO run it on your own thread, you can post a message back to
> > the main thread, using a Handler aimed at the main thread's Looper,
> > which you can get via getMainLooper() on any Activity or Application
> > or Service, or the static method Looper.getMainLooper(). If you just
> > call Handler(), it picks up the Looper for the current thread -- I
> > believe that's why AsyncTask states in its threading rules: "The task
> > instance must be created on the UI thread.". Basically, you'll be
> > doing what AsyncTask does - but you'll have the flexibility to direct
> > it t the UI thread even if you create it elsewhere. It seems like a
> > character flaw that ASyncTask's default constructor isn't hardwired to
> > send things to the UI thread -- it would prevent a lot of preventable
> > bugs.
>
> > Just put any code you'd have put in the onPostExecute(Result) method
> > into the runnable you post to your handler.
>
> > By default, when you flip the orientation, indeed, your activity is
> > destroyed and recreated. But you can specify in the manifest what
> > configuration change events you're prepared to handle yourself, and
> > handle them in onCofigurationChanged(Configuration). If all that's
> > needed is a layout change, you may not need to do anything at all in
> > this method other than call  super.onConfugrationChanged(newConfig) --
> > which, of course, means you don't really need to define the method at
> > all. I recommend doing so, however, to flag that you're actually doing
> > this, and that here's where any configuration change happens. If you
> > have elements of your UI that scroll, you may need to reset the scroll
> > position here. I've seen a number of apps that appear not to do this,
> > and it's annoying.
>
> > While you can tell that a Thread has ended by checking its state,
> >

[android-developers] Re: Can't show ProgressDialog during listview update

2010-02-18 Thread Ken H
Wow, dude...thanks! That was a thorough answer. Usually get a vague,
one sentence response that leaves me more confused than before.

I don't know why I said that thing about the custom adapter...I think
because I don't truly understand what it's doing and this activity
revolves around it.

Well, I need to digest all this and try it out. Thanks again.

Ken

On Feb 18, 5:24 pm, Bob Kerns  wrote:
> Using a custom ArrayAdapter doesn't seem to me to relate to your
> question, unless your problem is that it's broken. For example, if
> yours doesn't notify the registered DataSetObservers that the data has
> changed.
>
> As for async tasks -- what you're describing IS a one-shot task, in
> any sense that applies here. sure, you'll have more than one shot. But
> in between those shots, with an ASyncTask, that thread and all the
> memory required for its stack, will be available for use by OTHER
> AsyncTasks, including ones possibly launched by the SDK. You do have
> to create a new AsyncTask each time -- but that's a small price to pay
> for significantly smaller memory usage.
>
> So it's going to be more efficient than creating your own thread. Use
> your own thread if you have something that has continuously evolving
> state -- say some recursive process. Even then, you can generally
> modify it to work with an ASync task.
>
> I've read, on this list, I think, that early versions of ASyncTask
> limit the pool of threads it uses to one. If that's the case, and you
> run very long tasks, they may prevent other tasks from running. I
> wouldn't worry about that unless you run into it as a problem; then
> would be a time to either move your task into its own thread, or to
> split your task up so it operates as a series of smaller pieces. And
> it's my understanding that the pool is no longer limited to one
> thread, so this is a limitation that will fade.
>
> Still, if you are usually consuming one of those ASyncTask threads,
> you're really not getting any benefit from using an ASyncTask other
> than a convenient interface to moving that final action back to the UI
> thread. But it's not hard to do that yourself, either.
>
> If you DO run it on your own thread, you can post a message back to
> the main thread, using a Handler aimed at the main thread's Looper,
> which you can get via getMainLooper() on any Activity or Application
> or Service, or the static method Looper.getMainLooper(). If you just
> call Handler(), it picks up the Looper for the current thread -- I
> believe that's why AsyncTask states in its threading rules: "The task
> instance must be created on the UI thread.". Basically, you'll be
> doing what AsyncTask does - but you'll have the flexibility to direct
> it t the UI thread even if you create it elsewhere. It seems like a
> character flaw that ASyncTask's default constructor isn't hardwired to
> send things to the UI thread -- it would prevent a lot of preventable
> bugs.
>
> Just put any code you'd have put in the onPostExecute(Result) method
> into the runnable you post to your handler.
>
> By default, when you flip the orientation, indeed, your activity is
> destroyed and recreated. But you can specify in the manifest what
> configuration change events you're prepared to handle yourself, and
> handle them in onCofigurationChanged(Configuration). If all that's
> needed is a layout change, you may not need to do anything at all in
> this method other than call  super.onConfugrationChanged(newConfig) --
> which, of course, means you don't really need to define the method at
> all. I recommend doing so, however, to flag that you're actually doing
> this, and that here's where any configuration change happens. If you
> have elements of your UI that scroll, you may need to reset the scroll
> position here. I've seen a number of apps that appear not to do this,
> and it's annoying.
>
> While you can tell that a Thread has ended by checking its state,
> that's not how you SHOULD be doing things. In Android, use a Handler
> and post whatever action you want to perform when the thread is ended.
>
> At a lower Java level, use the wait/notify protocol to synchronize.
> There's a clear and reliable usage pattern you can use, but it's a bit
> complicated to describe, and doing it wrong results in subtle bugs.
>
> You may want to consider using a try block, and posting your final
> action from the finally clause. Declare a variable 'ok' at the start
> of your function, and set it to  true when you reach the end of your
> code. Choose what code to run in the success and error/failure case
> based on the f

[android-developers] Re: Can't show ProgressDialog during listview update

2010-02-18 Thread Ken H
But what if you're using a custom ArrayAdapter? Also, I *think*
AsyncTask is meant for one shot type tasks. A user of this app may
update this listview multiple times.

But here is something I've discovered: if I change the orientation of
the screen, the list is properly updated. Question: how can I mimic
that screen orientation change? What is actually happening when you
flip the phone? It's restarting that activity right?

Another question (I'm hitting this problem from multiple angles), how
do you tell is a thread has ended? If I can tell when the thread ends
I can do this listview update in the main thread -- which I know
works.

Ken

On Feb 18, 1:33 pm, Mark Murphy  wrote:
> Ken H wrote:
> > I wasn't able to get the AsyncTask to work (although I have used it
> > successfully in another app).
>
> Here's an example of using AsyncTask to asynchronously populate a ListView:
>
> http://github.com/commonsguy/cw-android/tree/master/Threads/Asyncer/
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> Android App Developer Training: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] Re: Can't show ProgressDialog during listview update

2010-02-18 Thread Ken H
I wasn't able to get the AsyncTask to work (although I have used it
successfully in another app). What I did was use the Looper.prepare();
in my run() method:

public void run(){
Looper.prepare();

loadsongs(CURRENT_PLAYLIST);
mHandler = new Handler() {
@Override
public void handleMessage(Message msg){
// refresh the listing of playlists
}
};

Looper.loop();
}

It doesn't crash, but it doesn't show the refresh of the listview
either -- but I think the listview is being refreshed. I have to leave
the activity and return to it to see the update.

On Feb 18, 10:43 am, Frank Weiss  wrote:
> Use AsyncTask instead od Java threads. I'm not kidding, it's that simple.
>
>
>
> On Thu, Feb 18, 2010 at 10:21 AM, Ken H  wrote:
> > What am I doing wrong here? I have a listview of items (songs on the
> > sd card). The user has an option to load all the songs on the sd card
> > to into a current playlist -- those songs are what is displayed in the
> > listview. Because this can take few seconds to load if they have a lot
> > of songs on the card, I want to display a progress dialog to just tell
> > the user "One moment..." until the list refresh is done.
>
> > I launch a thread to do this. I've done this successfully on another
> > app I have (which just updates a database in the background but
> > doesn't update any display), but this one fails with this error
> > message, "Can't create handler inside thread that has not called
> > Looper.prepare()". I chopped down the activity and pasted it below.
> > What am I doing wrong here? I have just a vague idea of what might be
> > happening.
>
> > By the way, everything works when I take out the threaded stuff, it
> > just looks like the app freezes for a couple seconds.
>
> > Ken
>
> > /
>
> > *** 
> > */
>
> > public class ListingThing extends ListActivity implements Runnable {
> >        public static final String PREF_NAME = "PlaylistAlarmPreferences";
> >    static final private int CONFIGURE_PLAYLIST = Menu.FIRST;
> >    static final private int DELETE_LIST = Menu.FIRST+1;
> >    static final private int DELETE_SONG = Menu.FIRST;
> >    static final private int LOAD_ALL = Menu.FIRST+2;
> >        String playlistName, CURRENT_PLAYLIST;
> >    SharedPreferences settings;
> >    String[] items, subitems, fullpath;
> >    int DRILL_DOWN_LEVEL, resultCount;
> >    MediaPlayer mMediaPlayer;
> >    ProgressDialog myProgressDialog;
>
> >        /** Called when the activity is first created. */
> >   �...@override
> >    public void onCreate(Bundle savedInstanceState) {
> >        super.onCreate(savedInstanceState);
>
> >                mMediaPlayer = new MediaPlayer();
>
> >                getListOfPlaylists();
> >        setListAdapter(new MySpecialAdapter(this));
> >                // you need this for the contextmenu
> >                registerForContextMenu(getListView());
> >    }
>
> >    public void getListOfPlaylists(){
> >        // query db for list of songs
> >    }
>
> >    class MySpecialAdapter extends ArrayAdapter {
> >        Activity context;
>
> >        MySpecialAdapter(Activity context) {
> >                super(context, R.layout.double_list_item, items);
> >                this.context=context;
> >        }
>
> >        public View getView(int position, View convertView, ViewGroup
> > parent) {
> >                View row=convertView;
>
> >                if (row==null) {
> >                        LayoutInflater inflater=context.getLayoutInflater();
> >                        row=inflater.inflate(R.layout.double_list_item,
> > null);
> >                }
>
> >                TextView text1 = (TextView)row.findViewById(R.id.maintext);
> >                text1.setText(items[position]);
> >                TextView text2 = (TextView)row.findViewById(R.id.subtext);
> >                text2.setText(subitems[position]);
> >                row.setSoundEffectsEnabled(true);
>
> >                        return row;
> >        }
> >    }
>
> >        // This handles a context menu item click
> >   �...@override
> >        public boolean onContextItemSelected(MenuItem item) {
> >                AdapterContextMenuInfo info = (AdapterContextMenuInfo)
> > item.getMenuInfo();
> >       

[android-developers] Can't show ProgressDialog during listview update

2010-02-18 Thread Ken H
What am I doing wrong here? I have a listview of items (songs on the
sd card). The user has an option to load all the songs on the sd card
to into a current playlist -- those songs are what is displayed in the
listview. Because this can take few seconds to load if they have a lot
of songs on the card, I want to display a progress dialog to just tell
the user "One moment..." until the list refresh is done.

I launch a thread to do this. I've done this successfully on another
app I have (which just updates a database in the background but
doesn't update any display), but this one fails with this error
message, "Can't create handler inside thread that has not called
Looper.prepare()". I chopped down the activity and pasted it below.
What am I doing wrong here? I have just a vague idea of what might be
happening.

By the way, everything works when I take out the threaded stuff, it
just looks like the app freezes for a couple seconds.

Ken

/
/

public class ListingThing extends ListActivity implements Runnable {
public static final String PREF_NAME = "PlaylistAlarmPreferences";
static final private int CONFIGURE_PLAYLIST = Menu.FIRST;
static final private int DELETE_LIST = Menu.FIRST+1;
static final private int DELETE_SONG = Menu.FIRST;
static final private int LOAD_ALL = Menu.FIRST+2;
String playlistName, CURRENT_PLAYLIST;
SharedPreferences settings;
String[] items, subitems, fullpath;
int DRILL_DOWN_LEVEL, resultCount;
MediaPlayer mMediaPlayer;
ProgressDialog myProgressDialog;

/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);

mMediaPlayer = new MediaPlayer();

getListOfPlaylists();
setListAdapter(new MySpecialAdapter(this));
// you need this for the contextmenu
registerForContextMenu(getListView());
}

public void getListOfPlaylists(){
// query db for list of songs
}

class MySpecialAdapter extends ArrayAdapter {
Activity context;

MySpecialAdapter(Activity context) {
super(context, R.layout.double_list_item, items);
this.context=context;
}

public View getView(int position, View convertView, ViewGroup
parent) {
View row=convertView;

if (row==null) {
LayoutInflater inflater=context.getLayoutInflater();
row=inflater.inflate(R.layout.double_list_item, null);
}

TextView text1 = (TextView)row.findViewById(R.id.maintext);
text1.setText(items[position]);
TextView text2 = (TextView)row.findViewById(R.id.subtext);
text2.setText(subitems[position]);
row.setSoundEffectsEnabled(true);

return row;
}
}

// This handles a context menu item click
@Override
public boolean onContextItemSelected(MenuItem item) {
AdapterContextMenuInfo info = (AdapterContextMenuInfo)
item.getMenuInfo();
Object n = this.getListAdapter().getItemId((int)info.id);
final String pos = n.toString();// get the item number of
selection

myProgressDialog = ProgressDialog.show(this,
  "One moment...", "Refreshing list of songs in
playlist.", true);
CURRENT_PLAYLIST = items[Integer.parseInt(pos)];
Thread t = new Thread(this);
t.start();

return super.onContextItemSelected(item);
}

public void run(){
loadsongs(CURRENT_PLAYLIST);
handler.sendEmptyMessage(0);
}

private Handler handler = new Handler() {
@Override
public void handleMessage(Message msg){
myProgressDialog.dismiss();
// refresh the listing of playlists
getListOfPlaylists();
setListAdapter(new MySpecialAdapter(ListingThing.this));

}
};

// delete all songs in playlist and then reload all songs into it
private void loadsongs(String pl){
try{
Uri media = MediaStore.Audio.Media.EXTERNAL_CONTENT_URI;
DBAdapter db_songs = new DBAdapter(ListingThing.this);

String[] projection = { 
// The columns we want
MediaStore.Audio.Media._ID, 
// 0
MediaStore.Audio.Media.ARTIST,  
// 1 artist
MediaStore.Audio.Media.TITLE,   
// 2 song
MediaStore.Audio.Media.DATA,
// 3 full p

[android-developers] Re: Launch ContextMenu from ContextMenu

2010-01-22 Thread Ken H
Mark,

Dang, I just looked it up (http://developer.android.com/intl/fr/guide/
topics/ui/dialogs.html) and you are right! It's an alertdialog using
the setitems method.

Ken

On Jan 22, 9:54 am, Ken H  wrote:
> But an AlertDialog with selectable items? I thought you could just do
> "Yes", "No", "Ok", "Cancel", etc. and a message above with those.
>
> Well I guess my question should be how do you launch a ContextMenu-
> like menu from a contextmenu?
>
> Ken
>
> On Jan 22, 3:06 am, "Mark Murphy"  wrote:
>
>
>
> > > How can I launch a contextmenu from a contextmenu?
>
> > > I'm trying to replicate the MediaPlayer action that happens when you
> > > long click a song, then click "Add to playlist" in the resulting
> > > contextmenu. When you click that menu item, another contextmenu pops
> > > up with "Add to playlist" as the title, and "Current playlist", "New",
> > > and however-many-playlists-you-have defined after that.
>
> > The second one might just be an AlertDialog.
>
> > --
> > Mark Murphy (a Commons Guy)http://commonsware.com
> > Android App Developer Books:http://commonsware.com/books.html

-- 
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] Re: Launch ContextMenu from ContextMenu

2010-01-22 Thread Ken H
But an AlertDialog with selectable items? I thought you could just do
"Yes", "No", "Ok", "Cancel", etc. and a message above with those.

Well I guess my question should be how do you launch a ContextMenu-
like menu from a contextmenu?

Ken

On Jan 22, 3:06 am, "Mark Murphy"  wrote:
> > How can I launch a contextmenu from a contextmenu?
>
> > I'm trying to replicate the MediaPlayer action that happens when you
> > long click a song, then click "Add to playlist" in the resulting
> > contextmenu. When you click that menu item, another contextmenu pops
> > up with "Add to playlist" as the title, and "Current playlist", "New",
> > and however-many-playlists-you-have defined after that.
>
> The second one might just be an AlertDialog.
>
> --
> Mark Murphy (a Commons Guy)http://commonsware.com
> Android App Developer Books:http://commonsware.com/books.html

-- 
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] Launch ContextMenu from ContextMenu

2010-01-21 Thread Ken H
How can I launch a contextmenu from a contextmenu?

I'm trying to replicate the MediaPlayer action that happens when you
long click a song, then click "Add to playlist" in the resulting
contextmenu. When you click that menu item, another contextmenu pops
up with "Add to playlist" as the title, and "Current playlist", "New",
and however-many-playlists-you-have defined after that.

Ken

-- 
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] Re: minSdkVersion and file editing

2009-12-10 Thread Ken H
Thank you! That was it!

Wow, finally got a solution to a problem in this group!!

Ken

On Dec 10, 10:37 am, Vytautas Vaitukaitis
 wrote:
> Your app has to have android.permission.WRITE_EXTERNAL_STORAGE
> permission, which was introduced at SDK v4, in order to do this. I had
> the same problem with my app - the most annoying thing about this
> problem is that it only shows up at some of the devices with Android
>
> >=1.6...
>
> On Dec 10, 6:17 pm, Ken H  wrote:
>
>
>
> > Why is this happening?
>
> > I have an app that saves/renames/deletes files on the sd card. I could
> > do this with no problems when I set my minSdkVersion=3. When I changed
> > the minSdkVersion=4 I could no longer save/rename/delete those files.
>
> > At first I thought it was because Android didn't recognize my newly
> > modified app (increased the versionCode) as the original one that
> > first created the files.
>
> > Not a huge problem. I'm trying to keep older versions of Android from
> > using my app obviously, but I'd love to know what's happening.
>
> > Ken

-- 
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] minSdkVersion and file editing

2009-12-10 Thread Ken H
Why is this happening?

I have an app that saves/renames/deletes files on the sd card. I could
do this with no problems when I set my minSdkVersion=3. When I changed
the minSdkVersion=4 I could no longer save/rename/delete those files.

At first I thought it was because Android didn't recognize my newly
modified app (increased the versionCode) as the original one that
first created the files.

Not a huge problem. I'm trying to keep older versions of Android from
using my app obviously, but I'd love to know what's happening.

Ken

-- 
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] Re: neighbor cell information yields odd results with 3G

2009-12-09 Thread Ken H
getCid() is in hex format. I do a

thisCell.getCid() & 0x

to get the decimal format. Now the cdma end of it is a big 'ol
mystery.

Ken

On Oct 20, 11:42 am, Jimmy  wrote:
> The MNC and MCC can be parsed from the serving cell information (it
> works in 2G and seems to work in 3G as well) from the
> telManager.getNetworkOperator() and the neighbor LACs can be parsed
> from NeighboringCellInfo string.  So most of the info is there.  It's
> just the 3G neighbor info that is missing.  Let me know if you want
> the breakdown on these parameters and I'll send sample code.
>
> Maybe the 3G cell info is simply not parsed yet in the telephony stack
> correctly to feed the API.  I was hoping this was understood in 1.6
> where there was new support forCDMA. So if anyone understands the 3G
> neighbor cells, any help would be greatly appreciated.
>
> On Sep 30, 2:59 am, "Will 'Varfar'"  wrote:
>
>
>
> > there's quite a history of people asking this exact question.
>
> > Not a single answer yet though.
>
> > Quite what you can do with a CID without the LAC and MNC etc is a bit
> > unclear anyway.
>
> > And these questions, they keep disappearing from the search results.
> > Search this group for GetNeighboringCellInfo().  It doesn't show 
> > mehttp://groups.google.com/group/android-developers/browse_thread/threa...
> > for example.
>
> > Very fustrating.  Sorry I don't know how to help you Jimmy.
>
> > On Sep 11, 9:42 pm, Jimmy  wrote:
>
> > > I have an app that collects neighbor cell information (CID and RSSI).
> > > It works fine in 2G.  When switching to3G, the getCid() and getRssi()
> > > throw a NumberFormatException
>
> > > List  neighCell = null;
> > > neighCell = telManager.getNeighboringCellInfo();
> > > for (i = 0; i < numNeigh; i++) {
> > >         try {
> > >                 NeighboringCellInfo thisCell = neighCell.get(i);
> > >                 int thisNeighCID = thisCell.getCid();
> > >                 int thisNeighRSSI = thisCell.getRssi();
>
> > >         } catch (NumberFormatException e) {
> > >                 e.printStackTrace();
> > >                 NeighboringCellInfo thisCell = neighCell.get(i);
> > >                 cellIdOutput = String.format("%s", neighCell.toString
> > > ());
>
> > > }
>
> > > Using toString() (as above in last line of the catch) generates the
> > > following string...
>
> > > [[6c at 0], [74 at 0]]
>
> > > This NeighboringCellInfo list identifies it's size as 2, which looks
> > > right from the string output.
>
> > > Does this string contain3Gcell ID such as scrambling code (in hex)?
> > > Anyone know how to decode it?
>
> > > Thanks in advance for the help.

-- 
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] Android 1.5 and CDMA

2009-12-08 Thread Ken H
I though Android 1.5 could not run cdma, am I wrong? It doesn't have
the android.telephony.cdma.CdmaCellLocation library, correct?

Yet I have a user with an HTC Eris with this setup:

Model number: ADR6200
Firmware version: 1.5
Baseband version: 2.32.00.09.26
Kernel version: 2.6.27-e850bba0  "htc-ker...@and18-2 #926"
Build number: 1.12.605.1 CL76938 release-keys
Software version: 1.12.605.1
Hardware version: 0002

Am I missing something?

Ken

-- 
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] Re: Droid or android 2.0 performance issues?

2009-12-08 Thread Ken H
Jarrod,

I went from the iPhone to the myTouch this summer because I got tired
of hacking and wanted to experience 3G outside of my house (I had a
1st gen iPhone).

It's not your imagination, it is slower when compared to the iPhone
just doing basic things. The browser blows (and still blows). The
scrolling issues you described are the first thing I noticed -- it was
very frustrating, but I got use to it. But remember, Apple controls
all aspects of the iPhone (hardware and software) so that's why things
run so smooth and are so refined I think.

That said, I think Android will get much better. The phones are
constantly improving -- I don't think the G1 can even handle the same
OS your Droid runs on -- and the shear number of people developing for
Android is huge and growing and unfettered by the restrictions Apple
imposes on their developers (and it's free to get into this unlike
developing for the iPhone). Right now the Android Marketplace is where
the iPhone App Store was a little over a year ago -- lots of trivial,
redundant, applications because people are still learning. But that
changed on the App Store and will change on the Marketplace.

Honestly I think this will be a repeat of the PC vs. Mac wars of the
'80s which the PC won and, I think, Android will win.

My 2 cents.

Ken

On Dec 1, 11:26 am, Jarrod Overson  wrote:
> I had been waiting to make the switch from the iphone to android until
> both some nice hardware was released and it had been out for a while
> for the initial usability issues to be resolved. TheDroidis what
> made me take the plunge but I am *constantly* frustrated by what seems
> to be surprisingly sub-par performance for the most basic UI
> interaction.
>
> I started looking into the SDK and worked on a few apps in order to
> resolve some issues i was having, but even the most basic example apps
> in the sdk aren't nearly as fast as I would expect them to be on a
> new, relatively high-end device.
>
> For example, something as simple as the sample 'home' app that comes
> with the sdk can't even open the 'all programs' list smoothly. This
> may seem trivial, but it is very telling if a basic application
> written by programmers experienced in the SDK performs poorly on a
> virgin device.
>
> There are a slew of problems that bother me and i am reaching out for
> any expert insight as to whether or not they areDroidspecific, or
> general to android 2.0 that may be addressed with future updates. My
> primary frustrations:
>
> Delay between swiping gestures/clicks and visual response.
> Scrolling is choppy in almost all cases, from lists, to home, to browser 
> pages.
> Scrolls are frequently registered as clicks.
> Occasionally clicks register as powerful downward scrolls, so a click
> on a large list will throw me near the bottom of the list as if theDroidis 
> consciously mocking me.
>
> I could go on for pages, but as I write them all down I think the bulk
> of my issues stem from the general feeling of sluggishness on theDroid. 
> Usability can be enhanced by other applications and by
> workarounds, but poor performance at an OS or device level doesn't
> seem easily fixable.
>
> I can't imagine it is inherent to theDroidbecause the specs seem
> perfectly decent for a hand held device. Could it be the screen
> resolution be requiring more processing power than theDroidcan
> provide? Does the road forward look promising?
>
> "Works fine for me" is not a useful response, so please use restraint
> when hovering over the 'Send' button. This is not device-specific, the
> same problems occur on the 5 other droids i've compared against in my
> company. Some people are OK with it, which is fine by me, but arguing
> that opinion is not helpful.
>
> --
> Jarrod

-- 
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] Re: GSM Timing Advance in Android

2009-12-04 Thread Ken H
Not that I've seen. The API is frustratingly limited in the phone
parameters you can query. They seem to have held us to *basic* things
like data state, CGI, RSSI, and basic network info among others.

http://developer.android.com/intl/fr/reference/android/telephony/TelephonyManager.html

Ken

On Dec 4, 6:01 am, BillS  wrote:
> Are there any Android APIs that allow the application to retrieve the
> GSM Timing Advance?
>
> Thanks,
> BillS

-- 
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] Re: CDMA home carrier

2009-12-04 Thread Ken H


On Dec 3, 9:57 am, gudujarlson  wrote:
> not the home operator. So for example, if I had a contract with AT&T
> and I was in Seattle, both the current cell site and the home operator
> are the same, but if I traveled to Vancouver, Canada the cell site
> would be owned by Rogers and those functions would return the MCC and
> MNC of Rogers, not AT&T.

Correct, which is what you would expect.

> The GSM API on Android, Windows Mobile, and
> Blackberry allow you to differentiate between the home and current
> operator...

I've never been roaming on my app so I'd be curious to know what it
did myself.

> I have not tested getNetworkOperatorName() in a roaming situation, but
> my assumption is that it returns the carrier that owns the current
> cell site.

getNetworkOperatorName() is all I use, although thinking about it I
could see why you would use the getSimOperator -- the sim has the
carrier info and that never changes. I guess this is the
differentiation you mentioned?

> ServiceState.getOperatorNumeric()
>     Returns the current operator (MCC + MNC). This is retrieved from
> the current cell site.

You can also get that from getNetworkOperator() and parse the string.
I wonder why they put that in so many places?


> TelephonyManager.getSimOperator()
>     In non "world phones", this returns the first 6 digits of the IMSI
> (e.g. 314). This is bogus, because CDMA IMSI's have 00 for the MNC
> which 2 digits not 3 and useless either way. The 4 on the end is
> actually the beginning of the subscriber ID. This is a bug in Android
> as far as I can tell. In world phones, it will probably return the MCC
> +MNC for an operator in Europe.
>
> ServiceState.getOperatorNumeric()
>     Returns the MCC + 00. This is mostly useless, because it does not
> identify the carrier.

Well, it wouldn't. That's why it's a country code and not a network
code.

But don't get me started on Android 2.0 and this CDMA stuff. Example:
the CdmaCellLocation has two methods (getBaseStationLatitude() &
getBaseStationLongitude()) which, judging from the name return the LAT/
LON of the site. Great, I'm thinking until I look at the datatype and
see that they are both INTs. Which, again, wouldn't be a problem if
they said, "To get the decimal value divide by 1,000,000", but they
don't. Another beautiful mystery is that onSignalStrengthChanged has
been depracated, but they don't state what the replacement is.

Ken

-- 
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] Re: CDMA home carrier

2009-12-02 Thread Ken H
I think I'm getting confused by what you mean by "home operator" and
"current cell tower".

The getNetworkOperatorName() method will get you the network or
"carrier" your phone is on (T-Mobile for example). I assume that is
what you mean by "home operator".

Technically there is nothing that tells you the "cell tower". Mobiles
don't talk to towers, they talk to cells, or sectors, on the tower.
Most towers -- or cell sites, since they can be located anywhere, not
just on poles -- have 3 sectors. Depending or your location relative
to that site your mobile may be talking to sector A, B or C. In GSM
the cells are uniquely identified by the CGI which consist of the
mobile country code (MCC), mobile network code (MNC), location area
code (LAC), and Cell ID. You can get MCC & MNC by using
getNetworkOperator(), and you can get the LAC & CI by using

GsmCellLocation cl = (GsmCellLocation) tm.getCellLocation();
int CELLID = cl.getCid();
int LAC = cl.getLac();

But again, this is GSM. The method I mentioned in my first post
*should* get you the CDMA version of the System ID, Network ID, and
Base Station ID, which will uniquely identify the cell you are current
on.

Ken


On Dec 2, 4:22 pm, gudujarlson  wrote:
> What you are referring to is information about the current cell tower,
> not the home operator. On a GSM phone, you can get the home operator
> with TelephonyManager.getSimOperator(), but on a CDMA phone it returns
> a bogus value.
>
> On Dec 2, 6:14 pm, Ken H  wrote:
>
>
>
> > On GSM I use:
>
> > TelephonyManager tm  = (TelephonyManager) getSystemService
> > (Context.TELEPHONY_SERVICE);
> > String Operator = tm.getNetworkOperatorName();
>
> > I assume CDMA is the same since I've seen nothing in the docs that say
> > otherwise. Also, for CDMA you can get SystemID & etc., by using:
>
> > CdmaCellLocation cd = (CdmaCellLocation) tm.getCellLocation();
> > int sysid = cd.getSystemId();
> > int netid = cd.getNetworkId();
> > int bsid = cd.getBaseStationId();
>
> > I can't test this last part out since I have a GSM phone. You can also
> > look at:
>
> >http://developer.android.com/intl/fr/reference/android/telephony/cdma...
>
> > Ken

-- 
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] Re: The GPS Shutdown Thing

2009-12-02 Thread Ken H
1 minute seems long to me too, 5-10 sec is a good generic interval if
you just want it to turn off quicker. Also remember that the GPS needs
a time *and* distance update interval.

But my question is this, have you sat down and watched to see if the
little satellite dish disappears after a minute? My guess is it
should. Also remember your app is usually just suspended when you
first turn it off (so it can be booted up quicker). If android needs
the memory it will kill it.

Ken

On Dec 2, 11:24 am, Mark Wyszomierski  wrote:
> I've been working with the location providers lately, I haven't seen
> this behavior. When I deregister my listeners, the GPS icon goes away,
> I haven't seen it stick around.
>
> Even one minute intervals for GPS seems like a lot for me - I'm
> guessing users won't be able to move fast enough in one minute to make
> any real difference in location. All depends on the app though.
>
> On Nov 19, 6:33 pm, jtoolsdev  wrote:
>
>
>
> > I'm looking to a solution using the MyLocationOverlay library where
> > one can use runOnFirstFix which can launch the thread (which I already
> > have) when the current location is found.  Once it is found I can shut
> > down the location stuff as I only need it at the start of the program.
>
> > On Nov 19, 3:20 pm, Nathan  wrote:
>
> > > On Nov 19, 12:09 pm, jtoolsdev  wrote:
>
> > > > The recommendation of
> > > > the SDK is for setting up the location listener is to set time at
> > > > 6ms or 1 minute.  
>
> > > Really? Does Google Maps follow that guideline?
>
> > > > My tests show if you use that number when
> > > > exiting the app it may not shutdownGPS.  
>
> > > Sounds bad.I hope there is an answer for that.
>
> > > Nathan

-- 
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] Re: getLastKnownLocation *again*

2009-12-02 Thread Ken H
My understanding is getLastKnownLocation is used to give your app an
immediate location since getting a good GPS fix can sometimes take up
to a minute. This way your app would show *something* until a better
position can be determined by initializing a provider, setting up your
time and distance update intervals, and giving that info to
requestLocationUpdates for immediate updates.

Ken

On Dec 2, 2:19 pm, jotobjects  wrote:
> requestLocationUpdates() docs say -
>
> "It may take a while to receive the most recent location. If an
> immediate location is required, applications may use the
> getLastKnownLocation(String) method."
>
> You could verify that getLastKnownLocation(providerName) returns the
> same Location as the argument to onLocationChanged() by logging
> getLatitude(), getLongitude(), and getProvider() for both Location
> values.  If these values are different AND they are different than
> what MyLocation shows then there are three different Location values.
> It would be interesting to know which one is right!
>
> On Dec 2, 1:30 pm, stanlick  wrote:
>
>
>
> > Are you saying if the CB occurred, indicating a new location "fix"
> > that getLastKnownLocation would not also return this last know
> > location?  I think I tried using the the location local variable
> > during one of my permutations and the net effect was the same.  Funny
> > thing is, while the Android API location shows me several blocks from
> > where I am, the My Location button in Google Maps finds me perfectly!
> > I have checked all my criteria and it looks okay.  ACCURACY_FINE no
> > concern for cost, etc.  I just don't get it!  I wish there was a
> > criteria DO_IT_LIKE_GOOGLE_DOES!
>
> > Sleepless in St. Louis,
> > Scott
>
> > On Dec 2, 3:14 pm, Jeffrey Blattman 
> > wrote:
>
> > > LocationManager. requestLocationUpdates()
> > > 
> > > LocationListener. onLocationChanged
> > > (Location
> > > 
> > > location)
>
> > > you are passed the location in the CB. no need to call getLastKnown...
>
> > > On 12/2/09 1:10 PM, stanlick wrote:
>
> > > > I *am* using the listener loop and using getLastKnownLocation from the
> > > > locationManager inside the onLocationChanged() method.  Is this not
> > > > the correct pattern?
>
> > > > On Dec 2, 2:31 pm, Lance Nanek  wrote:
>
> > > >> Why are you using getLastKnownLocation if you want a fresh fix? The
> > > >> documentation says it won't even start the location provider. Use
> > > >> requestLocationUpdates.
>
> > > >> On Dec 2, 2:53 pm, stanlick  wrote:
>
> > > >>> Didn't we put a man on the moon?  It can't be done seems a little lazy
> > > >>> today!
>
> > > >>> I have read all the posts about this topic and I understand the
> > > >>> arguments being made.  However, I would like to know how Google Maps
> > > >>> can return my *current* location yet while driving the same stretch of
> > > >>> road, the Android API often (not always) gives me a last known
> > > >>> location that was miles back.  I need to be able to rely on the API to
> > > >>> provide me with a *current location* and I have tried all the tricks
> > > >>> being proposed here and elsewhere.  Is there lower level code
> > > >>> someplace that could ping the phone's radio for a "fresh fix?"
>
> > > >>> If you have solved this riddle, I would be happy to pay for your
> > > >>> solution.
>
> > > >>> Peace,
> > > >>> Scott
>
> > > --
>
> > >  qr-gmail.png
> > > < 1KViewDownload

-- 
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] Re: CDMA home carrier

2009-12-02 Thread Ken H
On GSM I use:

TelephonyManager tm  = (TelephonyManager) getSystemService
(Context.TELEPHONY_SERVICE);
String Operator = tm.getNetworkOperatorName();

I assume CDMA is the same since I've seen nothing in the docs that say
otherwise. Also, for CDMA you can get SystemID & etc., by using:

CdmaCellLocation cd = (CdmaCellLocation) tm.getCellLocation();
int sysid = cd.getSystemId();
int netid = cd.getNetworkId();
int bsid = cd.getBaseStationId();

I can't test this last part out since I have a GSM phone. You can also
look at:

http://developer.android.com/intl/fr/reference/android/telephony/cdma/CdmaCellLocation.html

Ken


On Dec 2, 3:47 pm, gudujarlson  wrote:
> How does one determine the home carrier on a CDMA phone? By home
> carrier I mean the carrier that the phone's owner has a contract with,
> not the owner of the cell site that the phone is communicating with.
> These are different when the phone is roaming. On a GSM phone I can
> get the home carrier from the IMSI recorded on the SIM, but this does
> not work on a CDMA phone. CDMA has a similar identifier called home
> system ID. Is there a way to query the home system ID? If that is not
> possible, how do I determine the home carrier? On Windows Mobile I am
> forced to search the registry looking for strings like 'Verizon' and
> 'Sprint'. Is there a similar klooge on 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] Re: running sqlite3 commands from app?

2009-12-02 Thread Ken H
>From the looks of it you're going to need to read up on SQLite. This
is where I got started:

http://www.devx.com/wireless/Article/40842/0/page/1

But to import data to a database in your app, you need to do something
like this...

SQLiteDatabase db;
BufferedReader inFile;
String iLine;
try{
   inFile = new BufferedReader(new FileReader("/sdcard/[your file
name]"));  // open your file
}catch(FileNotFoundException e){
   // do something if file does not exist
}

try{
   ContentValues inputvalues = new ContentValues();
   iLine = inFile.readLine();  // read line from file
   while(iLine != null){
   String[] elements = iLine.split(",");  <-- i'm using a csv file
as an example
   inputvalues.put("column1", elements[1]);  <-- substitute your
db column names
   inputvalues.put("column2", elements[2]);
   inputvalues.put("column3", elements[3]);
   db.insert("database_name", null, inputvalues);  // insert
values into database
   iLine = inFile.readLine();   // read next line
   }
   inFile.close();
}catch(Exception e){
   // do something
}

You cannot issue command-line instructions like '.table' from the app,
I think that is were you are getting confused. You interact with the
database like a *database*, meaning you need to use SQL commands like
you would on SQL Server or Oracle.

Ken

On Dec 1, 1:53 pm, dsukhram  wrote:
> Thanks for your reply Chad. However I was just using the '.tables'
> command as an example. What I really need to do is run the '.read'
> command in order to load data into my db
>
> On Dec 1, 1:21 pm, chad ziccardi  wrote:
>
>
>
> > On Dec 1, 2009, at 9:32 AM, dsukhram wrote:
>
> > > When I try to run the '.tables' command by doing the following:
>
> > > SQLiteDatabase db = this.openOrCreateDatabase(DB_NAME, MODE_PRIVATE,
> > > null);
> > > db.execSQL(".tables");
>
> > Try this:
> > db.execSQL("SELECT name FROM sqlite_master where type='table' and name NOT 
> > LIKE 'sqlite_%';");

-- 
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] Re: Accessing Remote Database using Android

2009-12-02 Thread Ken H
Not sure what you mean by "remote database", but you can create your
own SQLite database on the phone fairly easily. This is where I got
started on it:

http://www.devx.com/wireless/Article/40842

Ken

On Dec 2, 1:21 am, Sanju  wrote:
> Hi.., Am new to mobile development environment as well as android... I
> m trying to store data in the remote database and retrieve back...
> Can anybody help me...

-- 
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] Figuring out android.telephony.cdma

2009-12-02 Thread Ken H
Ok, I've built an app for doing ad-hoc drive testing on a GSM network
and test it on my myTouch. Now I need to modify the code to work on a
CDMA network (Verizon). I've been looking over the CdmaCellLocation
class which seems to give me what I want.

Question: does anyone know what getBaseStationLatitude and
getBaseStationLongitude will actually give me? The documentation says
it returns an int. The problem is you cannot present Latitude and
Longitude as an int (it should be a float or double). I don't have a
Droid which makes testing this a little problematic for me.

Ken

-- 
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] Re: How to answer comments on your apps

2009-11-12 Thread Ken H
Amen brother!

I think I'll use your method of answering bad comments.

It is frustrating in the extreme to see someone go through the effort
to write a comment and post it to the market place when they could
have just as easily emailed it to the developer who could have, 1)
explained what is really happening, 2) ask them exactly what they are
doing to cause this issue, or 3) just tell them that you'll start
working on a fix asap.

I find myself hating my own users!!

Ken

On Nov 10, 11:38 am, "Maps.Huge.Info (Maps API Guru)"
 wrote:
> I've been puzzled by the lack of ability for a developer to 
> answercommentsmade on the market by users. It has been frustrating to 
> seenegativecommentsor questions made and be unable to do anything about
> them...
>
> I've found an easy to use, yet undocumented method to do this.
>
> First, download and install your own app.
>
> Second, wait for a comment that you need to respond to, then simply
> add a comment of your own prefaced by "Developer comment:" - your
> comment will appear as a new comment. Each comment made sticks in 
> thecommentslist, so you can effectively answer anything made on your
> app.
>
> Google should have mentioned this, it's so easy to do.
>
> Paid apps may have a problem doing this as developers (for some
> reason) can't download their own paid apps.
>
> -John Coryat
>
> "Radar Now!"
>
> "What Zip Code?"

-- 
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] Re: Should I Be Using AsyncTask?

2009-10-22 Thread Ken H

I think I solved it. While in the actual AsyncTask I can listen for
button clicks and such just like normal. So I just set up buttons and
listeners to set the direction and speed of the cursor reading method.

On Oct 21, 5:00 pm, Ken H  wrote:
> I have an app that stores gps data into a SQLite db. I want to 'play'
> that data back. I was having trouble getting that to work until I
> stumbled across Romain Guy's blog on painless threads -- thank you
> Romain!
>
> Now that I got that to work, I want to do things like stop, pause,
> backup, replay...like a little VCR. But the AsyncTask has that one-
> time-use condition (which in practice means that I *can* replay if I
> let the thread finish, leave and come back). But that's a little much
> for the users to live with.
>
> Question: is there a better way? Plain english answers greatly
> appreciated! :)
>
> Ken
--~--~-~--~~~---~--~~
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] Should I Be Using AsyncTask?

2009-10-21 Thread Ken H

I have an app that stores gps data into a SQLite db. I want to 'play'
that data back. I was having trouble getting that to work until I
stumbled across Romain Guy's blog on painless threads -- thank you
Romain!

Now that I got that to work, I want to do things like stop, pause,
backup, replay...like a little VCR. But the AsyncTask has that one-
time-use condition (which in practice means that I *can* replay if I
let the thread finish, leave and come back). But that's a little much
for the users to live with.

Question: is there a better way? Plain english answers greatly
appreciated! :)

Ken
--~--~-~--~~~---~--~~
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] Re: Cursor return order

2009-10-21 Thread Ken H

You know, it scares me the things I don't know about Android...

Thanks again.

On Oct 21, 9:59 am, Mark Murphy  wrote:
> Ken H wrote:
> > Ok that's what I thought, thanks.
>
> > Just curious, what other way is there to implement a cursor?
>
> Cursor is just an interface. There are at least seven Cursor
> implementations in Android, and creating your own is not terribly hard,
> particularly if you use AbstractCursor as a base. For example, I have a
> JoinCursor implementation that demonstrates creating a wrapping Cursor
> that blends two data sources:
>
> http://github.com/commonsguy/cw-advandroid/tree/master/Database/JoinC...
>
> > I usually
> > just load it and roll through in a do/while loop
> > (moveToFirst...moveToNext that sort of thing).
>
> That's a typical pattern for *using* a Cursor. You can also hand a
> Cursor off to a CursorAdapter to display in a ListView or other form of
> AdapterView.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> _Android Programming Tutorials_ Version 1.0 In Print!
--~--~-~--~~~---~--~~
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] Re: Cursor return order

2009-10-21 Thread Ken H

Ok that's what I thought, thanks.

Just curious, what other way is there to implement a cursor? I usually
just load it and roll through in a do/while loop
(moveToFirst...moveToNext that sort of thing).

Ken

On Oct 21, 9:20 am, Mark Murphy  wrote:
> Ken H wrote:
> > Will a cursor be ordered the same way as the query that loaded it up?
> > For example, if I query a table, and the result set is ordered by date
> > (oldest date first), will the first record in the cursor be the oldest
> > date as well?
>
> That depends on the implementation of the Cursor.
>
> In the case of a SQLiteCursor, yes, the results will be in the order you
> requested them via the ORDER BY clause.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> _Android Programming Tutorials_ Version 1.0 In Print!
--~--~-~--~~~---~--~~
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] Cursor return order

2009-10-21 Thread Ken H

Will a cursor be ordered the same way as the query that loaded it up?
For example, if I query a table, and the result set is ordered by date
(oldest date first), will the first record in the cursor be the oldest
date as well?
--~--~-~--~~~---~--~~
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] Re: Do maps always need GPS?

2009-10-20 Thread Ken H

That is a good idea, thank you!

I'm just having the usual "Easy things are hard, hard things are easy"
problem. :)

On Oct 20, 1:07 pm, Wayne Wenthin  wrote:
> You can use coarselocation too.   That way you don't have to wait so long
> for an update.
>
> On Tue, Oct 20, 2009 at 1:02 PM, Ken H  wrote:
>
> > Just want to make sure I'm not missing something because I'm having
> > trouble making this work for some reason. If I use a map, do I need to
> > setup the LocationManager and GPS criteria and all?
>
> > I just need a map to paint on. I'm building an activity that displays
> > location data collected and stored in SQLite...basically showing the
> > user where they were (it's more complicated than that, but that is the
> > essence). I can do this without needing to start up the whole GPS
> > thing right??
>
> > Ken
>
> --
> Writing code is one of few things
> that teaches me I don't know everything.
>
> http://www.fuligin.com
--~--~-~--~~~---~--~~
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] Do maps always need GPS?

2009-10-20 Thread Ken H

Just want to make sure I'm not missing something because I'm having
trouble making this work for some reason. If I use a map, do I need to
setup the LocationManager and GPS criteria and all?

I just need a map to paint on. I'm building an activity that displays
location data collected and stored in SQLite...basically showing the
user where they were (it's more complicated than that, but that is the
essence). I can do this without needing to start up the whole GPS
thing right??

Ken
--~--~-~--~~~---~--~~
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] Display my tracks in map

2009-09-25 Thread Ken H

I really thought this would be an easy thing to do...

I've built an app, and one of the things it does is show my current
position on the little google map on the phone. I walk around it and
it shows my speed, direction and position just fine.

Now what I want to do is show my tracks. I don't want to loose any of
the dots showing where I was -- I want it paint a trail of everywhere
I go. Simple, no?

I think my problem is I don't really understand overlays. Can I re-use
an overlay? That was my first instinct...rather than clear all the old
overlays on the mapview, make a new one, stick a dot on it and place
it in the mapview I wanted to grab the current overlay and *add" a new
dot to it and put it back on the mapview. But I can seem to get that
to work. Just out of curiosity I even try not clearing the old
overlays and just adding new ones...that took about two minutes the
bring the phone to its knees.

Anybody have any ideas? A direction I can be pointed in? I know this
can be done, but I've spent a week searching with no joy.

Ken
--~--~-~--~~~---~--~~
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] Re: Signed vs. Unsigned

2009-09-12 Thread Ken H

I think I got it figured. I just have to do it the way the dev guide
says do it -- create a key in the keystore and apply that to the
application. I'm new to the whole signing thing and using the "Export
Signed Application Package" confused me because there is no keystore
created (at least not one I can find...and I search the whole
computer), so I was confused on how to re-deploy my app.

Unfortunately I think the users of my app will have to reinstall.

Ken

On Sep 12, 4:53 pm, Jack Ha  wrote:
> Your app needs to be digitally signed.
>
> If you use Eclipse with the ADT plugin, skip to the Compiling and
> signing with Eclipse ADT section. Otherwise, follow the instructions
> to export an unsigned .apk and then sign it with jarsigner.
>
> --
> Jack Ha
> Open Source Development Center
> ·T· · ·Mobile· stick together
> The coverage you need at the price you want
>
> The views, opinions and statements in this email are those of
> the author solely in their individual capacity, and do not
> necessarily represent those of T-Mobile USA, Inc.
>
> On Sep 12, 3:40 pm, Ken H  wrote:
>
>
>
> > Ok, stupid question time: what's the difference being "Export Signed
> > Application Package" and "Export Unsigned Application Package"? Under
> > 'Signing for Public Release' in the dev guide it says you must:
>
> > 1. Compile the application in release mode
> > 2. Obtain a suitable private key
> > 3. *Sign* the application with your private key
>
> > But then it continues:
>
> > "To prepare your application for release...To export an unsigned .apk
> > from Eclipse, right-click the project in the Package Explorer and
> > select Android Tools > Export Unsigned Application Package."
>
> > But below this under "Compiling and signing with Eclipse ADT" it says
> > to "To create a signed .apk, right-click the project in the Package
> > Explorer and select Android Tools > Export Signed Application
> > Package...When you complete the Export Wizard, you'll have a
> > signed .apk that's ready for distribution"
>
> > Huh? Do I need my app signed or unsigned for distribution on market
> > place?
--~--~-~--~~~---~--~~
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] Re: Signed vs. Unsigned

2009-09-12 Thread Ken H

Thank you. That part is starting to sink in after reading it 10
times :)

My next problem/question is this: when I fix some bugs in the app do I
need to re-sign it? I just assumed I did, but when I do "Export Signed
Application Package", give it the password for the keystore (the
keystore location is the path to my .apk), I always run into a wall
that says "invalid keystore format". Am I doing something wrong?

Oh, by the way, I work at the FSC :)

Ken

On Sep 12, 4:53 pm, Jack Ha  wrote:
> Your app needs to be digitally signed.
>
> If you use Eclipse with the ADT plugin, skip to the Compiling and
> signing with Eclipse ADT section. Otherwise, follow the instructions
> to export an unsigned .apk and then sign it with jarsigner.
>
> --
> Jack Ha
> Open Source Development Center
> ·T· · ·Mobile· stick together
> The coverage you need at the price you want
>
> The views, opinions and statements in this email are those of
> the author solely in their individual capacity, and do not
> necessarily represent those of T-Mobile USA, Inc.
>
> On Sep 12, 3:40 pm, Ken H  wrote:
>
>
>
> > Ok, stupid question time: what's the difference being "Export Signed
> > Application Package" and "Export Unsigned Application Package"? Under
> > 'Signing for Public Release' in the dev guide it says you must:
>
> > 1. Compile the application in release mode
> > 2. Obtain a suitable private key
> > 3. *Sign* the application with your private key
>
> > But then it continues:
>
> > "To prepare your application for release...To export an unsigned .apk
> > from Eclipse, right-click the project in the Package Explorer and
> > select Android Tools > Export Unsigned Application Package."
>
> > But below this under "Compiling and signing with Eclipse ADT" it says
> > to "To create a signed .apk, right-click the project in the Package
> > Explorer and select Android Tools > Export Signed Application
> > Package...When you complete the Export Wizard, you'll have a
> > signed .apk that's ready for distribution"
>
> > Huh? Do I need my app signed or unsigned for distribution on market
> > place?
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---



  1   2   >