[android-developers] Re: How to interrupt a blocking I/O operation?

2011-01-07 Thread Tabman
I think you can extend the InputStream class and override its read method and inside read you can cancel/stop the read loop operation whenever you want to. Here is the source for InputStream.java http://www.docjar.com/html/api/java/io/InputStream.java.html Let me know if this solves your

[android-developers] Android GeoCoder Issue

2011-01-07 Thread Ankur Avlani
Hi All, I am using android map api. To plot overlays, for some address I need to get the lat lng values. I user GeoCoder to get the lat lng values based on address. I am passing the complete address with City, State and Zip. But the interesting part is, the GeoCoder does not always returns

Re: [android-developers] Android GeoCoder Issue

2011-01-07 Thread TreKing
On Fri, Jan 7, 2011 at 2:33 PM, Ankur Avlani ankuravl...@gmail.com wrote: Has anyone faced this issue?. Any help is highly appreciated. This is a known problem. Wrap your geocoding in a loop of say 5 or 10 attempts, sleeping() for a second or so in between each call. If it's valid, it should

Re: [android-developers] How to gracefully terminate a remote service process?

2011-01-07 Thread Dianne Hackborn
On Fri, Jan 7, 2011 at 12:23 PM, Frank Weiss fewe...@gmail.com wrote: This is a problem that the Google engineers have acknowledged. As you probably know, the issue is that the Android OS does delayed garbage collection of - and possibly reuses - dead porcesses, however the process name

[android-developers] Re: App Add-on

2011-01-07 Thread John Gaby
Thanks for the links, they were most helpful. I worry, however, that if I remove it from the Launcher that the user may not understand why it is not there, and may not be able to figure out how to launch it. I don't suppose that there is any way to remove it from the launcher after it has been

[android-developers] Re: How to interrupt a blocking I/O operation?

2011-01-07 Thread ivan
Tabman, I think that's the best idea yet, but I'm surprised the Apache classes don't offer some mechanism for manually interrupting the I/O blocks. After all, we can set timeouts on all of the I/O operations, which will interrupt the blocks with socket timeout exceptions etc. Thanks. On Jan 7,

Re: [android-developers] Re: App Add-on

2011-01-07 Thread TreKing
On Fri, Jan 7, 2011 at 2:46 PM, John Gaby jg...@gabysoft.com wrote: I don't suppose that there is any way to remove it from the launcher after it has been run? Don't think so. But if it's launch-able from the Market, you can display an Activity that explains this from there. If the user can't

[android-developers] Re: How to interrupt a blocking I/O operation?

2011-01-07 Thread Streets Of Boston
I was just using HttpClient (DefaultHttpClient from apache) and its 'execute(...)' method called in the background thread of an AsyncTask. It was properly interrupted when the AsyncTask was cancelled. On Jan 7, 3:17 pm, ivan istas...@gmail.com wrote: Were you using SingleClientConnManager or

Re: [android-developers] Re: Trying to get my head around multi screen densities. With more info

2011-01-07 Thread Dianne Hackborn
On Fri, Jan 7, 2011 at 10:32 AM, niko20 nikolatesl...@yahoo.com wrote: Hi, setting anyDensity to True tells android that YOU will be handling all density specifics, including supplying density specific graphics. In other words, it won't scale anything. Not really. The framework does a lot

[android-developers] Re: App Add-on

2011-01-07 Thread John Gaby
Honestly though, you're already heading down a user-experience nightmare path with this concept of add-on - seems like a simple concept but a lot of users simply won't get it. The ones that do will probably understand why it's missing. Good luck. I know. I really wish that Google had an

[android-developers] Re: Factory data reset - install app

2011-01-07 Thread Leon Moreyn-Android Development
Ummm, unless user backs up your app data I dont believe there is any way to actually auto install are factory reset. On Jan 6, 3:14 am, Hareef toar...@gmail.com wrote: Anyway to install App automatically when doing Factory Data Reset? Thanks in Advance -- You received this message because

[android-developers] Re: Prevent application - after Factory Data reset

2011-01-07 Thread Leon Moreyn-Android Development
Also maybe your app is the reason for the factory reset. IE Virus. On Jan 6, 3:14 am, Hareef toar...@gmail.com wrote: Factory Data reset will remove everything and uninstall the third party apps So, how can i prevent my app getting uninstalled? Thanks -- You received this message because

Re: [android-developers] Re: App Add-on

2011-01-07 Thread TreKing
On Fri, Jan 7, 2011 at 3:22 PM, John Gaby jg...@gabysoft.com wrote: I know. I really wish that Google had an in-app purchase mechanism like Apple (or would allow the use of 3rd party in-app purchasing like PayPal). Maybe I need to rethink this whole concept. Take a look at this thread:

[android-developers] Re: clicking a link on a website launches my application...

2011-01-07 Thread sdphil
hm... okay, so my web page looks like this: a href=myproto://www.myproto.comTest/a however, when I click on that on my phone's browser, it says Web page not available The Web page at myproto://www.myproto.com might be temporarily down or it may have in my AndroidManifest.xml file I

Re: [android-developers] Re: clicking a link on a website launches my application...

2011-01-07 Thread TreKing
On Fri, Jan 7, 2011 at 3:55 PM, sdphil phil.pellouch...@gmail.com wrote: so, what am I doing wrong? The browser will not be launching an intent with that action. Your action should probably be ACTION_VIEW.

[android-developers] Re: App Add-on

2011-01-07 Thread John Gaby
Thanks for the link, it really cleared things up (*NOT*). It was an interesting read, however. His situation is very similar to mine. I would like to sell 'virtual content' from within the game. The way Google is making me do it is absurd. On Jan 7, 1:35 pm, TreKing treking...@gmail.com

[android-developers] Re: clicking a link on a website launches my application...

2011-01-07 Thread sdphil
so you mean like this? intent-filter action android:name=android.intent.action.VIEW/ category android:name=android.intent.category.DEFAULT/ data android:scheme=myproto/ /intent-filter this gives the same thing... On Jan 7,

Re: [android-developers] Re: clicking a link on a website launches my application...

2011-01-07 Thread TreKing
On Fri, Jan 7, 2011 at 4:08 PM, sdphil phil.pellouch...@gmail.com wrote: so you mean like this? I do. this gives the same thing... Remove the action completely? Otherwise I don't know. -

Re: [android-developers] Re: clicking a link on a website launches my application...

2011-01-07 Thread Mark Murphy
FWIW, here is a sample project showing some of this stuff in action (though not using myproto): https://github.com/commonsguy/cw-advandroid/tree/master/Introspection/URLHandler On Fri, Jan 7, 2011 at 5:08 PM, sdphil phil.pellouch...@gmail.com wrote: so  you mean like this?            

Re: [android-developers] Re: clicking a link on a website launches my application...

2011-01-07 Thread Kostya Vasilyev
You also need to add category BROWSEABLE. -- Kostya Vasilyev -- http://kmansoft.wordpress.com 08.01.2011 1:11 пользователь TreKing treking...@gmail.com написал: On Fri, Jan 7, 2011 at 4:08 PM, sdphil phil.pellouch...@gmail.com wrote: so you mean like this? I do. this gives the same

Re: [android-developers] How to gracefully terminate a remote service process?

2011-01-07 Thread Moto
I guess my knowledge on the subject was not far off... I guess I was being mislead by all these task killers and users complaining... They just assume a visible process is hogging CPU and memory. Well it could on applications that aren't managing things properly. Thanks for your reply --

RE: [android-developers] Re: App Add-on

2011-01-07 Thread Tommy
Have you considered some kind of webportal with the use of paypal and using the webview control? Then using an external SQL server to manage your subscription for the add ons? -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On

Re: [android-developers] How to gracefully terminate a remote service process?

2011-01-07 Thread Moto
I kept telling my users I don't want to place an exit button cause it's pointless! If you program the application properly there is no need for an exit button on many type of applications such as mine, a media playback application. I explain users and some understand while other don't... --

[android-developers] HTTP parameter question

2011-01-07 Thread John Lussmyer
Does one of the HTTP support classes handle building a parameterized URL? i.e one of the sort http://a.com/stuff?a=bc=de=f Yes, I know writing one would be easy, but if there is already one out there... -- You received this message because you are subscribed to the Google Groups Android

[android-developers] Gingerbread BroadcastReceiver Issue

2011-01-07 Thread Jake Basile
My app, Hearing Saver, registers a BroadcastReceiver to get the ACTION_HEADSET_PLUGhttp://developer.android.com/reference/android/content/Intent.html#ACTION_HEADSET_PLUGaction. Because of a flag on this, the receiver cannot be registered via the AndroidManifest, so I need to keep a service

Re: [android-developers] How to gracefully terminate a remote service process?

2011-01-07 Thread Frank Weiss
I want to say thank you to Dianne Hackborn for correcting my mistaken assumption that an Android process could serially host different apps. I'll have to take some time to study how the Android OS manages processes and the DVK someday. -- You received this message because you are subscribed to

[android-developers] Hidden Activity?

2011-01-07 Thread Scott Deutsch
Hello group, I have a question for you all. I am trying to figure out a Downloadable Content system for my app I am developing. I already know that the DLC would be sold as a separate app on the Market place (since they don't support DLC yet). I want to get results back from polling an activity.

[android-developers] What type of messaging would you use?

2011-01-07 Thread Nathan
A client might have a use case for peer to peer or group sharing of location. Internet access, cell phone coverage not guaranteed. Wifi is available on a large private LAN. Users may have phones or more likely, tablets. A group of users are assigned a known key. User can periodically send their

Re: [android-developers] Gingerbread BroadcastReceiver Issue

2011-01-07 Thread Mark Murphy
Have you tried startForeground()? On Fri, Jan 7, 2011 at 5:41 PM, Jake Basile jakerbas...@gmail.com wrote: My app, Hearing Saver, registers a BroadcastReceiver to get the ACTION_HEADSET_PLUG action. Because of a flag on this, the receiver cannot be registered via the AndroidManifest, so I need

Re: [android-developers] Hidden Activity?

2011-01-07 Thread Mark Murphy
On Fri, Jan 7, 2011 at 5:52 PM, Scott Deutsch surger...@gmail.com wrote: I have a question for you all. I am trying to figure out a Downloadable Content system for my app I am developing. I already know that the DLC would be sold as a separate app on the Market place (since they don't support

Re: [android-developers] HTTP parameter question

2011-01-07 Thread Mark Murphy
On Fri, Jan 7, 2011 at 5:40 PM, John Lussmyer johnlussm...@gmail.com wrote: Does one of the HTTP support classes handle building a parameterized URL? i.e one of the sort http://a.com/stuff?a=bc=de=f Yes, I know writing one would be easy, but if there is already one out there...

Re: [android-developers] Hidden Activity?

2011-01-07 Thread Scott Deutsch
DLC = Downloadable Content When I said Polling an activity I meanstartActivityForResult() then use onActivityResult to grab the results Now when you do startActivity, a screen will appear. Now to your comment...I havent thought about a content provider or PackageManager. I would

Re: [android-developers] Hidden Activity?

2011-01-07 Thread Mark Murphy
On Fri, Jan 7, 2011 at 6:05 PM, Scott Deutsch surger...@gmail.com wrote: DLC = Downloadable Content When I said Polling an activity I meanstartActivityForResult() then use onActivityResult to grab the results Now when you do startActivity, a screen will appear. That's for the user to

Re: [android-developers] Hidden Activity?

2011-01-07 Thread Scott Deutsch
That's what I thought. Thanks. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to

[android-developers] DNS WHOIS query support

2011-01-07 Thread RAJ
Is there a android SDK API to get DNS name servers from given URL, using WHOIS query? Or We will have to implement our own code and parse to decode the response? Any links? thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to

[android-developers] Re: App Add-on

2011-01-07 Thread John Gaby
Actually, there are a number of ways that I could provide and in-app purchase mechanism, but I am TRYING not to violate Google's TOS. They are making it really hard, though. On Jan 7, 2:30 pm, Tommy droi...@gmail.com wrote: Have you considered some kind of webportal with the use of paypal and

[android-developers] Code Assist still Slow

2011-01-07 Thread Dan
After upgrading to ADT 8.0.1 with Eclipse Helios (3.6.1) I am still getting freezes with code assist. Does anyone have any ideas to fix or is this still a bug? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email

Re: [android-developers] DNS WHOIS query support

2011-01-07 Thread Mark Murphy
On Fri, Jan 7, 2011 at 6:25 PM, RAJ trra...@gmail.com wrote: Is there a android SDK API to get DNS name servers from given URL, using WHOIS query? Not that I am aware of. Or We will have to implement our own code and parse to decode the response? A simple Google search on: java whois

[android-developers] Protecting files on non-rooted phones

2011-01-07 Thread John Gaby
I find that, when using a actual device that is not rooted, that I cannot see the contents folders created by my application. However, if I know the exact name and path of a file, I CAN pull or push it using ADB. Is there a way to prevent external access to application files (on a non-rooted

Re: [android-developers] How to gracefully terminate a remote service process?

2011-01-07 Thread Dianne Hackborn
On Fri, Jan 7, 2011 at 2:29 PM, Moto medicalsou...@gmail.com wrote: I guess my knowledge on the subject was not far off... I guess I was being mislead by all these task killers and users complaining... They just assume a visible process is hogging CPU and memory. Well it could on

Re: [android-developers] Protecting files on non-rooted phones

2011-01-07 Thread Dianne Hackborn
On a user build, adb can not access any application files, with these exceptions: - If the app has declared itself debuggable, recent versions of android will allow the shell user to change to run as that app uid and thus access its files. - If you create files that are explicitly marked as world

Re: [android-developers] Hidden Activity?

2011-01-07 Thread Dianne Hackborn
Just look for the other package by name with the package manager. Ensure its cert is the one you expect to it can't be spoofed. If you want it to cary data about what features you are enabling or whatever, you can use meta-data tags under the application to supply whatever you want. On Fri, Jan

Re: [android-developers] Hidden Activity?

2011-01-07 Thread Scott Deutsch
Thanks for that info, didn't think about that. So, that means the DLC app would do nothing which means you hide the icon on the app list and only contain META-DATA tags in the manifest and the main app would just read the other programs manifest looking for those meta-data tagsinteresting,

Re: [android-developers] Gingerbread BroadcastReceiver Issue

2011-01-07 Thread Jake Basile
I have considered it, but it's not really what I'm looking for so I didn't try it. This service shouldn't be in the foreground, and the exact same code didn't need to be to work in previous versions. I don't think the service is getting killed because my onDestroy is not called and the service

Re: [android-developers] HTTP parameter question

2011-01-07 Thread John Lussmyer
I don't think you understood my question. Given a list of key-value pairs, is there a utility class to build the ?key=valuekey=valuekey=value string. On Fri, Jan 7, 2011 at 3:00 PM, Mark Murphy mmur...@commonsware.com wrote: On Fri, Jan 7, 2011 at 5:40 PM, John Lussmyer

Re: [android-developers] Gingerbread BroadcastReceiver Issue

2011-01-07 Thread Mark Murphy
On Fri, Jan 7, 2011 at 7:54 PM, Jake Basile jakerbas...@gmail.com wrote: This service shouldn't be in the foreground Ambling Book Player works fine with the headset plug on my Nexus S, and I'm reasonably certain that app uses startForeground(). I'm just suggesting you give it a shot. It's a

Re: [android-developers] HTTP parameter question

2011-01-07 Thread Brad Gies
I'm not 100% sure I understand the question either but just in case...this does it for a Post... and switching to a Get will do the same thing. HttpPost httpPost = new HttpPost(urlString); ListNameValuePair nvps = new ArrayListNameValuePair(); nvps.add(new BasicNameValuePair(akey,

Re: [android-developers] HTTP parameter question

2011-01-07 Thread John Lussmyer
Except that you can't setEntity() on an HttpGet - which is what I need to use. On Fri, Jan 7, 2011 at 5:27 PM, Brad Gies rbg...@gmail.com wrote: I'm not 100% sure I understand the question either but just in case...this does it for a Post... and switching to a Get will do the same thing.

[android-developers] Re: Protecting files on non-rooted phones

2011-01-07 Thread John Gaby
I must be setting the files as world readable then. I didn't know that if the app was debuggable that you could change the shell to run as an app uid. Can you tell me what version of Android that works for, and how I do that? Thanks. On Jan 7, 4:25 pm, Dianne Hackborn hack...@android.com

[android-developers] Re: Can't Uninstall

2011-01-07 Thread nextgen
OK, and the final answer is ... You are right! It is an installed app. Turns out after some more research, Verizon has started including an app as part of the system image that has similar keywords to ours. The user tries to uninstall it and can't. So the user goes to the Market App, finds our

Re: [android-developers] Re: Can't Uninstall

2011-01-07 Thread Dianne Hackborn
What do you mean by similar keywords? Is it that the app label the user sees is the same? Hopefully they don't both have the same package name. On Fri, Jan 7, 2011 at 5:59 PM, nextgen nextgenfant...@comcast.net wrote: OK, and the final answer is ... You are right! It is an installed app.

Re: [android-developers] Re: Protecting files on non-rooted phones

2011-01-07 Thread Dianne Hackborn
Unfortunately I don't recall exactly when it went in. Maybe 2.3? It is the run-as command. On Fri, Jan 7, 2011 at 5:42 PM, John Gaby jg...@gabysoft.com wrote: I must be setting the files as world readable then. I didn't know that if the app was debuggable that you could change the shell to

Re: [android-developers] Gingerbread BroadcastReceiver Issue

2011-01-07 Thread Jake Basile
I'll check it out shortly. If it happens to fix it I might include it as an optional workaround. As to onDestroy not always being called, where's the source for that? The documentationhttp://developer.android.com/guide/topics/fundamentals.html#servlifeseems to indicate it is always called.

Re: [android-developers] XML document parsing using the DOM API

2011-01-07 Thread Ajay Prabandham
oops my sincere apologies for cluttering android space with this queryin fact, i am new to Java as well, so did not realize this is a Java issue. Will check the Java API documentation. Thanks for redirecting me. Regards, Ajay -- You received this message because you are

Re: [android-developers] HTTP parameter question

2011-01-07 Thread TreKing
On Fri, Jan 7, 2011 at 4:40 PM, John Lussmyer johnlussm...@gmail.comwrote: Yes, I know writing one would be easy, but if there is already one out there... Not only is it easy - you could have written it by now. Hell you could have written it faster than your original email =P

[android-developers] Drawing on a canvas like normal VS OpenGl

2011-01-07 Thread brian purgert
So I was just wondering is openGL better in terms of making a 2dgame. does it render faster then if I were to draw on a Canvas -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to

Re: [android-developers] HTTP parameter question

2011-01-07 Thread John Lussmyer
Quite possibly, but if there is a standard one that comes with the system, i'd rather use. Since it appears that there isn't one, I'll write one. On Fri, Jan 7, 2011 at 7:42 PM, TreKing treking...@gmail.com wrote: On Fri, Jan 7, 2011 at 4:40 PM, John Lussmyer johnlussm...@gmail.comwrote: Yes,

[android-developers] Re: Disable Antenna

2011-01-07 Thread Bob Kerns
Please consult your dentist before attempting this. Or hire a hamster. On Jan 5, 10:10 am, Byron Penner bapenner...@gmail.com wrote: I'm putting my vote on chewing it off! On Jan 5, 12:06 am, Julius Spencer jul...@msa.co.nz wrote: -- You received this message because you are subscribed to

[android-developers] Re: Protecting files on non-rooted phones

2011-01-07 Thread John Gaby
Thanks for the tip. For the record, it works on 2.2. There have been a number of times that I have wanted to be able to see the files for my app, and I am glad to find that there is a way. Thanks again. On Jan 7, 6:55 pm, Dianne Hackborn hack...@android.com wrote: Unfortunately I don't recall

Re: [android-developers] Gingerbread BroadcastReceiver Issue

2011-01-07 Thread Dianne Hackborn
Please keep in mind, if you don't use startForeground(), your service is not critical, and its process *will* get killed occasionally in the background. Depending on how you have coded the service (what you return from onStartCommand()) it will or will not be restarted after its process is

[android-developers] Re: How to access mail ?

2011-01-07 Thread Bob Kerns
On Jan 7, 5:16 am, Mark Murphy mmur...@commonsware.com wrote: On Fri, Jan 7, 2011 at 2:30 AM, Bob Kerns r...@acm.org wrote: You forgot the battery of permissions, one per email app, needed to give users control over what app/spyware can receive these broadcasts. Otherwise, though, you're

[android-developers] Re: How to interrupt a blocking I/O operation?

2011-01-07 Thread Bob Kerns
Tabman's answer might possibly be what you're looking for -- but the more general answer I'd give would be: You can't, and you generally don't need to. What are you really trying to do? Most of the times that people think they want to abort waiting IO, that's really not what they need. It's

Re: [android-developers] Gingerbread BroadcastReceiver Issue

2011-01-07 Thread Jake Basile
I assumed it would get killed and attempted to design around that so that it gets restarted. I return START_STICKY onStartCommand, which I interpreted as meaning it will be restarted after it is killed. Is that incorrect? What can be returned from onStartCommand that can cause onDestroy() to

[android-developers] Re: Making cross-thread blocking/sync calls

2011-01-07 Thread Bob Kerns
Assuming there may actually be data to be transferred (or you invent some), you can use an ArrayBlockingQueue. Otherwise, wait()/notify() is a good choice, but you need to be careful to handle the case that the UI thread does the notify before you get into the wait() code. The usage pattern

[android-developers] Re: Prevent application - after Factory Data reset

2011-01-07 Thread Bob Kerns
Be nice to your users, making your application such an integral part of their lives that they would never DREAM of doing a factory reset -- for fear of losing your app and ruining their lives forever. Other than that, if you're an IT department wanting to make sure your corporate apps aren't lost

<    1   2