[android-developers] Re: How do I pass data between differentActivity/Process?
You can see below demo code: Intent tIntent = new Intent(); tIntent.setClassName(SKIP_PATH, SKIP_PATH_NAME); Bundle tBundle = new Bundle(); tBundle.putCharSequence(request, secondRequest.toString()); tIntent.putExtras(tBundle); startActivity(tIntent); [EMAIL PROTECTED] 2008年10月27日 - Original Message - From: Dikers To: Android Developers Sent: 2008-10-27, 14:11:03 Subject: [android-developers] How do I pass data between differentActivity/Process? Example: activity android:name=TestActivity android:theme=@android:style/ Theme.Dialog android:multiprocess=true intent-filter action android:name=android.intent.action.VIEW / category android:name=android.intent.category.DEFAULT / /intent-filter /activity I start many activities with different processes(android:multiprocess=true), Now how do I pass data between these activities? 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How do I pass data between differentActivity/Process?
Thank you! On Oct 27, 2:17 pm, dailyLife[EMAIL PROTECTED] wrote: You can see below demo code: Intent tIntent = new Intent(); tIntent.setClassName(SKIP_PATH, SKIP_PATH_NAME); Bundle tBundle = new Bundle(); tBundle.putCharSequence(request, secondRequest.toString()); tIntent.putExtras(tBundle); startActivity(tIntent); [EMAIL PROTECTED] 2008年10月27日 - Original Message - From: Dikers To: Android Developers Sent: 2008-10-27, 14:11:03 Subject: [android-developers] How do I pass data between differentActivity/Process? Example: activity android:name=TestActivity android:theme=@android:style/ Theme.Dialog android:multiprocess=true intent-filter action android:name=android.intent.action.VIEW / category android:name=android.intent.category.DEFAULT / /intent-filter /activity I start many activities with different processes(android:multiprocess=true), Now how do I pass data between these activities? 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Fonts in XML
Hey developers, I have a TTF in my assets/fonts directory I can use in TextViews from within code following the API example. That is great for one-offs, but what I really want to do is to use this font in a style, and the reference that style from a layout. Broken example: !-- styles.xml -- ?xml version=1.0 encoding=utf-8? resources style name=Title item name=android:textSize24sp/item item name=android:typefacefonts/myfont.ttf/item /style /resources !-- layout.xml -- LinearLayout xmlns:android=http://schemas.android.com/apk/res/ android android:orientation=vertical android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/title style=@style/Title android:layout_width=fill_parent android:layout_height=wrap_content / /LinearLayout This would allow me to reuse the same style (including font) without having to do it in code. Anyone have any ideas how to make this work? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How do I pass data between differentActivity/Process?
Sorry I didn't clear my problem, so you misunderstand my means. For Example: I have five activities in different process, then I want to start a service to manager these activities. In the service , user can send a message to stop/finish a given activities. How do I pass data between these activity and service? Thank you! On Oct 27, 2:30 pm, Dikers [EMAIL PROTECTED] wrote: Thank you! On Oct 27, 2:17 pm, dailyLife[EMAIL PROTECTED] wrote: You can see below demo code: Intent tIntent = new Intent(); tIntent.setClassName(SKIP_PATH, SKIP_PATH_NAME); Bundle tBundle = new Bundle(); tBundle.putCharSequence(request, secondRequest.toString()); tIntent.putExtras(tBundle); startActivity(tIntent); [EMAIL PROTECTED] 2008年10月27日 - Original Message - From: Dikers To: Android Developers Sent: 2008-10-27, 14:11:03 Subject: [android-developers] How do I pass data between differentActivity/Process? Example: activity android:name=TestActivity android:theme=@android:style/ Theme.Dialog android:multiprocess=true intent-filter action android:name=android.intent.action.VIEW / category android:name=android.intent.category.DEFAULT / /intent-filter /activity I start many activities with different processes(android:multiprocess=true), Now how do I pass data between these activities? 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] browse localhost using android emulator
Hi all, I am using Apache server with port 80 as localhost. Google Chrome can access that localhost, but Android emulator failed (saying the web page might be temporarily down or moved). Do I need to do some setting some where in order to make it work? TIA --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] application version retrieval
how can i read current application version? i mean value stored in manifest file for android:versionCode and android:versionName so far i tried to find some api for it in Application or Context, but i didn't found any. also i didn't found it in android.R. resource identifier (or in R.) so i don't know what to try next --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
If you still insist on using a single activity I don't insist on anything :-) I just want to talk about it. And speaking of state, I don't think you want to be using setContentView() to change views, even within a single application. Changing content views for your application will mean the built-in state management will fail. Consider if the users receives a phone call, switches task via notification, or hits the home button. If your activity is closed due to memory constraints, its last saved state may not match the view when your application restarts. Your application will appear broken to a user, loosing state if they multitask. It is sure that if I use setContentView(view), I have according boolean variables that tell which view is active at the moment. All other view variables are set to inactive/ false then. If I store these variables during onPause(), everything gets restored like it should, when the Activity is about to restart again. Of course the last state has to be saved properly, but that's the same if you take lots of single Activities, just more variables maybe. I have successfully done this approach for Applets. The intent/ multiple-activity pattern is just unfamiliar to me. I agree, but as I have understood, freeing up memory would mean that the particular acivity is entirely shut down. The system would do that only if it is absolutely necessary. I doubt if the rest of the application continues working fine in that case. If the appropriate state is saved during onPause(), why wouldn't the rest of the application work when an activity is shut down. I have meant it other way. (As far as I have understood the concept,) freeing up memory would mean, that the Activity is entirely destroyed and onDestroy() gets passed. I suppose, that this happens only if the system is really overexerted (or if the activity isn't used for long time). If the G1 (as it is a strong device compared to others) really gets out of memory, I don't think that it makes a large difference if you destroy a part of your Application you don't use anymore. Maybe for some special cases it does. Going out of memory would mean, A.) that the resources of your actually running Activity are too heavy-weight or B.) you have dozens of passive Activities which aren't destroyed. For the first case, it would make more sense to try making the actual Activity more efficient (and freeing up memory manually). For the second case, I think, there would be a remarkable performance loss BEFORE the tons of non-used Activities are finally being destroyed. Therefore maybe it is even better to quit the whole application and taking steps to destroy the non-used Activities. That's only my theory I know :-) Hope I get some comments for it. Robert --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: T-mobile G1 for testing purposes
Sorry Timbobsteve, I just realized I made a mistake in my previous email: I wrote free device but I did'nt mean free of charge but free of lock, unlocked. I realize it was quite stupid, sorry for my english. My concern is that in my country Android is not going to come until 2009 and I would like to buy a G1 in USA but I don't know if the ones that they sell in T-Mobile stores are unlocked or not. I know that the full price is 399 but will I be able to use the device abroad, with mi SIM? Can you explain me more about the 90 days unlock? I mean, if I came to the USA and I buy a G1 how can I unlock it after 90 days? Is the unlock something like a software update or it is a physical modification? Thank you very much! AB On Oct 24, 10:57 am, Timbobsteve [EMAIL PROTECTED] wrote: What I don't understand is why people are deluded enough to think that they should get one of these devices for free? I would like to develop programs for Windows, PSP and Nintendo DS Should I get free consoles and a new PC as a result? No... that would be ludicrous. I have to pay for the devices just like everyone else. My guess is that you may be able to get these devices straight from HTC, if you have some sort of developer connection (and if they support that kind of setup)... otherwise you have to buy into the contract like everyone else. There is always the option to get the contract and after 90 days, request the phone be unlocked. From what I hear T-Mobile are quite good with that kind of thing and usually oblige. My 2 cents... I'm now off to find some free donuts and free coffee and enjoy a free trip to the premier of Quantum of Solace. Ale wrote: Hi guys, I'm wondering whether for strangers it will be possible to buy the G1 and use it abroad for testing (and for enjoing Android ;) ). I read that the device can be bought at full price 399$ but I think that it will be unlocked.. Any idea on how to get a free device for testing purposes? Thank you in advance!!! AB --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Allocation too large for this process
Easier said than done. An end-user of my app immediately got an OutOfMemoryError on a real G1 (not the emulator) when capturing just s single image from the camera at 2048 x 1536, the only specified resolution that I could find on the web for the T-Mobile G1. Do you know of any lower still image resolutions supported by the G1, Romain? Thanks! On Oct 27, 4:15 am, Romain Guy [EMAIL PROTECTED] wrote: Use less memory in your application :) On Sun, Oct 26, 2008 at 7:54 PM, Tim [EMAIL PROTECTED] wrote: suffer to the same issue, out of memory :( --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How do I pass data between different Activity/Process?
Example: activity android:name=TestActivity android:theme=@android:style/ Theme.Dialog android:multiprocess=true intent-filter action android:name=android.intent.action.VIEW / category android:name=android.intent.category.DEFAULT / /intent-filter /activity I start many activities with different processes(android:multiprocess=true), Now how do I pass data between these activities? 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: T-mobile G1 for testing purposes
I must apologize for my rudeness. It was an unhappy Friday and I was/am terrified that the Android community will begin to emulate the iPhone development community (e.g. expect everything for free and ASAP). I now see that you meant a SIM-Lock "free" device for testing :P There is always the option to get one off eBay, or perhaps talk to HTC directly letting them know that you are an Android dev wanting a device for testing. Best of luck. Timbobsteve. Ale wrote: Sorry Timbobsteve, I just realized I made a mistake in my previous email: I wrote free device but I did'nt mean free of charge but free of lock, unlocked. I realize it was quite stupid, sorry for my english. My concern is that in my country Android is not going to come until 2009 and I would like to buy a G1 in USA but I don't know if the ones that they sell in T-Mobile stores are unlocked or not. I know that the full price is 399 but will I be able to use the device abroad, with mi SIM? Can you explain me more about the 90 days unlock? I mean, if I came to the USA and I buy a G1 how can I unlock it after 90 days? Is the unlock something like a software update or it is a physical modification? Thank you very much! AB On Oct 24, 10:57am, Timbobsteve [EMAIL PROTECTED] wrote: What I don't understand is why people are deluded enough to think that they should get one of these devices for free? I would like to develop programs for Windows, PSP and Nintendo DS Should I get free consoles and a new PC as a result? No... that would be ludicrous. I have to pay for the devices just like everyone else. My guess is that you may be able to get these devices straight from HTC, if you have some sort of developer connection (and if they support that kind of setup)... otherwise you have to buy into the contract like everyone else. There is always the option to get the contract and after 90 days, request the phone be unlocked. From what I hear T-Mobile are quite good with that kind of thing and usually oblige. My 2 cents... I'm now off to find some free donuts and free coffee and enjoy a free trip to the premier of Quantum of Solace. Ale wrote: Hi guys, I'm wondering whether for strangers it will be possible to buy the G1 and use it abroad for testing (and for enjoing Android ;) ). I read that the device can be bought at full price 399$ but I think that it will be unlocked.. Any idea on how to get a free device for testing purposes? Thank you in advance!!! AB --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: T-mobile G1 for testing purposes
This is an excellent question. T-Mobile isn't in my country as well. There are some rumors it will come, but nothing official yet. So will there be a legitimate way to get an Android phone that will work with our own SIM cards? Thanks, Teo On Oct 27, 10:33 am, Ale [EMAIL PROTECTED] wrote: Sorry Timbobsteve, I just realized I made a mistake in my previous email: I wrote free device but I did'nt mean free of charge but free of lock, unlocked. I realize it was quite stupid, sorry for my english. My concern is that in my country Android is not going to come until 2009 and I would like to buy a G1 in USA but I don't know if the ones that they sell in T-Mobile stores are unlocked or not. I know that the full price is 399 but will I be able to use the device abroad, with mi SIM? Can you explain me more about the 90 days unlock? I mean, if I came to the USA and I buy a G1 how can I unlock it after 90 days? Is the unlock something like a software update or it is a physical modification? Thank you very much! AB On Oct 24, 10:57 am, Timbobsteve [EMAIL PROTECTED] wrote: What I don't understand is why people are deluded enough to think that they should get one of these devices for free? I would like to develop programs for Windows, PSP and Nintendo DS Should I get free consoles and a new PC as a result? No... that would be ludicrous. I have to pay for the devices just like everyone else. My guess is that you may be able to get these devices straight from HTC, if you have some sort of developer connection (and if they support that kind of setup)... otherwise you have to buy into the contract like everyone else. There is always the option to get the contract and after 90 days, request the phone be unlocked. From what I hear T-Mobile are quite good with that kind of thing and usually oblige. My 2 cents... I'm now off to find some free donuts and free coffee and enjoy a free trip to the premier of Quantum of Solace. Ale wrote: Hi guys, I'm wondering whether for strangers it will be possible to buy the G1 and use it abroad for testing (and for enjoing Android ;) ). I read that the device can be bought at full price 399$ but I think that it will be unlocked.. Any idea on how to get a free device for testing purposes? Thank you in advance!!! AB --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
What I really don't like about it for example is that everytime I want to add a new activity, I have to change the Manifest.xml in addition. Then, a 'Resource is out of sync' message appears, sometimes till I restart the computer...that's really annoying... Sometimes resources don't get updated automatically in Eclipse. This seems to be a bug. But instead of restarting your computer, in Eclipse it is sufficient to choose Project / Clean Unless you have strong reasons to combine everything in a single activity (large amount of shared data, require animation between activities, ...) in the long run you will be better off by using the mechanisms provided by the framework. Note that the G1 is only the first device. I'm just phantasizing now, but what if a future device features not only a back button, but also a forward button to switch between activities? If you had hard- coded the back button functionality, the forward button would fail in your application. If you handed the logics to the framework, everything would work fine, also in the future. PS: It may seem strange and novel at first, but the intent passing mechanism is really powerful, in the sense that part of your applications can be reused or replaced by other applications if they agree on the intents. Have a look at our intent registry: http://www.openintents.org/en/intentstable Peli www.openintents.org --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: application version retrieval
/** * Get current version number. * * @return */ private String getVersionNumber() { String version = ?; try { PackageInfo pi = getPackageManager().getPackageInfo(getPackageName(), 0); version = pi.versionName; } catch (PackageManager.NameNotFoundException e) { Log.e(TAG, Package name not found, e); }; return version; } Peli www.openintents.org On Oct 27, 8:36 am, Selmi [EMAIL PROTECTED] wrote: how can i read current application version? i mean value stored in manifest file for android:versionCode and android:versionName so far i tried to find some api for it in Application or Context, but i didn't found any. also i didn't found it in android.R. resource identifier (or in R.) so i don't know what to try next --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: HTTP proxy, android.net.Proxy, Android 1.0
After digging around a bit more I found this thread: http://groups.google.com/group/android-developers/msg/d8cb5935a609b8cc That indicates that the Android Proxy class is (or at least was) for use in setting settings for the built in browser. I personally hadn't thought about a device wide settings type proxy that I should be incorporating to my own apps if it's there, but now that you bring it up (if that's what you are trying to do - handle a proxy at run time if it's set, not one you know about beforehand), we all probably should be. That said, you are also correct that the Android Proxy class has no concept of user/pass credentials. In that case if you really want to accommodate for it, you probably need to use that Android Proxy (as you are) AND at the moment allow the user to set the username and password in some kind of settings screen in your own app, if the Android Proxy is set (if you find host/port in the Android Proxy, only then ask them for user pass once in your own app). That is the only way I can think of to handle all the possibilities at the moment. Maybe some Googlers will chime in here and help? It's great that the device wide proxy is there, a sort of global setting (the Android Proxy), but if it doesn't have user and pass it's really only half- baked? (And I haven't accommodated for it yet in my apps at all, should I be doing so, should everyone?) -- As a side note, if you did know the host, port, and user and pass, you can USE a KNOWN proxy just like the HttpClient examples demonstrate: DefaultHttpClient httpclient = new DefaultHttpClient(); httpclient.getCredentialsProvider().setCredentials( new AuthScope(localhost, 8080), new UsernamePasswordCredentials(username, password)); HttpHost targetHost = new HttpHost(www.verisign.com, 443, https); HttpHost proxy = new HttpHost(localhost, 8080); httpclient.getParams().setParameter (ConnRoutePNames.DEFAULT_PROXY, proxy); HttpGet httpget = new HttpGet(/); On Oct 26, 6:49 pm, Sean Sullivan [EMAIL PROTECTED] wrote: android.net.Proxy has four static methods: getDefaultHost getDefaultPort getHost(Context) getPort(Context) According to the javadocs: - (getDefaultHost, getDefaultPort) are for a carrier proxy - (getHost, getPort) are for a user specified proxy I'm looking for methods that will return the user specified proxy username and password. I looked at the source code for android.net.Proxy and I don't see any methods for retrieving the username or password: http://git.source.android.com/?p=platform/frameworks/base.git;a=blob;... Are there other API's that I should be looking at? android.net.ConnectivityManager looked promising but I did not see any methods for retrieving proxy configuration: http://code.google.com/android/reference/android/net/ConnectivityMana... android.net.http.AndroidHttpClient doesn't seem to help either. The source code doesn't reveal how Android handles proxies: http://git.source.android.com/?p=platform/frameworks/base.git;a=blob;... Sean On Oct 26, 3:32 pm, Charlie Collins [EMAIL PROTECTED] wrote: I believe the android.net.Proxy class is intended to be used for default carrier proxies, which don't require credentials (but rather use the fact that the device is on the private carrier network as auth) not for connecting through your own proxy server with authentication. You should be able to do your own proxy stuff though, with credentials, using the straight up HttpClient classes - looks like you are almost there. Check out the HttpClient 4 examples. http://hc.apache.org/httpcomponents-client/examples.html This specific example should work on Android, all these classes are there (or so it appears from a quick glance):http://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk/modul... --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: T-mobile G1 for testing purposes
There are more Android phones coming on other service providers. For now, the emulator should be fine until one of the other phones comes out. Sprint has been waffling on it, saying they will have Android phones soon but at the same time saying Android isn't good enough yet (I think they mean it's not big enough yet for them to invest into) so just hold tight, they're coming, and they will be big :) On Oct 27, 4:20 am, Teo [EMAIL PROTECTED] wrote: This is an excellent question. T-Mobile isn't in my country as well. There are some rumors it will come, but nothing official yet. So will there be a legitimate way to get an Android phone that will work with our own SIM cards? Thanks, Teo On Oct 27, 10:33 am, Ale [EMAIL PROTECTED] wrote: Sorry Timbobsteve, I just realized I made a mistake in my previous email: I wrote free device but I did'nt mean free of charge but free of lock, unlocked. I realize it was quite stupid, sorry for my english. My concern is that in my country Android is not going to come until 2009 and I would like to buy a G1 in USA but I don't know if the ones that they sell in T-Mobile stores are unlocked or not. I know that the full price is 399 but will I be able to use the device abroad, with mi SIM? Can you explain me more about the 90 days unlock? I mean, if I came to the USA and I buy a G1 how can I unlock it after 90 days? Is the unlock something like a software update or it is a physical modification? Thank you very much! AB On Oct 24, 10:57 am, Timbobsteve [EMAIL PROTECTED] wrote: What I don't understand is why people are deluded enough to think that they should get one of these devices for free? I would like to develop programs for Windows, PSP and Nintendo DS Should I get free consoles and a new PC as a result? No... that would be ludicrous. I have to pay for the devices just like everyone else. My guess is that you may be able to get these devices straight from HTC, if you have some sort of developer connection (and if they support that kind of setup)... otherwise you have to buy into the contract like everyone else. There is always the option to get the contract and after 90 days, request the phone be unlocked. From what I hear T-Mobile are quite good with that kind of thing and usually oblige. My 2 cents... I'm now off to find some free donuts and free coffee and enjoy a free trip to the premier of Quantum of Solace. Ale wrote: Hi guys, I'm wondering whether for strangers it will be possible to buy the G1 and use it abroad for testing (and for enjoing Android ;) ). I read that the device can be bought at full price 399$ but I think that it will be unlocked.. Any idea on how to get a free device for testing purposes? Thank you in advance!!! AB- Hide quoted text - - Show quoted text - --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Fastest Combination of Http Post/Get and XML parsing libs
According to me, the fastest combo is to use HttpClient + SAX. SAX: encouraged by the android team, they discourage the use of XmlPullParser unless we import KXml in our source tree and use this implementation. With HttpClient, you can reuse the same socket (keepalive) to make several requests one after another, so I guess it's more efficient than UrlConnection API. On Oct 26, 7:57 pm, Christine [EMAIL PROTECTED] wrote: I use httpClient, which is built into the Android. I see no performance problem there. I use DOM for xml parsing, for just very small replies from a server, no performance problems there. I would like to have an alternative for DOM, just 'cause I don't like it. Elsewhere I use Xstream which I like a lot, haven't tried that on android. Promise you I will though. Christine On Oct 26, 4:32 am, Casey Link [EMAIL PROTECTED] wrote: Hello, My Application is consuming some remote REST services. Currently I am using java.net.HttpURLConnection to make the POST/GET requests, and javax.xml.parsers.DocumentBuilder, org.w3c.dom to parse the XML results. I don't have any hard numbers, but it is very slow in the emulator. The main bottleneck seems to be the DOM parsing routines. Is there a recommended/preferred/faster way of making POST/GET requests, and parsing XML in the android? Casey Link --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: browse localhost using android emulator
You must not use the name localhost but a weird NAT address 10.0.2.2 http://code.google.com/android/reference/emulator.html#emulatornetworking If you want to use hostnames you must also install a DNS server because the hosts file cannot be modiied. Anders On Oct 27, 8:34 am, mushimi [EMAIL PROTECTED] wrote: Hi all, I am using Apache server with port 80 as localhost. Google Chrome can access that localhost, but Android emulator failed (saying the web page might be temporarily down or moved). Do I need to do some setting some where in order to make it work? TIA --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Help_Appreciated: Sample code for getting data from a web server
The common way is to use something like a web-service. It can be as simple as sending an HTTP get to http//example.com/mydbapp?item=45 which should return data in a shape that your local app understands which can be XML JSOn or custome good luck! Anders On Oct 24, 9:17 pm, Armanda Lewis [EMAIL PROTECTED] wrote: I apologize if this has already been asked, but I am looking for sample code for how to make a call and retrieve info from a web server. I have my PHP/MySql script running, but don't know how to make Android get access to my database on my server. Thanks in advance!!! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: browse localhost using android emulator
Or use you're machines LAN IP if you're firewall allows. Al. Anders Rundgren wrote: You must not use the name localhost but a weird NAT address 10.0.2.2 http://code.google.com/android/reference/emulator.html#emulatornetworking If you want to use hostnames you must also install a DNS server because the hosts file cannot be modiied. Anders On Oct 27, 8:34 am, mushimi [EMAIL PROTECTED] wrote: Hi all, I am using Apache server with port 80 as localhost. Google Chrome can access that localhost, but Android emulator failed (saying the web page might be temporarily down or moved). Do I need to do some setting some where in order to make it work? TIA -- Al Sutton W: www.alsutton.com B: alsutton.wordpress.com T: twitter.com/alsutton --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Start Service when phone power up
Hi, after i read some posts here in forum, i'm able to start my program when phone power up. But i need to start a Service, in this case, the service is a notification, just for testing. Here is my code. package com.test.StartupTest; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.widget.Toast; public class TesteStartup extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { Toast.makeText(context, Test to see if this works,Toast.LENGTH_LONG).show(); //Start explicitly a Service that show in Notification bar a message context.startService(new Intent(context, NotifyInfoUser.class)); } } and the NotifyInfoUser.java: package com.test.StartupTest; import com.test.R; import android.app.Notification; import android.app.NotificationManager; import android.app.PendingIntent; import android.app.Service; import android.content.Intent; import android.os.IBinder; public class NotifyInfoUser extends Service{ private NotificationManager mNM; private static int MOOD_NOTIFICATIONS = R.layout.main; @Override public void onCreate() { mNM = (NotificationManager) getSystemService(NOTIFICATION_SERVICE); } @Override public void onStart(Intent intent, int startId) { super.onStart(intent, startId); showNotification(R.drawable.online_connected, Connected); } private void showNotification(int moodId, CharSequence text) { // Set the icon, scrolling text and timestamp. // Note that in this example, we pass null for tickerText. We update the icon enough that // it is distracting to show the ticker text every time it changes. We strongly suggest // that you do this as well. (Think of of the New hardware found or Network connection // changed messages that always pop up) Notification notification = new Notification(moodId, Client Started, System.currentTimeMillis()); // The PendingIntent to launch our activity if the user selects this notification //I guess putting null in Intent(this,null) can be crashing PendingIntent contentIntent = PendingIntent.getActivity(this, 0, new Intent(this, null), 0); // Set the info for the views that show in the notification panel. notification.setLatestEventInfo(this, null, text, contentIntent); // Send the notification. // We use a layout id because it is a unique number. We use it later to cancel. mNM.notify(MOOD_NOTIFICATIONS, notification); } @Override public void onDestroy() { // Cancel the persistent notification. mNM.cancel(MOOD_NOTIFICATIONS); } @Override public IBinder onBind(Intent intent) { return null; } } and finally my manifest ?xml version=1.0 encoding=utf-8? manifest xmlns:android=http://schemas.android.com/apk/res/android; package=com.test android:versionCode=1 android:versionName=1.0.0 uses-permission android:name=android.permission.RECEIVE_BOOT_COMPLETED / application android:icon=@drawable/icon android:label=@string/ app_name receiver android:name=.StartupTest.TesteStartup intent-filter action android:name=android.intent.action.BOOT_COMPLETED / category android:name=android.intent.category.LAUNCHER / /intent-filter /receiver service android:name=.StartupTest.NotifyInfoUser/ /application /manifest When phone power up, the screen with This app execute a ilegal operation, etc appear. When i comment the startService, the Toast appear in screen. So, what is wrong with the context.startService? thanks a lot Breno --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
I'm just phantasizing now, but what if a future device features not only a back button, but also a forward button to switch between activities? If you had hard- coded the back button functionality, the forward button would fail in your application. Such a button is not implemented in the actual SDK. If it causes trouble, you might need to re-build your software with the future SDK, where the 'forward' button is contained (even if you handed the logics to the framework). Compared to Java, it would be quite the same as if you write code with the standard library dealing with keyboard and mouse input, and one day maybe the joystick is also included to the standard libraries in a newer SDK. The application you wrote with the old SDK wouldn't adapt by itself to the joystick input, but you have to rewrite your code in the new version SDK. A new 'forward' button would be a very similar case. On the other hand I don't think this would be a problem. I just change the functionality of the 'back' button when it is necessary, so that it doesn't jump out of the application, but returns to the last view or menu for example. All the other button functionalities remain the same, as designed by default. If you press 'home', it still returns to desktop, and an imaginable forward button would do what it always does (it may leave my application though, as it is only one activity). It may seem strange and novel at first, but the intent passing mechanism is really powerful, in the sense that part of your applications can be reused or replaced by other applications if they agree on the intents. Yes, i agree. But the question is, if it makes sense that a special screen of your application is used by foreign applications. There are lots of cases, where it is not considerable to use it outside of the original one. Anyway, if this part is generally useful and if it makes sense to deploy it for the outside, then I fully agree in using Activities for that. But if the single views of the application (especially if there are more than 10 pieces, for example) is only needed for this particular application, then it is different. I have taken a look on the Intent and Activity class sources...these definitely belong to the most heavy-weight ones of the entire framework. So I doubt if it makes sense to use Activity by Activity for each single screen. I think, Activities are useful, but not for universal purpose. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Fonts in XML
I raised this on the forums a little while ago and found out it isn't supported in 1.0. Seeing your post reminded me that I didn't subsequently file an RFE, so I just wrote this: http://code.google.com/p/android/issues/detail?id=1087 It lists some possible workarounds that you might find useful. My proposal is probably a big change, but wouldn't (I think) cause any backward incompatibility with the 1.0 release. Tom. 2008/10/27 PAS [EMAIL PROTECTED] Hey developers, I have a TTF in my assets/fonts directory I can use in TextViews from within code following the API example. That is great for one-offs, but what I really want to do is to use this font in a style, and the reference that style from a layout. Broken example: !-- styles.xml -- ?xml version=1.0 encoding=utf-8? resources style name=Title item name=android:textSize24sp/item item name=android:typefacefonts/myfont.ttf/item /style /resources !-- layout.xml -- LinearLayout xmlns:android=http://schemas.android.com/apk/res/ android android:orientation=vertical android:layout_width=fill_parent android:layout_height=fill_parent TextView android:id=@+id/title style=@style/Title android:layout_width=fill_parent android:layout_height=wrap_content / /LinearLayout This would allow me to reuse the same style (including font) without having to do it in code. Anyone have any ideas how to make this work? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Copying an area from a drawable
I am not entirely sure if this is what you are looking for, but the Canvas has a method where you can specify the a source and destination rectangle to draw from and to: public void drawBitmap(Bitmapfile:///C:/Software/android/docs/reference/android/graphics/Bitmap.html bitmap, Rectfile:///C:/Software/android/docs/reference/android/graphics/Rect.html src, Rectfile:///C:/Software/android/docs/reference/android/graphics/Rect.html dst, Paintfile:///C:/Software/android/docs/reference/android/graphics/Paint.html paint) HTH Ludwig 2008/10/26 PorkChop [EMAIL PROTECTED] What I am trying to achieve is breaking a drawable down into an array of separate bitmaps. E.g. I am passing a grid of 32x32 images (lets say the image is 320x320 pixels and contains a grid of 10x10 smaller bimap images) and i want to create an array of 100 bitmaps. So I need to copy from (eg) x=32, y=32, w=32,h=32 into another bitmap which is 32x32 pixels. Anyone got any idea how to do this? Hope I have explained this well enough. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
On the emulator, each sample unit of 'API Demos' is made as single Activity. It lasts about 1000-1200 milliseconds till a unit starts. I don't think this is by design, but simply because it lasts that long to load the activity... with setContentView(View) the new screen appears almost immediately. That's what I mean. Regards, Robert --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: PreferenceActivity Refresh Problem
Few tips I currently use : If you want to clear all settings easiliy: getSharedPreferences(..., MODE_PRIVATE).edit().clear().commit(); This method works well when: * you don't have invisible settings, or you want them to be cleared too. * you have specified default values correctly in the xml file describing the preferences. If you want to restart your activity with a single line of code, with the same extras as before: startActivity(getIntent()); //provided you didn't modify the original intent of course On 5 oct, 06:39, Amos [EMAIL PROTECTED] wrote: I've implemented something similar and will leave it like this for now. My resetpreferences option is currently not in the main activity screen, but I'll move it there so it'll behave reasonably. Guess this is an example of the limitations of working with a framework rather than rolling your own code. I'm still very happy with thepreferencesframework, though - it's consistent, works well and saves a lot of time and hassle. 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Start Service when phone power up
At a glance your code looks correct. I use that same approach and it works fine (this project for example: http://unlocking-android.googlecode.com/svn/chapter4/trunk/WeatherReporter/src/com/msi/manning/AndroidManifest.xml). The only difference I see there is that your receiver has the LAUNCHER category, and that may be causing it not to match (or worse an illegal combination). Try removing that and see if works. Also, try posting more info about the error if that's not the problem (the debug output of logcat). On Oct 27, 7:05 am, Breno [EMAIL PROTECTED] wrote: Hi, after i read some posts here in forum, i'm able to start my program when phone power up. But i need to start a Service, in this case, the service is a notification, just for testing. Here is my code. package com.test.StartupTest; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.widget.Toast; public class TesteStartup extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { Toast.makeText(context, Test to see if this works,Toast.LENGTH_LONG).show(); //Start explicitly a Service that show in Notification bar a message context.startService(new Intent(context, NotifyInfoUser.class)); } } and the NotifyInfoUser.java: package com.test.StartupTest; import com.test.R; import android.app.Notification; import android.app.NotificationManager; import android.app.PendingIntent; import android.app.Service; import android.content.Intent; import android.os.IBinder; public class NotifyInfoUser extends Service{ private NotificationManager mNM; private static int MOOD_NOTIFICATIONS = R.layout.main; @Override public void onCreate() { mNM = (NotificationManager) getSystemService(NOTIFICATION_SERVICE); } @Override public void onStart(Intent intent, int startId) { super.onStart(intent, startId); showNotification(R.drawable.online_connected, Connected); } private void showNotification(int moodId, CharSequence text) { // Set the icon, scrolling text and timestamp. // Note that in this example, we pass null for tickerText. We update the icon enough that // it is distracting to show the ticker text every time it changes. We strongly suggest // that you do this as well. (Think of of the New hardware found or Network connection // changed messages that always pop up) Notification notification = new Notification(moodId, Client Started, System.currentTimeMillis()); // The PendingIntent to launch our activity if the user selects this notification //I guess putting null in Intent(this,null) can be crashing PendingIntent contentIntent = PendingIntent.getActivity(this, 0, new Intent(this, null), 0); // Set the info for the views that show in the notification panel. notification.setLatestEventInfo(this, null, text, contentIntent); // Send the notification. // We use a layout id because it is a unique number. We use it later to cancel. mNM.notify(MOOD_NOTIFICATIONS, notification); } @Override public void onDestroy() { // Cancel the persistent notification. mNM.cancel(MOOD_NOTIFICATIONS); } @Override public IBinder onBind(Intent intent) { return null; } } and finally my manifest ?xml version=1.0 encoding=utf-8? manifest xmlns:android=http://schemas.android.com/apk/res/android; package=com.test android:versionCode=1 android:versionName=1.0.0 uses-permission android:name=android.permission.RECEIVE_BOOT_COMPLETED / application android:icon=@drawable/icon android:label=@string/ app_name receiver android:name=.StartupTest.TesteStartup intent-filter action android:name=android.intent.action.BOOT_COMPLETED / category android:name=android.intent.category.LAUNCHER / /intent-filter /receiver service android:name=.StartupTest.NotifyInfoUser/ /application /manifest When phone power up, the screen with This app execute a ilegal operation, etc appear. When i comment the startService, the Toast appear in screen. So, what is wrong with the context.startService? thanks a lot Breno --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at
[android-developers] Re: How do I pass data between differentActivity/Process?
AIDL, IPC - Parcelable, Binder, etc. is how you pass data directly between processes. http://code.google.com/android/reference/aidl.html That can be cumbersome and complicated though. You may be better off using the Android way and making your own ContentProvider that all the activities and apps can share? http://code.google.com/android/devel/data.html On Oct 27, 3:27 am, Dikers [EMAIL PROTECTED] wrote: Sorry I didn't clear my problem, so you misunderstand my means. For Example: I have five activities in different process, then I want to start a service to manager these activities. In the service , user can send a message to stop/finish a given activities. How do I pass data between these activity and service? Thank you! On Oct 27, 2:30 pm, Dikers [EMAIL PROTECTED] wrote: Thank you! On Oct 27, 2:17 pm, dailyLife[EMAIL PROTECTED] wrote: You can see below demo code: Intent tIntent = new Intent(); tIntent.setClassName(SKIP_PATH, SKIP_PATH_NAME); Bundle tBundle = new Bundle(); tBundle.putCharSequence(request, secondRequest.toString()); tIntent.putExtras(tBundle); startActivity(tIntent); [EMAIL PROTECTED] 2008年10月27日 - Original Message - From: Dikers To: Android Developers Sent: 2008-10-27, 14:11:03 Subject: [android-developers] How do I pass data between differentActivity/Process? Example: activity android:name=TestActivity android:theme=@android:style/ Theme.Dialog android:multiprocess=true intent-filter action android:name=android.intent.action.VIEW / category android:name=android.intent.category.DEFAULT / /intent-filter /activity I start many activities with different processes(android:multiprocess=true), Now how do I pass data between these activities? 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Fastest Combination of Http Post/Get and XML parsing libs
On Mon, Oct 27, 2008 at 6:01 AM, Guillaume Perrot [EMAIL PROTECTED] wrote: According to me, the fastest combo is to use HttpClient + SAX. SAX: encouraged by the android team, they discourage the use of XmlPullParser unless we import KXml in our source tree and use this implementation. Why do they discourage using XmlPullParser? Casey --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
Hm, if you have a side-by-side demo comparing the two approaches and showing that one is really much faster than the other while offering same functionality, this calls for explanation from the Google folks :-) To be fair this comparison should be made on a real device though, not on the emulator. Peli On Oct 27, 12:36 pm, Robert K. [EMAIL PROTECTED] wrote: On the emulator, each sample unit of 'API Demos' is made as single Activity. It lasts about 1000-1200 milliseconds till a unit starts. I don't think this is by design, but simply because it lasts that long to load the activity... with setContentView(View) the new screen appears almost immediately. That's what I mean. Regards, Robert --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
a) setContentView(new content) b) Send an Intent so the OS can resolve it, start a new Activity (optionally restoring it's state), call the needed methods of the old Activity (onPause() etc..) and finally call setContentView(new content) in the new Activity (I know, it's a simplification..) You need a side-by-side demo for understanding that a is way faster than b? :) Yes, using just one Activity and calling setContentView(new content) is not the best practice but the speed/memory advantage is just too great IMO (yes, I know that I have to handle the back key, state saving and memory cleanup myself.. I'm doing it and it's still way faster/more memory efficent than using different Activities for every screen that I have) If you have a simple application with just a few screens and you don't mind that the user has to wait for about a second while switching between them, then go for many Activities. If you want memory and speed efficiency, then use one Activity and manage the different views yourself (with the burden of managing different states yourself when the user navigates to/away from your app.) On Mon, Oct 27, 2008 at 2:41 PM, Peli [EMAIL PROTECTED] wrote: Hm, if you have a side-by-side demo comparing the two approaches and showing that one is really much faster than the other while offering same functionality, this calls for explanation from the Google folks :-) To be fair this comparison should be made on a real device though, not on the emulator. Peli On Oct 27, 12:36 pm, Robert K. [EMAIL PROTECTED] wrote: On the emulator, each sample unit of 'API Demos' is made as single Activity. It lasts about 1000-1200 milliseconds till a unit starts. I don't think this is by design, but simply because it lasts that long to load the activity... with setContentView(View) the new screen appears almost immediately. That's what I mean. Regards, Robert --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Join via ContentProvider
That looks like two tables. Contacts.People Contacts.People.Phones - Juan On Oct 26, 12:52 pm, Anm [EMAIL PROTECTED] wrote: jtaylor, Did you read the example? It does not do a joint. Instead it uses a Uri subpath notation for its child query, within the same table rather than joining multiple tables. The references to group in the code are not contact group membership, but rather ExpandableList parent node/groups. On Oct 25, 11:51 am, jtaylor [EMAIL PROTECTED] wrote: ExpandableList2.java has the getChildrenCursor() (in the MyExpandableListAdapter inner class) which has the code for obviously a contentprovider Join. http://code.google.com/android/samples/ApiDemos/src/com/example/andro... - Juan On Oct 25, 2:47 pm, jtaylor [EMAIL PROTECTED] wrote: ExpandableList2.http://code.google.com/android/samples/ApiDemos/src/com/example/andro... - Juan On Oct 24, 3:05 am, Anm [EMAIL PROTECTED] wrote: I'm struggling to understand how to do a join, if its possible, with the decomposed SQL arguments of the ContentProvider APIs. Is there an example out there? Or if not, could some code up a quick example, say joining People with GroupMembership? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Join via ContentProvider
I'm just supposing that each class is a table. I don't know how android.provider is set up, though I guess one can now see from the source code. - Juan On Oct 27, 9:15 am, jtaylor [EMAIL PROTECTED] wrote: That looks like two tables. Contacts.People Contacts.People.Phones - Juan On Oct 26, 12:52 pm, Anm [EMAIL PROTECTED] wrote: jtaylor, Did you read the example? It does not do a joint. Instead it uses a Uri subpath notation for its child query, within the same table rather than joining multiple tables. The references to group in the code are not contact group membership, but rather ExpandableList parent node/groups. On Oct 25, 11:51 am, jtaylor [EMAIL PROTECTED] wrote: ExpandableList2.java has the getChildrenCursor() (in the MyExpandableListAdapter inner class) which has the code for obviously a contentprovider Join. http://code.google.com/android/samples/ApiDemos/src/com/example/andro... - Juan On Oct 25, 2:47 pm, jtaylor [EMAIL PROTECTED] wrote: ExpandableList2.http://code.google.com/android/samples/ApiDemos/src/com/example/andro... - Juan On Oct 24, 3:05 am, Anm [EMAIL PROTECTED] wrote: I'm struggling to understand how to do a join, if its possible, with the decomposed SQL arguments of the ContentProvider APIs. Is there an example out there? Or if not, could some code up a quick example, say joining People with GroupMembership? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
I agree with you, tauntz. Maybe it won't last 'seconds' with the activity approach to switch (with further investigation: the API demo needs 1 sec. cause of the large amount of list items, i think) but there is a remarkable delay by simply switching one LinearLayout to another. With setContentView(view) it happens really immediately with almost zero delay. I have coded a side-by-side demo, which i'll post. Just need to implement a realistic timer. The differences are evident, I think. I think, the Activity/Intent- Pattern is a real intelligent thing, but it is rather heavy-weight. As I've said, both classes Intent and Activity contain about 3000-4000 lines of 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Manipulate Drawable Resource
Hi Kyle, Where does the icon live that you are trying to update? Is it inside of your app, or is it on the Android home screen? From what I can gather the SDK does not allow one to update the icon on the home screen during runtime (at least that is what I read here on the board when attempting to do that), instead you have to use the notification layer and post a message to the title bar. On the other hand, if you are attempting to change an image/icon inside of the app, this is pretty standard. Just grab the current ImageButton and call .setImageResource(int resource id). Now, if you are getting fancy and just adding a badge or something, it will be slightly more complicate, but this should get you up in the right direction. Take a look at the draw() methods as well Does that help? Kevin On Oct 26, 12:20 pm, Kyle [EMAIL PROTECTED] wrote: Hello, I'm trying to find a way to programmatically change a drawable resource within my application so that I can display this updated icon as a notification. Would this be possible? If not is there another way to go about doing something like this? I figured a notification object might be able to take a bitmap or drawable but it looks like you can only pass a resource id. Thanks for any help. Kyle --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
Hm, according to my experience, switching between activities works quite swiftly. I wonder if you do a fair comparison. If you have a lot of initialization going on in onCreate() and onResume() then it is hardly the OS to be blamed. Some of the heavier objects could be stored in static variables. If you switch between activities within your own application, you stay within your process. Resolving the intents should not account for the 1000 ms you are experiencing... Peli On Oct 27, 2:00 pm, tauntz [EMAIL PROTECTED] wrote: a) setContentView(new content) b) Send an Intent so the OS can resolve it, start a new Activity (optionally restoring it's state), call the needed methods of the old Activity (onPause() etc..) and finally call setContentView(new content) in the new Activity (I know, it's a simplification..) You need a side-by-side demo for understanding that a is way faster than b? :) Yes, using just one Activity and calling setContentView(new content) is not the best practice but the speed/memory advantage is just too great IMO (yes, I know that I have to handle the back key, state saving and memory cleanup myself.. I'm doing it and it's still way faster/more memory efficent than using different Activities for every screen that I have) If you have a simple application with just a few screens and you don't mind that the user has to wait for about a second while switching between them, then go for many Activities. If you want memory and speed efficiency, then use one Activity and manage the different views yourself (with the burden of managing different states yourself when the user navigates to/away from your app.) On Mon, Oct 27, 2008 at 2:41 PM, Peli [EMAIL PROTECTED] wrote: Hm, if you have a side-by-side demo comparing the two approaches and showing that one is really much faster than the other while offering same functionality, this calls for explanation from the Google folks :-) To be fair this comparison should be made on a real device though, not on the emulator. Peli On Oct 27, 12:36 pm, Robert K. [EMAIL PROTECTED] wrote: On the emulator, each sample unit of 'API Demos' is made as single Activity. It lasts about 1000-1200 milliseconds till a unit starts. I don't think this is by design, but simply because it lasts that long to load the activity... with setContentView(View) the new screen appears almost immediately. That's what I mean. Regards, Robert --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
As I've said, both classes Intent and Activity contain about 3000-4000 lines of code... Most of which are actually documentation: http://git.source.android.com/?p=platform/frameworks/base.git;a=blob;f=core/java/android/app/Activity.java;h=fa310a5cf14ae6952188895ed9804fe1d0b780a1;hb=HEAD http://git.source.android.com/?p=platform/frameworks/base.git;a=blob;f=core/java/android/content/Intent.java;h=aa4622b14f3008d1bfaa3a034e7df92e740ecde1;hb=HEAD I only see a handful of member variables in each of them... Peli --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Notification from a Broadcast Receiver Class
Hi, I am trying to set an automatic notification to the ticket text when a broadcast receiver class returns a certain result. Here is what I have so far: public class PriceCheck extends BroadcastReceiver{ int alarmCount = 0; public void onReceive(Context context, Intent intent) { do something if (alarmCount 0) { String message = !!! Price Alarm !!!; Notifier notice = new Notifier(); Intent noticeIntent = new Intent(context, Another.class); notice.setNotice(context, noticeIntent, R.string.limit_detect, R.drawable.icon, message, true); } } public class Notifier extends Activity{ private static final String TAG = Notifier; NotificationManager nm; String tickerText; protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); nm = (NotificationManager)getSystemService(NOTIFICATION_SERVICE); } public void setNotice(Context ctx, Intent intent, int noticeId, int icon, String messageText, boolean showTicker) { // In this sample, we'll use the same text for the ticker and the expanded notification CharSequence text = messageText; Log.v(TAG, Text: + text); // choose the ticker text if (showTicker = true) { tickerText = messageText; } else { tickerText = null; } // Set the icon, scrolling text and timestamp Log.v(TAG, Icon id is: + icon); Log.v(TAG, TickerText is: + tickerText + , SystemTime is: + System.currentTimeMillis()); Notification notification = new Notification(icon, tickerText, System.currentTimeMillis()); // The PendingIntent to launch our activity if the user selects this notification if (ctx == null) { Log.v(TAG, Context is null); } PendingIntent contentIntent = PendingIntent.getActivity(ctx, 0, intent, 0); // Set the info for the views that show in the notification panel. notification.setLatestEventInfo(ctx, messageText, text, contentIntent); // Send the notification. // We use a layout id because it is a unique number. We use it later to cancel. nm.notify(noticeId, notification); } } The last line in the second class gives me a null pointer exception: nm.notify(noticeId, notification); I know that most of the stuff is received. How could I check that the context has all information required? Does anybody know what I am doing wrong? Thanks for your input, AusSeattle --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Anyone mind testing quickly?
Anyone mind testing this on a real phone for me (before the marketplace launch tomorrow)? It's a basic tip calculator. The main thing I'm not sure will work are the blue arrow buttons to the right of the text fields. You should be able to touch them to modify values in the calculator. Appreciate it! http://satipcalculator.googlecode.com/files/sa_tip_calculator.apk --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How can I change a ListView to ExpandableList
I am programing a business card system . And when this program is start , user can choose what list will be show. The list can be order by card or order by group when using order by card I will using ListView to show when using order by group I will using ExpandableList to show The question is android only can Extends one class so that I just can only use one List. Is it possible to implement two list view in my program ? public class card extends ListActivity { } or public class card extends ExpandableListActivity{ } my program just can only choose one list method. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: EditText
I was wondering the same thing yesterday. I'm trying to make minor changes to the notepad tutorial and this was one of them! --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Image Zoom
Hi all, i would like to make zoom on a image and, when the zoom is activated, browse the image with touch. Any idea? 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] application size / resources
Hi I am trying to design an application that has lots of data (medical reference stuff). Probably more than 90% of the size of this application will be resource files (images/text). Given that the G1 has about 64mb free when they arrive to the customer (i.e. after accounting for default installed apps). Assuming that my typical user will also have a number of other apps running on their device, this leaves me striving for an app size of around 1mb max (note that some free apps out on the market are 7mb and I assume many games will have similar sizes). The ideal solution is to store my application data on the sd card. The applications that are out there do not seem to be using such an approach and I am wondering if this is possible? Will the market install such applications correctly or will it throw out an out of memory error? I am already very close to running out of space on my G1 because all these apps are going into the phone memory with all their resources. I guess I should delete all the games?! Any pointers ? Where are apps installed on the device? how about sqlite database? resources? Do we have control of where they go? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] g1 keyboard missing up/down/left/right keys?
I set up my g1 phone to test the Snake sample came with the Android SDK. The application requires up/down/left/right keys, but they not available on the g1 keyboard - did I miss it? I changed the code to use I, K, J, L keys instead. It works when I have the device connect to to the computer with Eclipse running. But the app stops working when I unplugged it from the computer. Is it because I didn't do a release build? How? I know, two questions! 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] G1 GPS receiver turn on and turn off
Hi, I would like to control the GPS receiver via software. Simple turn on and turn off. Has anyone done it? I imagine that T-Mobile/HTC would have to share G1 specific SDK to accomplish that, am I right? Thanks, hdk --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: 'Keytool error' when building
Thanks mitschi. Tha worked. Also found the cool tool to choose and select an alternative update-alternatives --config keytool On Sep 24, 1:04 pm, mitschi [EMAIL PROTECTED] wrote: Hi, I had the exact same problem. here is what i did: // look which keytool is first in path # which keytool /usr/bin/keytool // this is just a link, so let's look deeper # ls -al /usr/bin/keytool lrwxrwxrwx 1 root root 39 2008-09-24 21:41 /usr/bin/keytool - /etc/alternatives/keytool // again just a link # ls -al /etc/alternatives/keytool lrwxrwxrwx 1 root root 37 2008-06-10 08:27 /etc/alternatives/keytool - /usr/lib/jvm/java-gcj/jre/bin/keytool here is the problem, the keytool in path is the one from the gnu java vm. here my solution: rm /etc/alternatives/keytool ln -s /usr/lib/jvm/*some-sun-vm*/bin/keytool /etc/alternatives/keytool rm -rf /home/myhome/.android eclipse - and start working... I think this is a Ubuntu issue and there is a nicer way to change the keytool alternative, but this worked for me. /Mitschi On 31 Aug., 11:03, nazurro [EMAIL PROTECTED] wrote: Hi, My email showed up in the discussion a bit late, after Megha Joshi:s suggestion to try java 5 instead I got it to work, together with deleting the debug.keystore file (which I had tried before). So I'm good for now. Thx :) Going for the Notepad tutorial as we speak. /Tobias On 30 Aug, 23:49, David Given [EMAIL PROTECTED] wrote: nazurro wrote: Hello, I have the EXACT same problem, want to try developing forAndroidbut I just can't get it to work: Ubuntu 8.04 Eclipse 3.3.2 JVM: java-6-sun I would be very happy for suggestions. Beats me. Sorry. (That is, in fact, almost exactly my setup --- I'm using Eclipse 3.4.) The only thing I can think of is that on my system, when it worked the debug.keystore file was being created from the command line and when it failed it was being created via Eclipse; so you might be interesting to have a try recreating your keystore from the command line... but I'm afraid I don't know how. And at this point I'm a little adverse to playing with my system and breaking it again! -- ┌─── dg@cowlark.com ─http://www.cowlark.com─ │ │ All power corrupts, but we need electricity. --- Diana Wynne Jones, │ _Archer's Goon_ signature.asc 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How to get the picture(like a .jpg picture) in Android?
Maybe there is one way, that is to decodeResource to be a bitmap and get height and width of this bitmap, but if there is any other way to get the size of picture(obtained by id)? Plz help me, thanks a lot! --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Problems with socket connection
Hi people, first of all I tell you that my English isn't so good, so please forgive my ugly grammar! I have this problem: when using sdk m5 I wrote an Android app (running on the emulator) and a Java program running on the pc. The java program uses BlueCove to interact with the bluetooth radio of my pc. I was able to connect the Android app and the Java program with a socket connection and then I opened a DataInputStream an a DataOutput Stream. The thing worked fine. Now with the SDK 1.0 I'm not able to do the same and I don't understand why: on the AndroidManifest file I specified with uses- permission that my app has the INTERNET permission, but I can't open the streams: the Java program (the server) throws an Exception that says that the operation on the socket failed because the net isn't reacheable. If you have any idea about what is my error... Thank you very much! Bye! --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] how to stay in webview without opening new browser window
if i make the webview load a web page, and in that web page i press on a form submit button, then another browser window is open. How can i make everything stay in my app instead of opening a new browser window? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Streaming Media to Android Success!!!!
After purchasing 2 G1 phones I was very eager to use the 3G service in my area. Long story short when found that there is currently no media player on the OS out the box, I started to look and found that there was currently no solution available until I found this: www.Ifunpix.com I usually use ORB with WinMo6 on an HTC universal but it seems that ORB and Youtube are no good together yet on the G1. So with some limitation you can use IFUNPIX to handle video and audio streaming. Advanced features of Orb such as Webcam and TV viewing are not available but it's a start:P I have been using it for 20 minute streaming Prison Break and it seems to be OK out side of an occasional buffer oh and try not to scrub your file it will crash the video player. I forgot to mention I believe the stream will be played on the video player software that is available through the Android market. If anyone has something better please inform a fellow ORB'er. 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] load and test apps on a g1 device
I've been testing my apps on Android provided emulators on Eclipse in Vista. Just got a g1 phone. Plugged it in my computer. But it doesn't show up on the emulator list - it is not an emulator I guess! Question: How to test my apps directly on the g1 device? 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: My application doesn't work...
did you exec wipe-data ? If you didn't exec wipe-data,you should exec onece . ex 1) SDK run Run- Run configuration - Select Target tab - check Wipe User Data ex 2) Console exec below comand emulator -wipe-data 2008/10/27 Yoshiyuki [EMAIL PROTECTED] Thanks for your reply, Hirayama-san. It is SDK command. I always start applications from run button of eclipse. On Oct 26, 2:21 pm, Hirayama Jun'ichi [EMAIL PROTECTED] wrote: How did you install your apk ? SDK comand , adb install , adb push ? 2008/10/26 Yoshiyuki [EMAIL PROTECTED] This is non-modified version of my error log. [2008-10-26 03:44:06 - Calorie2] -- [2008-10-26 03:44:06 - Calorie2] Android Launch! [2008-10-26 03:44:06 - Calorie2] adb is running normally. [2008-10-26 03:44:06 - Calorie2] Launching: com.gclue.android.Calorie [2008-10-26 03:44:06 - Calorie2] Automatic Target Mode: launching new emulator. [2008-10-26 03:44:06 - Calorie2] Launching a new emulator. [2008-10-26 03:44:11 - Emulator] 2008-10-26 03:44:11.103 emulator[1317:10b] Warning once: This application, or a library it uses, is using NSQuickDrawView, which has been deprecated. Apps should cease use of QuickDraw and move to Quartz. [2008-10-26 03:44:24 - Emulator] emulator: ### WARNING: /etc/localtime does not point to zoneinfo-compatible timezone name [2008-10-26 03:44:24 - Emulator] Thanks, On Oct 24, 5:40 am, Yoshiyuki [EMAIL PROTECTED] wrote: Hi, Alvin, and thanks for reading this one. You asked about the statement apk name and activity name. As you guessed, these were replaced manually. I'm sorry, these changes might make some troubles for people who read this discussion. On 10月24日, 午前5:24, Alvin Yates [EMAIL PROTECTED] wrote: He's compiling on OS X. That's a Java library that he has zero control over. I get the same error all the time. As far at the spontaneous death, the only thing I can point you to is: emulator: ### WARNING: /etc/localtime does not point to zoneinfo- compatible timezone name Also, did you manually replace apk name and activity name in the log, or is that straight from the log? If it's straight from the log, I really have no idea what is going on there. On Oct 23, 6:16 am, Mast3rpyr0 [EMAIL PROTECTED] wrote: one of the packages you include uses something that was removed. find which one is using NSQuickDrawView. and dont use quickdraw anymore. On Oct 23, 8:13 am, Yoshiyuki [EMAIL PROTECTED] wrote: I installed latest version of android and migrated my application. But my application doesn't work. After installing it, I fixed the program because there were some errors due to API changes. Then, I tried to run it, but an error was appeared. Application was not started as a matter of course. The error is below. [2008-10-23 20:57:45 - Calorie2] -- [2008-10-23 20:57:45 - Calorie2] Android Launch! [2008-10-23 20:57:45 - Calorie2] adb is running normally. [2008-10-23 20:57:45 - Calorie2] Launching: com.gclue.android.Calorie [2008-10-23 20:57:45 - Calorie2] Automatic Target Mode: launching new emulator. [2008-10-23 20:57:45 - Calorie2] Launching a new emulator. [2008-10-23 20:57:47 - Calorie2] New emulator found: emulator-5554 [2008-10-23 20:57:47 - Calorie2] Waiting for HOME ('android.process.acore') to be launched... [2008-10-23 20:57:48 - Emulator] 2008-10-23 20:57:48.113 emulator[860:10b] Warning once: This application, or a library it uses, is using NSQuickDrawView, which has been deprecated. Apps should cease use of QuickDraw and move to Quartz. [2008-10-23 20:57:50 - Emulator] emulator: ### WARNING: /etc/localtime does not point to zoneinfo-compatible timezone name [2008-10-23 20:57:50 - Emulator] [2008-10-23 20:58:46 - Calorie2] HOME is up on device 'emulator-5554' [2008-10-23 20:58:46 - Calorie2] Uploading apk name.apk onto device 'emulator-5554' [2008-10-23 20:58:46 - Calorie2] Installing apk name.apk... [2008-10-23 20:58:52 - Calorie2] Success! [2008-10-23 20:58:52 - Calorie2] Starting activity activity name on device [2008-10-23 20:58:55 - Calorie2] ActivityManager: Starting: Intent { comp={package name} } [2008-10-23 20:58:55 - Calorie2] ActivityManager: [1] Killed am start -n com Would someone have ideas to fix it up? 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] Uploads disabled in browser
hey guys, is there anyway to upload an image from android/simulator through a web page? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: mail.jar activation.jar problem in android
im using example http://davanum.wordpress.com/2007/12/22/android-send-email-via-gmail-actually-via-smtp/ with 1.0 and found Following is the exception. E/OSNetworkSystem( 448): unknown socket error -1 E/SendMail( 448): Could not connect to SMTP host: smtp.gmail.com, port: 465 E/SendMail( 448): javax.mail.MessagingException: Could not connect to SMTP host : smtp.gmail.com, port: 465; E/SendMail( 448): nested exception is: E/SendMail( 448): java.net.SocketException: unknown error E/SendMail( 448): at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransp ort.java:1391) E/SendMail( 448): at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPT ransport.java:412) E/SendMail( 448): at javax.mail.Service.connect(Service.java: 310) E/SendMail( 448): at javax.mail.Service.connect(Service.java: 169) E/SendMail( 448): at javax.mail.Service.connect(Service.java: 118) E/SendMail( 448): at javax.mail.Transport.send0(Transport.java: 188) E/SendMail( 448): at javax.mail.Transport.send(Transport.java: 118) E/SendMail( 448): at org.apache.android.mail.GMailSender.sendMail(GMailSen der.java:60) E/SendMail( 448): at org.apache.android.mail.SendMail $1.onClick(SendMail.j ava:35) E/SendMail( 448): at android.view.View.performClick(View.java: 2109) E/SendMail( 448): at android.view.View.onTouchEvent(View.java: 3523) E/SendMail( 448): at android.widget.TextView.onTouchEvent(TextView.java:44 10) E/SendMail( 448): at android.view.View.dispatchTouchEvent(View.java:3178) E/SendMail( 448): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.j ava:857) E/SendMail( 448): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.j ava:857) E/SendMail( 448): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.j ava:857) E/SendMail( 448): at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.j ava:857) E/SendMail( 448): at com.android.internal.policy.impl.PhoneWindow $DecorVie w.superDispatchTouchEvent(PhoneWindow.java:1561) E/SendMail( 448): at com.android.internal.policy.impl.PhoneWindow.superDis patchTouchEvent(PhoneWindow.java:1085) E/SendMail( 448): at android.app.Activity.dispatchTouchEvent(Activity.java :1873) E/SendMail( 448): at com.android.internal.policy.impl.PhoneWindow $DecorVie w.dispatchTouchEvent(PhoneWindow.java:1545) E/SendMail( 448): at android.view.ViewRoot.handleMessage(ViewRoot.java:114 0) E/SendMail( 448): at android.os.Handler.dispatchMessage(Handler.java:88) E/SendMail( 448): at android.os.Looper.loop(Looper.java:123) E/SendMail( 448): at android.app.ActivityThread.main(ActivityThread.java:3 742) E/SendMail( 448): at java.lang.reflect.Method.invokeNative(Native Method) E/SendMail( 448): at java.lang.reflect.Method.invoke(Method.java: 515) E/SendMail( 448): at com.android.internal.os.ZygoteInit $MethodAndArgsCalle r.run(ZygoteInit.java:739) E/SendMail( 448): at com.android.internal.os.ZygoteInit.main(ZygoteInit.ja va:497) E/SendMail( 448): at dalvik.system.NativeStart.main(Native Method) E/SendMail( 448): Caused by: java.net.SocketException: unknown error E/SendMail( 448): at org.apache.harmony.luni.platform.OSNetworkSystem.crea teSocketImpl(Native Method) E/SendMail( 448): at org.apache.harmony.luni.platform.OSNetworkSystem.crea teSocket(OSNetworkSystem.java:79) E/SendMail( 448): at org.apache.harmony.luni.net.PlainSocketImpl2.create(P lainSocketImpl2.java:59) E/SendMail( 448): at java.net.Socket.checkClosedAndCreate(Socket.java:763) E/SendMail( 448): at java.net.Socket.connect(Socket.java:910) E/SendMail( 448): at java.net.Socket.connect(Socket.java:888) E/SendMail( 448): at com.sun.mail.util.SocketFetcher.createSocket(SocketFe tcher.java:233) E/SendMail( 448): at com.sun.mail.util.SocketFetcher.getSocket(SocketFetch er.java:163) E/SendMail( 448): at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransp ort.java:1360) E/SendMail( 448): ... 29 more On Oct 9, 4:15 pm, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: http://groups.google.com/group/android-developers/browse_thread/threa... could be useful? On 4 Ott, 05:14, Megha Joshi [EMAIL PROTECTED] wrote: Any details of what you are trying to do would be good... 2008/10/3 mpredosin [EMAIL PROTECTED] I am having the same problem. The activation.jar can't find the required classes in the android jar. It occurs with both Android 1.0 0.9 sdks. 10-03 23:24:49.891: DEBUG/SSLSocketFactory(378): Using factory [EMAIL PROTECTED] 10-03 23:24:49.979: DEBUG/OpenSSLSocketImpl(378): SSL_OP_NO_SSLv3 is set 10-03 23:24:56.080: INFO/global(378): Oct 3, 2008 11:24:55 PM java.io.BufferedOutputStream init 10-03 23:24:56.080: INFO/global(378): INFO: Default buffer size used in BufferedOutputStream constructor. It would be better to be explicit if a 8k buffer is required. 10-03
[android-developers] Re: T-mobile G1 for testing purposes
shadowdrakken, I know that more phones are coming out with Android, but apart from the USA, the situation is quite confusing. In many european countries we still don't know when and if Android phones are hitting the market. I will try to buy a G1 next month in NY, if it will not be possible I will take one from eBay, like Timbobsteve suggested, even though I don't still know if the ones from eBay are real G1s or fakes. Anybody knows something about the unlocking after 90 days from T- Mobile? Is that a software modification? Anyway I read on some blogs that in T-Mobile stores they don't want to sell G1s at full price, so I think it will be very hard to get one in USA... On Oct 27, 10:52 am, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: There are more Android phones coming on other service providers. For now, the emulator should be fine until one of the other phones comes out. Sprint has been waffling on it, saying they will have Android phones soon but at the same time saying Android isn't good enough yet (I think they mean it's not big enough yet for them to invest into) so just hold tight, they're coming, and they will be big :) On Oct 27, 4:20 am, Teo [EMAIL PROTECTED] wrote: This is an excellent question. T-Mobile isn't in my country as well. There are some rumors it will come, but nothing official yet. So will there be a legitimate way to get an Android phone that will work with our own SIM cards? Thanks, Teo On Oct 27, 10:33 am, Ale [EMAIL PROTECTED] wrote: Sorry Timbobsteve, I just realized I made a mistake in my previous email: I wrote free device but I did'nt mean free of charge but free of lock, unlocked. I realize it was quite stupid, sorry for my english. My concern is that in my country Android is not going to come until 2009 and I would like to buy a G1 in USA but I don't know if the ones that they sell in T-Mobile stores are unlocked or not. I know that the full price is 399 but will I be able to use the device abroad, with mi SIM? Can you explain me more about the 90 days unlock? I mean, if I came to the USA and I buy a G1 how can I unlock it after 90 days? Is the unlock something like a software update or it is a physical modification? Thank you very much! AB On Oct 24, 10:57 am, Timbobsteve [EMAIL PROTECTED] wrote: What I don't understand is why people are deluded enough to think that they should get one of these devices for free? I would like to develop programs for Windows, PSP and Nintendo DS Should I get free consoles and a new PC as a result? No... that would be ludicrous. I have to pay for the devices just like everyone else. My guess is that you may be able to get these devices straight from HTC, if you have some sort of developer connection (and if they support that kind of setup)... otherwise you have to buy into the contract like everyone else. There is always the option to get the contract and after 90 days, request the phone be unlocked. From what I hear T-Mobile are quite good with that kind of thing and usually oblige. My 2 cents... I'm now off to find some free donuts and free coffee and enjoy a free trip to the premier of Quantum of Solace. Ale wrote: Hi guys, I'm wondering whether for strangers it will be possible to buy the G1 and use it abroad for testing (and for enjoing Android ;) ). I read that the device can be bought at full price 399$ but I think that it will be unlocked.. Any idea on how to get a free device for testing purposes? Thank you in advance!!! AB- Hide quoted text - - Show quoted text - --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
Here's the side-by-side app I wrote: http://www.anddev.org/viewtopic.php?p=12247#12247 setContentView(view) needed 2-5 ms, new Activity approach 40-90ms for this simple example. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: process ids
Ludwig, Thanks. I was aware of the /proc structure. ps gets its data from / proc/stats I thought that using ps would minimize the possibility of future incompatibilities. when running the code I listed below, it does not fail. However, all it seems to retrieve is the column headers. Note that when I run the code on a Linux desktop (via Eclipse). The expected output, the entrie list of processes, is produced. So, at this point, I wonder why when running the code in the Android emulator, all I get is the column headers. Alex On Oct 26, 5:54 pm, Ludwig [EMAIL PROTECTED] wrote: /proc is a (virtual) file system, so you can navigate through it with the usual File operations. For every process there is a directory /proc/pid where pid is the processes PID. Under that directory is a whole lot of stuff relating to that process, such as command line, actual executable, open files etc etc. Searching for proc filesystem should give you much more information, but as hackbod pointed out you do not have any guarantees that the layout will stay exactly the same over versions/devices etc.Command like ps actually read from /proc for their output. Ludwig 2008/10/26 alexdonnini [EMAIL PROTECTED] I thought I would try using ps with code like the one listed below. headers for the process list are reported correctly but not much else. When you mentioned accessing /proc directly, did you have something else (other than ps) in mind? Thanks. Alex Donnini private void getProcessList() { System.out.println(retrieving list of running processes via -- ps -e -- command); try { processList = new ArrayListString(); String line; java.lang.Process p = Runtime.getRuntime().exec(ps -e); BufferedReader input = new BufferedReader(new InputStreamReader(p.getInputStream())); while ((line = input.readLine()) != null) { System.out.println(running process - +line); //-- Parse data here. processList.add(line); } input.close(); } catch (Exception err) { err.printStackTrace(); } On Oct 26, 2:43 pm, alexdonnini [EMAIL PROTECTED] wrote: Thanks. I understand the risk in going for direct access. On Oct 24, 1:09 am, hackbod [EMAIL PROTECTED] wrote: Sorry, we don't currently have a high-level API for doing this. As a hack, you can read /proc directly, but that is not something that is part of the SDK and so you have no guarantees of it working on future releases or other phones. On Oct 23, 8:25 pm,alexdonnini[EMAIL PROTECTED] wrote: Hello, Would anyone be able to tell me (or point me in the right direction) how I could retrieve the pids and related process information as reported, for example, in DDMS in an Android application? I have been able to put together a small application that retrieves information about all tasks running (ActivityManager activityManager = (ActivityManager)this.getSystemService(ACTIVITY_SERVICE); ListActivityManager.RunningTaskInfo runningTasks = activityManager.getRunningTasks(30); ) However, if possible, I would like to retrieve task and process information at a higher level of granularity (or, if you like, at lower level). Any help would be greatly appreciated. Thanks. Alex Donnini --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: T-mobile G1 for testing purposes
I am a T-Mobile customer/Android developer living in Germany, and we have been promised a device sometime in Q1/2009 (after USA, then UK). As it takes 90 days to get an officially locked T-Mobile USA device, I am assuming that all unlocked G1’s currently listed on eBay are fake. I am also unsure of how well a device apparently *optimised* for T- Mobile USA 3G frequencies will perform on my local network. Ironically, for such a developer centric device, they are starving the community of phones: e.g. http://www.biggu.com/2008/10/23/t-mobile-says-no-g1-for-you/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: g1 keyboard missing up/down/left/right keys?
Hi, I had the same problem with the Lunar Lander application. Someone on this group told me that the D-Pad events are supposed to be handled by the trackball, but this is definitely not happening. Please post if you get a solution. I have been trying to find an applicable code snippet for trackball usage. On Oct 27, 12:01 am, g1ster [EMAIL PROTECTED] wrote: I set up my g1 phone to test the Snake sample came with the Android SDK. The application requires up/down/left/right keys, but they not available on the g1 keyboard - did I miss it? I changed the code to use I, K, J, L keys instead. It works when I have the device connect to to the computer with Eclipse running. But the app stops working when I unplugged it from the computer. Is it because I didn't do a release build? How? I know, two questions! 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Problem with ImageView
Hi, I have an Activity which contains an ImageView. If I call another Activity via “startActivity” and then move back to the starting Activity via the “back button” the ImageView is greyed-out like it is disabled. Has anybody encountered this problem? How can I avoid it? Best regards, Christian Wiesbauer --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: HttpURLConnection getResponseCode
Add me to the list of people who are experiencing this problem. Anyone have solutions? On Oct 16, 11:43 pm, Gil [EMAIL PROTECTED] wrote: I learned more about the problem. It always occurs after I cancel a GET request. By cancel I mean quit the loop that reads from the input stream, disconnect theHttpURLConnectionand quit the thread which runs the connection. NextHttpURLConnectionI create exhibits the problem described above. If I restart my application using Eclipse the problem goes away. It also goes away some time after the canceled GET request (simply wait a 30 seconds to a minute). On Oct 16, 5:15 pm, androidian [EMAIL PROTECTED] wrote: I have the same problem. No idea what's happening. On Oct 16, 4:04 pm, Gil [EMAIL PROTECTED] wrote: I have a class that implements anHttpURLConnection. The class works fine most of the time. Once in a while when I perform a GET operation getResponseCode returns -1. Does anyone know under what circumstances getResponseCode returns -1? The documentation states: the response code, -1if no valid response code. Ethereal shows that the GET request has been sent but that no bytes have been received. Also, the getResponseCode does not time out. When it fails it does so without waiting at all (typically 100ms). --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] More highlevel 3D development
Hi As I understand it, the only 3D graphics related thing that comes with Android, is the raw OpenGL ES. I would like to work with my 3D applications for Android at a little higher level. For instance I would like to have a GLUT layer ontop of OpenGL ES. Does anyone know if that is possible? If someone have done it? If GLUT is not possible, what is then used out there? What is the best way (in your opinion) to effeciently devoplor 3D apps for Android. 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: process ids
Thanks, that is quite a bit more elegant than what I proposed. (Hint to Google: the documentation for the clear() method on the SharedPreferences.Editor says: Mark in the editor to remove *all* values from the preferences. Once commit is called, the only remaining preferences will be any that you have defined in this editor. That is, IMHO, not exactly the same as saying that everything will be reset to what is defined in the XML file... I would have assumed that by just calling clear() it would result in all queries to the shared preferences settings then returning that they are not set.) Ludwig 2008/10/27 alexdonnini [EMAIL PROTECTED] Ludwig, Thanks. I was aware of the /proc structure. ps gets its data from / proc/stats I thought that using ps would minimize the possibility of future incompatibilities. when running the code I listed below, it does not fail. However, all it seems to retrieve is the column headers. Note that when I run the code on a Linux desktop (via Eclipse). The expected output, the entrie list of processes, is produced. So, at this point, I wonder why when running the code in the Android emulator, all I get is the column headers. Alex On Oct 26, 5:54 pm, Ludwig [EMAIL PROTECTED] wrote: /proc is a (virtual) file system, so you can navigate through it with the usual File operations. For every process there is a directory /proc/pid where pid is the processes PID. Under that directory is a whole lot of stuff relating to that process, such as command line, actual executable, open files etc etc. Searching for proc filesystem should give you much more information, but as hackbod pointed out you do not have any guarantees that the layout will stay exactly the same over versions/devices etc.Command like ps actually read from /proc for their output. Ludwig 2008/10/26 alexdonnini [EMAIL PROTECTED] I thought I would try using ps with code like the one listed below. headers for the process list are reported correctly but not much else. When you mentioned accessing /proc directly, did you have something else (other than ps) in mind? Thanks. Alex Donnini private void getProcessList() { System.out.println(retrieving list of running processes via -- ps -e -- command); try { processList = new ArrayListString(); String line; java.lang.Process p = Runtime.getRuntime().exec(ps -e); BufferedReader input = new BufferedReader(new InputStreamReader(p.getInputStream())); while ((line = input.readLine()) != null) { System.out.println(running process - +line); //-- Parse data here. processList.add(line); } input.close(); } catch (Exception err) { err.printStackTrace(); } On Oct 26, 2:43 pm, alexdonnini [EMAIL PROTECTED] wrote: Thanks. I understand the risk in going for direct access. On Oct 24, 1:09 am, hackbod [EMAIL PROTECTED] wrote: Sorry, we don't currently have a high-level API for doing this. As a hack, you can read /proc directly, but that is not something that is part of the SDK and so you have no guarantees of it working on future releases or other phones. On Oct 23, 8:25 pm,alexdonnini[EMAIL PROTECTED] wrote: Hello, Would anyone be able to tell me (or point me in the right direction) how I could retrieve the pids and related process information as reported, for example, in DDMS in an Android application? I have been able to put together a small application that retrieves information about all tasks running (ActivityManager activityManager = (ActivityManager)this.getSystemService(ACTIVITY_SERVICE); ListActivityManager.RunningTaskInfo runningTasks = activityManager.getRunningTasks(30); ) However, if possible, I would like to retrieve task and process information at a higher level of granularity (or, if you like, at lower level). Any help would be greatly appreciated. Thanks. Alex Donnini --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Why Android Market does not accept payments from China?
I come from China and register as a developer When I click continue and pay my registration fee with google checkout System said Android Market does not accept payments from China I bought google apps use the some card before When will Android Market support developer from China? Or just a mistake? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Why Android Market does not accept payments from China?
http://checkout.google.com/support/sell/bin/answer.py?hl=enanswer=42871 On Mon, Oct 27, 2008 at 5:06 PM, NY [EMAIL PROTECTED] wrote: I come from China and register as a developer When I click continue and pay my registration fee with google checkout System said Android Market does not accept payments from China I bought google apps use the some card before When will Android Market support developer from China? Or just a mistake? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Why Android Market does not accept payments from China?
Hi, You can stock your app at http://slideme.org. We don't charge any fees. Shane On Mon, Oct 27, 2008 at 8:06 AM, NY [EMAIL PROTECTED] wrote: I come from China and register as a developer When I click continue and pay my registration fee with google checkout System said Android Market does not accept payments from China I bought google apps use the some card before When will Android Market support developer from China? Or just a mistake? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] MyLocationOverlay Disappears
Hi, I created a MapView and added a MyLocationOverlay to it. If I pass a new GPS lat/lon to the app using DDMS then the blue dot will be shown at that location, which is fine. However if I leave the app running then the blue dot will eventually disappear, and the only way to get it back is to send the coordinates again. Is there a way so that the dot will constantly stay on the screen? Cheers --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Why Android Market does not accept payments from China?
I' ve already got a google checkout account. And used the same card to buy the google app service(http:// www.google.com/a) several months ago I just have another try that I can buy more google apps on that. Order Details - Google Apps, 1600 Amphitheatre Parkway, Mountain View, CA 94043 US are same with the Android Market So why cannot I pay the Android Market Fee now? Can any Google stuff tell me why? Thank you very much indeed. On 10月27日, 下午11时09分, george_c [EMAIL PROTECTED] wrote: http://checkout.google.com/support/sell/bin/answer.py?hl=enanswer=42871 On Mon, Oct 27, 2008 at 5:06 PM, NY [EMAIL PROTECTED] wrote: I come from China and register as a developer When I click continue and pay my registration fee with google checkout System said Android Market does not accept payments from China I bought google apps use the some card before When will Android Market support developer from China? Or just a mistake?- 隐藏被引用文字 - - 显示引用的文字 - --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: process ids
Sorry that was posted on the wrong thread. 2008/10/27 Ludwig [EMAIL PROTECTED] Thanks, that is quite a bit more elegant than what I proposed. (Hint to Google: the documentation for the clear() method on the SharedPreferences.Editor says: Mark in the editor to remove *all* values from the preferences. Once commit is called, the only remaining preferences will be any that you have defined in this editor. That is, IMHO, not exactly the same as saying that everything will be reset to what is defined in the XML file... I would have assumed that by just calling clear() it would result in all queries to the shared preferences settings then returning that they are not set.) Ludwig 2008/10/27 alexdonnini [EMAIL PROTECTED] Ludwig, Thanks. I was aware of the /proc structure. ps gets its data from / proc/stats I thought that using ps would minimize the possibility of future incompatibilities. when running the code I listed below, it does not fail. However, all it seems to retrieve is the column headers. Note that when I run the code on a Linux desktop (via Eclipse). The expected output, the entrie list of processes, is produced. So, at this point, I wonder why when running the code in the Android emulator, all I get is the column headers. Alex On Oct 26, 5:54 pm, Ludwig [EMAIL PROTECTED] wrote: /proc is a (virtual) file system, so you can navigate through it with the usual File operations. For every process there is a directory /proc/pid where pid is the processes PID. Under that directory is a whole lot of stuff relating to that process, such as command line, actual executable, open files etc etc. Searching for proc filesystem should give you much more information, but as hackbod pointed out you do not have any guarantees that the layout will stay exactly the same over versions/devices etc.Command like ps actually read from /proc for their output. Ludwig 2008/10/26 alexdonnini [EMAIL PROTECTED] I thought I would try using ps with code like the one listed below. headers for the process list are reported correctly but not much else. When you mentioned accessing /proc directly, did you have something else (other than ps) in mind? Thanks. Alex Donnini private void getProcessList() { System.out.println(retrieving list of running processes via -- ps -e -- command); try { processList = new ArrayListString(); String line; java.lang.Process p = Runtime.getRuntime().exec(ps -e); BufferedReader input = new BufferedReader(new InputStreamReader(p.getInputStream())); while ((line = input.readLine()) != null) { System.out.println(running process - +line); //-- Parse data here. processList.add(line); } input.close(); } catch (Exception err) { err.printStackTrace(); } On Oct 26, 2:43 pm, alexdonnini [EMAIL PROTECTED] wrote: Thanks. I understand the risk in going for direct access. On Oct 24, 1:09 am, hackbod [EMAIL PROTECTED] wrote: Sorry, we don't currently have a high-level API for doing this. As a hack, you can read /proc directly, but that is not something that is part of the SDK and so you have no guarantees of it working on future releases or other phones. On Oct 23, 8:25 pm,alexdonnini[EMAIL PROTECTED] wrote: Hello, Would anyone be able to tell me (or point me in the right direction) how I could retrieve the pids and related process information as reported, for example, in DDMS in an Android application? I have been able to put together a small application that retrieves information about all tasks running (ActivityManager activityManager = (ActivityManager)this.getSystemService(ACTIVITY_SERVICE); ListActivityManager.RunningTaskInfo runningTasks = activityManager.getRunningTasks(30); ) However, if possible, I would like to retrieve task and process information at a higher level of granularity (or, if you like, at lower level). Any help would be greatly appreciated. Thanks. Alex Donnini --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Why Android Market does not accept payments from China?
Wait... we can register as Android developers already? I expected to see an announcement on the Android blog. Where's the link? On Oct 27, 11:06 am, NY [EMAIL PROTECTED] wrote: I come from China and register as a developer When I click continue and pay my registration fee with google checkout System said Android Market does not accept payments from China I bought google apps use the some card before When will Android Market support developer from China? Or just a mistake? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: PreferenceActivity Refresh Problem
Thanks, that is quite a bit more elegant than what I proposed. (Hint to Google: the documentation for the clear() method on the SharedPreferences.Editor says: Mark in the editor to remove *all* values from the preferences. Once commit is called, the only remaining preferences will be any that you have defined in this editor. That is, IMHO, not exactly the same as saying that everything will be reset to what is defined in the XML file... I would have assumed that by just calling clear() it would result in all queries to the shared preferences settings then returning that they are not set.) (Apologies, this was first posted on the wrong thread) Ludwig 2008/10/27 Guillaume Perrot [EMAIL PROTECTED] Few tips I currently use : If you want to clear all settings easiliy: getSharedPreferences(..., MODE_PRIVATE).edit().clear().commit(); This method works well when: * you don't have invisible settings, or you want them to be cleared too. * you have specified default values correctly in the xml file describing the preferences. If you want to restart your activity with a single line of code, with the same extras as before: startActivity(getIntent()); //provided you didn't modify the original intent of course On 5 oct, 06:39, Amos [EMAIL PROTECTED] wrote: I've implemented something similar and will leave it like this for now. My resetpreferences option is currently not in the main activity screen, but I'll move it there so it'll behave reasonably. Guess this is an example of the limitations of working with a framework rather than rolling your own code. I'm still very happy with thepreferencesframework, though - it's consistent, works well and saves a lot of time and hassle. 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Why Android Market does not accept payments from China?
market.android.com On 10月27日, 下午11时27分, atrus123 [EMAIL PROTECTED] wrote: Wait... we can register as Android developers already? I expected to see an announcement on the Android blog. Where's the link? On Oct 27, 11:06 am, NY [EMAIL PROTECTED] wrote: I come from China and register as a developer When I click continue and pay my registration fee with google checkout System said Android Market does not accept payments from China I bought google apps use the some card before When will Android Market support developer from China? Or just a mistake?- 隐藏被引用文字 - - 显示引用的文字 - --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Developing GPS Application on Android
Hi All, I need couple of things as below to start with Developing GPS Application on Android. 1. What are the currently available GPS Application or basic test application on Android Platform? 2. How to start with Developing GPS Application on Android i.e. available interface./class @ Location Manager Framework. Any information on above topic is really appreciated. Thanks. Regards, _-_Mayank Rana_-_ --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: application size / resources
There have been a few conversations on this topic before and I think the answer is 'no'. Applications install onto the built-in memory, not onto the SD card. If you need larger resources, you will need to implement a download from the web, which can save onto the card. (I think this should change, but it seems that the G1 is considered a phone first, with some applications, rather than an application platform that also comes with a phone). Ludwig 2008/10/27 ammar [EMAIL PROTECTED] Hi I am trying to design an application that has lots of data (medical reference stuff). Probably more than 90% of the size of this application will be resource files (images/text). Given that the G1 has about 64mb free when they arrive to the customer (i.e. after accounting for default installed apps). Assuming that my typical user will also have a number of other apps running on their device, this leaves me striving for an app size of around 1mb max (note that some free apps out on the market are 7mb and I assume many games will have similar sizes). The ideal solution is to store my application data on the sd card. The applications that are out there do not seem to be using such an approach and I am wondering if this is possible? Will the market install such applications correctly or will it throw out an out of memory error? I am already very close to running out of space on my G1 because all these apps are going into the phone memory with all their resources. I guess I should delete all the games?! Any pointers ? Where are apps installed on the device? how about sqlite database? resources? Do we have control of where they go? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Developing GPS Application on Android
Maybe there's a language barrier or something. Did you look at the information from your earlier post? http://groups.google.com/group/android-developers/browse_thread/thread/8aac9166789efe32/b098663fbd23c8d8#b098663fbd23c8d8 Are you looking for a specific piece of information or a demo project? The Location APIs are somewhat easy to follow just by looking at the JavaDocs. Nick On Oct 27, 11:01 am, Mayank Rana [EMAIL PROTECTED] wrote: Hi All, I need couple of things as below to start with Developing GPS Application on Android. 1. What are the currently available GPS Application or basic test application on Android Platform? 2. How to start with Developing GPS Application on Android i.e. available interface./class @ Location Manager Framework. Any information on above topic is really appreciated. Thanks. Regards, _-_Mayank Rana_-_ --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Manipulate Drawable Resource
Hey Kevin, Thanks for the response. The icon I'm trying to update would be a placeholder image that I would store in the resources of my application. I was hoping I would be able to change this within my program based on certain conditions and have the status bar reflect the changes when the icon gets updated. (i.e. Say you wanted to keep an icon of the current temperature in the titlebar and be able to change that icon in your resources with new text as the temperature changes.) I know you can customize the view for the window shade but I'd like to be able to change the actual icon that displays in the status bar. Notifications only take a drawable resource so I wouldn't be able to use setImageResource(int resource id) to change that. Would this be possible at all? Thanks, Kyle On Oct 27, 9:09 am, cyntacks [EMAIL PROTECTED] wrote: Hi Kyle, Where does the icon live that you are trying to update? Is it inside of your app, or is it on the Android home screen? From what I can gather the SDK does not allow one to update the icon on the home screen during runtime (at least that is what I read here on the board when attempting to do that), instead you have to use the notification layer and post a message to the title bar. On the other hand, if you are attempting to change an image/icon inside of the app, this is pretty standard. Just grab the current ImageButton and call .setImageResource(int resource id). Now, if you are getting fancy and just adding a badge or something, it will be slightly more complicate, but this should get you up in the right direction. Take a look at the draw() methods as well Does that help? Kevin On Oct 26, 12:20 pm, Kyle [EMAIL PROTECTED] wrote: Hello, I'm trying to find a way to programmatically change a drawable resource within my application so that I can display this updated icon as a notification. Would this be possible? If not is there another way to go about doing something like this? I figured a notification object might be able to take a bitmap or drawable but it looks like you can only pass a resource id. Thanks for any help. Kyle --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Why Android Market does not accept payments from China?
Hmmm, I don't see a link to register android apps on there, am I missing something? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: G1 GPS receiver turn on and turn off
Just guessing here, but have you checked the system configuration DB? On Oct 26, 9:34 pm, hdk [EMAIL PROTECTED] wrote: Hi, I would like to control the GPS receiver via software. Simple turn on and turn off. Has anyone done it? I imagine that T-Mobile/HTC would have to share G1 specific SDK to accomplish that, am I right? Thanks, hdk --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How fast is the T-Mobile G1?
Has anyone ever done a speed test on this phone yet, so we know exactly how many bogomips it can do? Starting a shell and typing: cat /proc/cpuinfo should give the answer. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: EditText
and you don't find a solution? On Oct 27, 12:59 am, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I was wondering the same thing yesterday. I'm trying to make minor changes to the notepad tutorial and this was one of them! --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Why Android Market does not accept payments from China?
There is a link on the right side of market.android.com saying: Interested in having your application in Android Market? Learn more On 27 Paź, 16:53, InC [EMAIL PROTECTED] wrote: Hmmm, I don't see a link to register android apps on there, am I missing something? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Why Android Market does not accept payments from China?
Sorry for double post but here's the direct link: http://market.android.com/publish On 27 Paź, 17:16, Wiktor [EMAIL PROTECTED] wrote: There is a link on the right side of market.android.com saying: Interested in having your application in Android Market? Learn more On 27 Paź, 16:53, InC [EMAIL PROTECTED] wrote: Hmmm, I don't see a link to register android apps on there, am I missing something? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: EditText
android:gravity=top|left On Oct 27, 2008 9:19 AM, jphdsn [EMAIL PROTECTED] wrote: and you don't find a solution? On Oct 27, 12:59 am, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I was wondering the same thin... --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How fast is the T-Mobile G1?
$ cat /proc/cpuinfo Processor : ARMv6-compatible processor rev 2 (v6l) BogoMIPS: 245.36 Features: swp half thumb fastmult edsp java CPU implementer : 0x41 CPU architecture: 6TEJ CPU variant : 0x1 CPU part: 0xb36 CPU revision: 2 Cache type : write-back Cache clean : cp15 c7 ops Cache lockdown : format C Cache format: Harvard I size : 32768 I assoc : 4 I line length : 32 I sets : 256 D size : 32768 D assoc : 4 D line length : 32 D sets : 256 Hardware: trout Revision: 0080 Serial : $ On Oct 27, 9:04 am, PorkChop [EMAIL PROTECTED] wrote: Has anyone ever done a speed test on this phone yet, so we know exactly how many bogomips it can do? Starting a shell and typing: cat /proc/cpuinfo should give the answer. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Google maps not working on G1
When I install this on my phone, all I see is a blank grid, no map. Does anyone see any errors? It works fine when I run it in the emulator with the debug maps api key but not on the phone with the release maps api key. thanks Nick GoogleMap.java package com.websmithing.googlemap; import com.google.android.maps.MapController; import com.google.android.maps.MapView; import com.google.android.maps.GeoPoint; import com.google.android.maps.MapActivity; import android.os.Bundle; import android.view.KeyEvent; public class GoogleMap extends MapActivity { private MapView mapView; private MapController mc; /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); mapView = (MapView) findViewById(R.id.mapview1); mc = mapView.getController(); String coordinates[] = {47.47, -122.01}; double lat = Double.parseDouble(coordinates[0]); double lng = Double.parseDouble(coordinates[1]); GeoPoint p = new GeoPoint( (int) (lat * 1E6), (int) (lng * 1E6)); mc.animateTo(p); mc.setZoom(17); mapView.invalidate(); } @Override protected boolean isRouteDisplayed() { // TODO Auto-generated method stub return false; } public boolean onKeyDown(int keyCode, KeyEvent event) { switch (keyCode) { case KeyEvent.KEYCODE_3: mc.zoomIn(); break; case KeyEvent.KEYCODE_1: mc.zoomOut(); break; } return super.onKeyDown(keyCode, event); } } main.xml ?xml version=1.0 encoding=utf-8? LinearLayout xmlns:android=http://schemas.android.com/apk/res/ android android:orientation=vertical android:layout_width=fill_parent android:layout_height=fill_parent com.google.android.maps.MapView android:id=@+id/mapview1 android:layout_width=fill_parent android:layout_height=fill_parent android:enabled=true android:clickable=true android:apiKey=my_release_api_key / /LinearLayout AndroidManifest.xml ?xml version=1.0 encoding=utf-8? manifest xmlns:android=http://schemas.android.com/apk/res/android; package=com.websmithing.googlemap android:versionCode=1 android:versionName=1.0.0 application android:icon=@drawable/icon android:label=@string/ app_name uses-library android:name=com.google.android.maps / activity android:name=.GoogleMap android:label=@string/app_name intent-filter action android:name=android.intent.action.MAIN / category android:name=android.intent.category.LAUNCHER / /intent-filter /activity /application uses-permission android:name=android.permission.ACCESS_FINE_LOCATION / uses-permission android:name=android.permission.INTERNET / /manifest --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] GridView Selector Padding
How do you change the padding on the GridView selector? With the default settings, the selector is wider than my column width. I could use setSelector but I would rather not muck with the default functionality. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Documents supported on Android
Hi, is there any way to open files .pdf, .doc, .ppt, .odt ... with Android? 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
the 40 ms in your example contain creating a new GestureDetector (which you don't do when you switch within your activity), and packing and retrieving the start value into an intent extra. that's exactly the point. Not only the GestureDetector, but you have to create the whole application frame and each component entirely new if you start a new Activity. This example is rather light-weight. I guess that the performance difference increase the more complex the new screen becomes. By the way- 40ms is the minimumit goes up to 106ms (average maybe 60 ms). The GestureDetector is the best example. Things like this have to be created again and again in the new Activities which cost a lot of efficience. If you take setContentView(view), it is enough to use single object of GestureDetector for every views. With a single variable you can provide GestureDetector-Access to the view which is active and lock it for all the others. Packing and retrieving the extra gives the application additional value (because your activity may communicate with 3rd party) maximally 1-2 ms i'd give for that. This is very very light-weight compared to the other operations. In this case it doesn't communicate with 3rd party activity. Static long instead of long is also nearly no difference. That is comparable if you use an ArrayListInteger instead of int[ ] in regular Java. I've tried it once, and the difference is 0ms. The timer resolution is not enough to register that :-) --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Run function when EditText text changed
So that's how I use the TextWatcher...Ok, it works perfectly! Thanks tauntz! (Am I correct in assuming this is how to use the tabHost.setOnTabChangeListener()?) On Oct 26, 12:39 pm, tauntz [EMAIL PROTECTED] wrote: http://code.google.com/android/reference/android/widget/TextView.html...) Example: editText.addTextChangedListener(new TextWatcher() { public void afterTextChanged(Editable s) { //XXX do something } public void beforeTextChanged(CharSequence s, int start, int count, int after) { //XXX do something } public void onTextChanged(CharSequence s, int start, int before, int count) { //XXX do something } }); Tauno On Sun, Oct 26, 2008 at 9:33 PM, David [EMAIL PROTECTED] wrote: I want to run a function when the text in an EditText is changed. How would I 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Starting new Activity vs. setContentPane(newView)
By the way, I've also tried a version where I deleted GestureDetector and the whole onGestureListener -stuff from Second.java... The result was a minimum of 36ms...mostly it was 42 or 45ms. The peak lowered a little bit. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Android App Store
Was wondering if its possible to run the Android App Store application on the emulator. I'd like to browse the store and see what apps are available w/o having to buy the phone. I checked out the GIT repository, but don't see the App store application in there. I'm guessing Google is keeping that closed. :( Would be nice if they at least provided us with the application in the emulator. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How fast is the T-Mobile G1?
how did you get a command line prompt on the phone? On Oct 27, 12:52 pm, shyamal [EMAIL PROTECTED] wrote: $ cat /proc/cpuinfo Processor : ARMv6-compatible processor rev 2 (v6l) BogoMIPS : 245.36 Features : swp half thumb fastmult edsp java CPU implementer : 0x41 CPU architecture: 6TEJ CPU variant : 0x1 CPU part : 0xb36 CPU revision : 2 Cache type : write-back Cache clean : cp15 c7 ops Cache lockdown : format C Cache format : Harvard I size : 32768 I assoc : 4 I line length : 32 I sets : 256 D size : 32768 D assoc : 4 D line length : 32 D sets : 256 Hardware : trout Revision : 0080 Serial : $ On Oct 27, 9:04 am, PorkChop [EMAIL PROTECTED] wrote: Has anyone ever done a speed test on this phone yet, so we know exactly how many bogomips it can do? Starting a shell and typing: cat /proc/cpuinfo should give the answer. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] question about IBinder.queryLocalInterface()
In Binder.java, public void attachInterface(IInterface owner, String descriptor) { mOwner = owner; mDescriptor = descriptor; } /** * Attempt to retrieve a local implementation of an interface * for this Binder object. If null is returned, you will need * to instantiate a proxy class to marshall calls through * the transact() method. */ public IInterface queryLocalInterface(String descriptor) { if (mDescriptor.equals(descriptor)) { return mOwner; } return null; } In ISms.java generated by ISms.aidl and AIDL tool, public Stub() { this.attachInterface(this, DESCRIPTOR); } The function attachInterface(IInterface owner, String descriptor) will be invoked whenever the object of ISms.Stub or the classes that extend it. So it seems that the function queryLocalInterface(String descriptor) will not return null forever. However, the comments said that it will return null if the Binder is not a local one. Does anybody know anything I missed? Thanks in advance! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Cell IDs by cell phones
Hello all, Is there any chance that the cell phone may have information about ALL the cell ids that it can sense. I know that I can get the cell id of the tower I'm connected to, but can I get the cell ids of other cell towers in my area??? --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How fast is the T-Mobile G1?
I don't own a phone (I'm in Canada), but the serial shouldn't be zeroed out, should it? On Oct 27, 9:52 am, shyamal [EMAIL PROTECTED] wrote: $ cat /proc/cpuinfo Processor : ARMv6-compatible processor rev 2 (v6l) BogoMIPS : 245.36 Features : swp half thumb fastmult edsp java CPU implementer : 0x41 CPU architecture: 6TEJ CPU variant : 0x1 CPU part : 0xb36 CPU revision : 2 Cache type : write-back Cache clean : cp15 c7 ops Cache lockdown : format C Cache format : Harvard I size : 32768 I assoc : 4 I line length : 32 I sets : 256 D size : 32768 D assoc : 4 D line length : 32 D sets : 256 Hardware : trout Revision : 0080 Serial : $ On Oct 27, 9:04 am, PorkChop [EMAIL PROTECTED] wrote: Has anyone ever done a speed test on this phone yet, so we know exactly how many bogomips it can do? Starting a shell and typing: cat /proc/cpuinfo should give the answer. --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] IMAP Email message body is null
Not sure if this is where bug reports go, but in lieu of a known tracking mechanism here's my bug: Synopsis: IMAP Email message body is null Platform: T-Mobile G1 Issue: Using IMAP Email client, some messages contain a body consisting of the word null. This is using the Sun Java System Messaging Server. The issue does not happen on all emails, just mail from a particular sender; usually the sender is from an automated email system, such as Clarify or Radiance. Notes: Viewing the same emails from Thunderbird show the whole message. Thanks, Brian --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Anyone mind testing quickly?
On a similar note: Would anybody mind testing this application on a real phone: http://grocerylist.schuemie.net It is a simple grocery list application (freeware). I live in Europe, and it will be some time before I get to buy an Android phone! On Oct 27, 6:40 am, Nate Sanden [EMAIL PROTECTED] wrote: Anyone mind testing this on a real phone for me (before the marketplace launch tomorrow)? It's a basic tip calculator. The main thing I'm not sure will work are the blue arrow buttons to the right of the text fields. You should be able to touch them to modify values in the calculator. Appreciate it! http://satipcalculator.googlecode.com/files/sa_tip_calculator.apk --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Documents supported on Android
Not yet. The best way is to email them to your Gmail account and have it parse it into HTML, but its really poor. You can't modify it either. Hopefully, someone is working on an editor. I just don't have the experience to code it yet. (where is Google Docs on Android? C'mon Google!) Andrew On Oct 27, 12:56 pm, Jose Alonso [EMAIL PROTECTED] wrote: Hi, is there any way to open files .pdf, .doc, .ppt, .odt ... with Android? 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Anyone mind testing quickly?
I (and others) can help out with G1 testing of the applications stocked to SlideME: http://slideme.org. Thanks, Shane On Mon, Oct 27, 2008 at 8:48 AM, Martijn Schuemie [EMAIL PROTECTED]wrote: On a similar note: Would anybody mind testing this application on a real phone: http://grocerylist.schuemie.net It is a simple grocery list application (freeware). I live in Europe, and it will be some time before I get to buy an Android phone! On Oct 27, 6:40 am, Nate Sanden [EMAIL PROTECTED] wrote: Anyone mind testing this on a real phone for me (before the marketplace launch tomorrow)? It's a basic tip calculator. The main thing I'm not sure will work are the blue arrow buttons to the right of the text fields. You should be able to touch them to modify values in the calculator. Appreciate it! http://satipcalculator.googlecode.com/files/sa_tip_calculator.apk --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: G1 GPS receiver turn on and turn off
It's not in android.provider.Settings.System where I suspected it would be. I also searched the SDK and it has no references to GPS anywhere in it. LIke I mentioned before: it looks like we are missing certain control capabilities that are specific to HTC implementation. Thanks, hdk On Oct 27, 10:54 am, nkijak [EMAIL PROTECTED] wrote: Just guessing here, but have you checked the system configuration DB? On Oct 26, 9:34 pm, hdk [EMAIL PROTECTED] wrote: Hi, I would like to control the GPS receiver via software. Simple turn on and turn off. Has anyone done it? I imagine that T-Mobile/HTC would have to share G1 specific SDK to accomplish that, am I right? Thanks, hdk --~--~-~--~~~---~--~~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---