[android-developers] how to create thumbnail generated after ending video recording
In 1.5, is there any API I can used to generate Video thumbnail? Thanks! Cindy --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: 30 Days of Android Applications
The source for day 17 and 18 are missing... Keep up the good work, only 8 days left! -John Coryat --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How can LinearLayout know child's focusable?
Hi. Expert! I have a LinearLayout that have 4 buttons children. so I like to know whether my button is focusable or not when I press a arrow key. and I like to know whether my button is clicked or not when I click a child button. LinearLayout.onFocusChanged function is not called when child has focus. So I tried to find it. below code is my difficult and dirty solution. in below code, I should call button.setOnFocusChangeListener and button.setOnClickListener on every child button. If I have a hundred button, I should call button.setOnFocusChangeListener. and I don't need to know what button is exactly focuschanged. I just need to know whether my child buttons is focusChanged or not. and what is a clear and simple solution? LinearLayout xmlns:android=http://schemas.android.com/apk/res/ android android:id=@+id/layout1 android:layout_width=fill_parent android:layout_height=fill_parent android:orientation=vertical com.windriver.Test.MyLayout android:id=@+id/layout2 android:layout_width=wrap_content android:layout_height=wrap_content android:orientation=horizontal android:focusable=true /com.windriver.Test.MyLayout Button android:layout_width=wrap_content android:layout_height=wrap_content android:text=@string/app_name android:focusable=true / /LinearLayout public class MyLayout extends LinearLayout implements View.OnFocusChangeListener, View.OnClickListener { static final String TAG = MyLayout; public MyLayout (Context context) { this (context, null); } public MyLayout (Context context, AttributeSet attrs) { super (context, attrs); LayoutParams lp = new LayoutParams (LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT); Button button; for (int i = 0; i 4; i++) { button = new Button (context); button.setText (String.format (Button %d, i)); button.setOnFocusChangeListener (this); button.setOnClickListener (this); addView (button, lp); } } protected void onFocusChanged (boolean gainFocus, int direction, Rect prevRect) { Log.v (TAG, onFocusChanged); - this function is not called!!! why? } public void onFocusChange (View v, boolean hasFocus) { Log.v (TAG, Button FocusChanged!); } public void onClick (View v) { Log.v (TAG, Button Clicked!); } } --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: OnSharedPreferenceChangeListener not listening anymore in 1.5??
I tried implementing OnSharedPreferenceChangeListener as well (1.5_r2) and could not get it to work. Since I never had working code in a prior Android version, this could be due to a mistake in my coding. However, I just switched to using onPreferenceChangeListener() and it worked fine... Jim On Jun 22, 10:55 pm, Dave srandls...@gmail.com wrote: I have an app that has been out there on the market for months. I rebuilt for 1.5 a while ago and things seemed fine, but now that I have 1.5 actually on my phone I and some of my users have noticed a difference in the handling of preferences. In my OnCreate() I read the preferences and register an OnSharedPreferenceChangeListener. Prior to 1.5, if I changed apreferencethe listener worked fine and updated thepreference immediately. After 1.5 this is no longer working. It appears my listener never gets called, so the new settings only apply on the next run (i.e. the next time OnCreate gets called). Here's a code snippet: public void onCreate(Bundle savedInstanceState) { SharedPreferences settings = getSharedPreferences(PREFS_FILE, 0); mUseGPSAccuracy = settings.getBoolean(USE_GPS_ACCURACY, false); settings.registerOnSharedPreferenceChangeListener( new SharedPreferences.OnSharedPreferenceChangeListener() { public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) { if (key.equalsIgnoreCase(USE_GPS_ACCURACY)) { mUseGPSAccuracy = sharedPreferences.getBoolean(USE_GPS_ACCURACY, false); } } }); So in this example, a change in the USE_GPS_ACCURACYpreferenceis read on startup correctly, but the listener is no longer called to change thepreferencewhile the application is running. Does anyone have some insight as to why this has changed in 1.5 and what the remedy is? As I said, prior to 1.5, this code worked fine. Thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Multiselect List View and Key Event
Hi All, I have the Multi select list view in my project. Here i am using the custom adapter to build the list view. The code as follows, public static class EfficientMultiSelectionAdapter extends ArrayAdapterString implements CompoundButton.OnCheckedChangeListener { public EfficientMultiSelectionAdapter(Context context, int resource, String[] objects) { // My code here } public void onCheckedChanged(CompoundButton buttonView, boolean isChecked){ // My code here. } } Using this code i am able to get the mouse event. That means if i touch the list view, i am able to see the checked and unchecked action. I know it is using the CompoundButton event. But if i use key pad enter key, i am not able to get the same action. So can any one tell me how to handle this event. Thanks in advance, Muthu Kumar K. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: INSTALL_FAILED_SHARED_USER_INCOMPATIBLE in 1.0 and 1.5
Thanks. On Jun 26, 1:25 pm, Dianne Hackborn hack...@android.com wrote: There was a bug in 1.5 with this, that was fixed in the most recent security update. You apparently aren't running a system with that security update. On Thu, Jun 25, 2009 at 8:53 PM, hunter jun.hun...@gmail.com wrote: Hi, all: I have a application with android:sharedUserId=android.uid.system in its AndroidManifest.xml. This application is not signed with the platform key. In 1.0, I use adb install to install it but failed with INSTALL_FAILED_SHARED_USER_INCOMPATIBLE which is OK because it is not signed with the proper key. But in 1.5, I successfully installed this application and it worked well. Can anyone tell me why? Thanks. -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Sensor and Compass APIDemo failing on emulator 1.5
On Wed, May 27, 2009 at 1:40 PM, sarang sarangd...@gmail.com wrote: Is this a bug in emulator 1.5 ? Yes, it's a known bug in the 1.5 emulator which will be fixed in the next SDK release. However, what others have mentioned is true, there is little you will be able to do in the emulator anyway; this is the kind of thing that requires a real device for proper testing. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: RFCOMM API
Hi, i was working with last cupcake release las week and i recompiled it to use RFCOMM API in my dev phone. i can say that status is yet unestable, something sockets don't free resources on destroy method is invocated and application crashes when it tried reopen it. You can see a demo in http://openhealth.morfeo-project.org/ I remember you that the API is in development process yet and i can see that it goes to the rigth way, i hope that we can see it in android official branche in next months :) Long escribió: Hi, What is the latest status of the RFCOMM support in android? I'd like to write an application using RFCOMM to communicate with PC. I don't want to rebuild a custom image. I just want my application can run on a HTC Magic. Is that doable now? I heard of there is an application bluex can transfer files with obex. Obex is based on RFCOMM. So that indicates the rfcomm should be OK. But i am confused because lots of post on the list say RFCOMM is not ready yet. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: RFCOMM API
I'm also waiting for RFCOMM to be released. I'm thinking about implementing something over it for events to come up on the PC, quote tipical but yet useful. do you know if there's something similar over usb already done? any recommendation about a craddle for magic? greets! El 26 de jun de 2009, 9:24 a.m., Santi sanc...@gmail.com escribió: Hi, i was working with last cupcake release las week and i recompiled it to use RFCOMM API in my dev phone. i can say that status is yet unestable, something sockets don't free resources on destroy method is invocated and application crashes when it tried reopen it. You can see a demo in http://openhealth.morfeo-project.org/ I remember you that the API is in development process yet and i can see that it goes to the rigth way, i hope that we can see it in android official branche in next months :) Long escribió: Hi, What is the latest status of the RFCOMM support in android? I'd like to write an app... --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] xml write
HI I can't find it(method) in class xmlpullparser. I would like to write attributes in res/xml/*.xml. maybe, I use the other parser. follow that is samplecode. / InputStream stream = cn.getInputStream(); DocumentBuilder docBuild = DocumentBuilderFactory.newInstance ().newDocumentBuilder(); Document manifestDoc = docBuild.parse(stream); ... ... ... How can I use res/xml/*.xml, instead of stream ? (the stream is urlconnection, ) is possible? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Wi Fi connection
hi all... im trying to connect to a secured wifi network.. through wifi manager i am able to scan for results... now how do i connect to it programmatically... meaning how do i get the network configuration details...and then connect to it.. hope im clear..kindly help! thanks in advance!! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] scalable vector graphics
hola, i think the answer is no.. but want to make sure. Does the current API support scalable vector graphics? If so which file formats? If not, will it be added in the future? I ask because I'd like my animations to based off of SVGs - in order to better support different screen resolutions while reducing file size. Thanks! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Paid applications and market feedback/rating
I was searching for an easy way to implement trial and paid versions. This seems like an ideal solution. Gonna try it out. Has anyone out there tried this? How did it work out? On Sat, May 9, 2009 at 10:42 AM, mirko mirkocze...@googlemail.com wrote: Hi all, as in a few weeks it will be possible to sell application from germany I was thinking some time to keep my currently free version and offer an enhanced paid version. I only wanted to support one version of code. The idea was to have a preference setting to enable the paid options in the code. So I tried to get a secure way to set this preference. In my opinion the above shown way works, but everyone can just write a package that meets the package name of the license and install it. To get access to the private preference of the free version of the program, I will use signature based permission and a very easy content provider. These steps will lead to a full version: 1. Install the free version 2. Install the licensing application for the free version. This one needs to have the same signature as the free version. 3. When starting the paid app, it gets the simple content provider from the free app (secured with signature based permissions) and sets the flag for the license in the preferences of the free app 4. You can use the free app with all features. 5. After 24 hours the license app has to be run again to make sure it was not refunded. (can be done automatically with an intent) 6. The license app may be uninstalled to safe memory What do you think about this approach? Did I miss anything? Any huge security leaks? If this work I will publish the code for the licensing app so that every app can get the same licensing behaviour. @Google: Btw, I think the best thing would be to handle such licensing within the market, because this would be the easiest for the user. Until this is done we have to do such workarounds. Mirko On 17 Mrz., 16:56, StefanK skyntc...@gmail.com wrote: There is probably a possibility to still keep the ratings if you leave the app free, let it expire (or go to a limited functionality after a several days or so). If users want to get it back to full features - they have to buy an unlock key. The unlock key is nothing more than a paid application that has no functionality. Your free application will just have to check if the paid is installed and unlock itself. This approach (if possible) has lots of advantages: 1. You can keep the ratings from the free app 2. You support only one app (not free and paid). 3. You can give your users potentially longer trial than the 24 hours Google allows. 4. No need to port settings from the free to the paid one. 5. You potentially avoid issues with crashes caused by copy protection as you will copy protect only the paid app that has not real functionality, This is a bit unconventional approach, but it may work. On Mar 16, 7:44 pm, Keith Wiley kbwi...@gmail.com wrote: I don't *think* that's possible. Assuming the signature/package is tied to the market app, there is no way to convert a previously free app to a paid app. A brand new app must be installed instead, if I've understood thing so far. I think a new app must have a new package and an old app can't be changed from free to paid. Can anyone clarify or straighten this out for us? On Mar 16, 4:26 pm, sm1 sergemas...@gmail.com wrote: I'm not 100% sure but if my understanding of how Android Market works is correct, what you may want to do is keep the same package (aka. signature) for your paid app as the package that you had before, with the comments and ratings, and make a *new* package for the free app., and the new free app will start at zero comments and zero ratings, but you could write about that in it's description, i.e., previous version had a rating of x stars. and you could verify it by posting on this forum: http://www.google.com/support/forum/p/Android+Market Let us know what you find. cheers, good luck with your app. On Mar 16, 11:02 am, Keith Wiley kbwi...@gmail.com wrote: I have had a free version of my app available for several months. With the new features I am about to release in the latest version, and with paid apps now possible, I intend to split the app into a free lite/trial version and a paid full version. I am aware that I must create a new app with a new signature for the full version b/c I can't change the current free app to a paid one. I don't mind this, but, is there any way I can transfer the thousands of feedback and ratings I have accumulated so far to the paid version even though it will have a totally new signature? If there is no way to do this then, permit me to say, I am a little miffed. :-/ ...but I'm holding out hope that I missed this somewhere, that's it's
[android-developers] RIL and datacall (CSD)
Hello I tried to establish datacall between android phone and other phone, and I failed. AFAIK, CSD is recognized using %CPI (call progress infromation), looking in reference-ril.c:onUnsolicited it seems that RIL handle following unsolicited commands: * CTZV: Unsolicited result code for time zone change events * CRING, RING, NO CARRIES, CCWA: - ringing, call waiting * CMT: Notification of a directly delievered SMS message * CREG: network registration * CDS: sms * CGEV: gprs So, current RIL and probably jave framework can not recognize datacall also framework does not support this. Is there any plan for extending this functionality? From my point of view this functionality is must, what is proper way for extending SW? Best regards Mile --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] oprofile usage with dalvik vm
Hi all, I want to try profiling on android using oprofile but I am not sure if it comes support for dalvik vm. Has anybody tried the same? If this doesn't click then I can try using traceview and oprofile separately. Thanks, JJ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] publishing an app that uses online service on android market
Hello, Assuming that I am planning on publishing an application on the android market, one that uses an online service. Do I need to guarantee that this service will be running for a specific amount of time? What happens if after a while my application hasn't made enough money to cover expenses of server, maintenance of database etc and I decide to shut it down? What happens then if the few people that have actually bought my app ask for a refund? Will they be granted the refund? Would I be able to mention in a disclaimer or something that this online service is guaranteed to be running for six months or something like this? 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Finding a particular intent in the whole system(packet manager)
Hi All, I have a query to ask.This piece of code i have come across in one of the posts (http://android-developers.blogspot.com/search/label/How-to by Romain Guy ) in which author has said simple way to find out whether the system contains any application capable of responding to the intent you want to use. public static boolean isIntentAvailable(Context context, String action) { final PackageManager packageManager = context.getPackageManager(); final Intent intent = new Intent(action); ListResolveInfo list = packageManager.queryIntentActivities(intent, PackageManager.MATCH_DEFAULT_ONLY); return list.size() 0; } But this code is working only if my androidmanifest.xml file has the particular intent{isIntentAvailable(this,action = (com.android.)--this string is defined as intent filter in my androidmanifest.xml )}. However this is not working if i am trying to find out an intent which is in some other apk and this other apk is installed in my system.Can i do this using the code shown above or it is not possible? regards, ani --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] SQL Query
Hi Folks, How do i select only one particular row sort by a column using a sqlite query in Android?? Regards, Manjunatha --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Repo error
Dear All, This was due to the error in the repo file which was not downloaded correctly. After getting the correct repo file, repo was initialized successfully Regards Sivan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] value @ /sys/class/lightsensor/switch_cmd/lightsensor_file_cmd is getting lost
Hi, I am storing a byte stream @ /sys/class/lightsensor/switch_cmd/lightsensor_file_cmd but on reboot, the value over here is getting lost. How do i recover Xie xie. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How to use a library in Android source and to write application on top of that
Hi All, I have written a new library following the given sample liberary in / development/sample/PlatformLibrary I have properly compiled it. It properly gets compiled without any errors it build binaries are vailable in below mentioned locations. ./symbols/system/lib/ ./obj/lib/ Binary file ./obj/SHARED_LIBRARIES/native_lib_jni_intermediates/LINKED/ native_lib_jni.so matches ./obj/SHARED_LIBRARIES/native_lib_jni_intermediates/ But it is not available in system.img When I copy all these img images to SDK and try to call these API in my own application It gives a error about the library namespace Please guide me where to put this library in source code to get it or is there any macro or setting by applying which we can get all sample folder apps/libraries in system.img Regards, Arun achoudhary2...@gmail.com --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Update message - how to check whether app has run before?
Actually, I have realised that won't work, because it will also show the first time the app is installed. It should only show upon update. So, the question still stands. How can I check whether a user has just installed an update, in order to show an update message? Any ideas anyone? Thanks, Anna On Jun 25, 5:17 pm, Anna PS annapowellsm...@googlemail.com wrote: Hi all, I want to show anupdatemessagefor a new release - the first time the user opens the updated version of my app, a pop-up dialog should appear, saying what's new, with an OK button. After the user has read it once, it shouldn't appear again. Is there any inbuilt Android variable I can check to see whether the user has opened the app before? Of course, I can define my own boolean in the app settings (hasUserSeenUpdateMessage) to check each time the app runs - setting it to false initially, and then true when the user clicks OK. Just wondered if there was a slightly more sophisticated way of doing it, or if that's the way to go :) thanks! Anna --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] ACTION_TIME_TICK for every Second required.
ACTION_TIME_TICK occurs every minute. I need an action which will occur every second because I'm trying to display the 'Seconds' needle in AppWidget. Do help me even if it means modifying the framework source code. ACTION_TIME doesn't occurs it's docs are not clear. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: how to receive call and play media file
Thanks for your reply. But can't i play in the way so only caller can listen it. The receiver do not need to listen it. On Jun 22, 10:41 pm, Marco Nelissen marc...@android.com wrote: Sorry, there are too many messages to this list to keep up. The built-in apps do pause when a call comes in, however there is nothing preventing you from restarting them or playing a sound while a call is in progress (which you would have discovered had you simply tried it). On Mon, Jun 22, 2009 at 4:07 AM, Honest honestsucc...@gmail.com wrote: No Reply ? On Jun 17, 11:29 am, Honest honestsucc...@gmail.com wrote: Thanks Marco for your quick reply.But some one told me tha all application running in background become pause when we receive call so is that true ? if that is true then how can i play audio file when call is running on ? hope some quick reply. On Jun 15, 8:08 pm, Marco Nelissen marc...@android.com wrote: The current platform and hardware do not support playing audio in to the phone conversation. The best you could do is play it through the speaker really loud, and hope the other side can hear it. On Sun, Jun 14, 2009 at 10:16 PM, Honest honestsucc...@gmail.com wrote: Hi, I want to develop application in which i want to listen call and play medial file so caller can listen it. Can some one tell me how can i do it ? any code snippt or link of resource. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: ACTION_TIME_TICK for every Second required.
why don't you simply write a service and send your own broadcast intent as often as you want? Peli www.openintents.org On Jun 26, 12:46 pm, Ravi ravikumar...@gmail.com wrote: ACTION_TIME_TICK occurs every minute. I need an action which will occur every second because I'm trying to display the 'Seconds' needle in AppWidget. Do help me even if it means modifying the framework source code. ACTION_TIME doesn't occurs it's docs are not clear. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Finding a particular intent in the whole system(packet manager)
This code works regardless in which package the action is located. The only improvement I would suggest is to change the last argument form String action to Intent intent and omit the line final Intent intent = new Intent(action); Then you can search for arbitrary intents that you want to launch, including those that use data or a mime type. (here is the modified source: http://code.google.com/p/openintents/source/browse/trunk/NotePad/src/org/openintents/util/IntentUtils.java ) Peli www.openintents.org On Jun 26, 11:02 am, ani anish198519851...@gmail.com wrote: Hi All, I have a query to ask.This piece of code i have come across in one of the posts (http://android-developers.blogspot.com/search/label/How-to by Romain Guy ) in which author has said simple way to find out whether the system contains any application capable of responding to the intent you want to use. public static boolean isIntentAvailable(Context context, String action) { final PackageManager packageManager = context.getPackageManager(); final Intent intent = new Intent(action); ListResolveInfo list = packageManager.queryIntentActivities(intent, PackageManager.MATCH_DEFAULT_ONLY); return list.size() 0; } But this code is working only if my androidmanifest.xml file has the particular intent{isIntentAvailable(this,action = (com.android.)--this string is defined as intent filter in my androidmanifest.xml )}. However this is not working if i am trying to find out an intent which is in some other apk and this other apk is installed in my system.Can i do this using the code shown above or it is not possible? regards, ani --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Sensor and Compass APIDemo failing on emulator 1.5
Unless of course one has a sensor simulator :-) http://code.google.com/p/openintents/wiki/SensorSimulator (I should mention that we did not have time yet to upgrade it to SDK 1.5, but some people already got this to work in the 1.5 emulator). I'd say simulating the sensors in this way can be quite useful if one wants to work out the basic trigonometric relations (which vectors correspond to which orientation, etc.), just as it is useful to test touch interfaces in the emulator with the mouse, or to think through a user interface with pen and pencil. Of course, nothing replaces testing on the real device in the end. Peli www.openintents.org On Jun 26, 9:19 am, David Turner di...@android.com wrote: On Wed, May 27, 2009 at 1:40 PM, sarang sarangd...@gmail.com wrote: Is this a bug in emulator 1.5 ? Yes, it's a known bug in the 1.5 emulator which will be fixed in the next SDK release. However, what others have mentioned is true, there is little you will be able to do in the emulator anyway; this is the kind of thing that requires a real device for proper testing. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Sensor and Compass APIDemo failing on emulator 1.5
Actually, the sensor code I had written with the SensorSimulator ( http://code.google.com/p/openintents/wiki/SensorSimulator ) before any Android hardware was available publicly, worked perfectly on the G1 when it came out - apart from the known issues with the wrong orientation sensor values that are returned by the G1 hardware :-) It is one of the reasons that kept me from updating the SensorSimulator so far: I wanted to include a G1 compatibility mode that reproduces the wrong G1 readings for orientation - but it is a very ungrateful task (it is not so trivial to simulate exactly the same wrong readings), but unless this is done, I am slightly hesitant to call it a true sensor simulator... It should be mentioned that accelerometer and magnetic compass values are fine - only the calculated orientation values on the G1 had some issues. Peli www.openintents.org On Jun 26, 3:32 am, Dianne Hackborn hack...@android.com wrote: But also, there is no way you are going to be able to implement a working app like this without doing it on real hardware. It would be kind-of like trying to implement a touch user interface without a touch screen. :) On Thu, Jun 25, 2009 at 10:05 AM, Mark Murphymmur...@commonsware.com wrote: Is there any update on this? I need to build a compuss application but the API Demo doesn't work in the emulator. You will need actual hardware to test sensor-related applications. Partly, this is due to the emulator bug. -- Mark Murphy (a Commons Guy) http://commonsware.com Android App Developer Books:http://commonsware.com/books.html -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Sensor and Compass APIDemo failing on emulator 1.5
Firstly, openIntents sensor simulator is a very good tool for compass applications. I have used it without any breakage.. Further,, the compass bug in 1.5 r1 is FIXED in SDK 1.5 r2. Go ahead, there's no breakage now. Cheers. Peli wrote: Unless of course one has a sensor simulator :-) http://code.google.com/p/openintents/wiki/SensorSimulator (I should mention that we did not have time yet to upgrade it to SDK 1.5, but some people already got this to work in the 1.5 emulator). I'd say simulating the sensors in this way can be quite useful if one wants to work out the basic trigonometric relations (which vectors correspond to which orientation, etc.), just as it is useful to test touch interfaces in the emulator with the mouse, or to think through a user interface with pen and pencil. Of course, nothing replaces testing on the real device in the end. Peli www.openintents.org On Jun 26, 9:19 am, David Turner di...@android.com wrote: On Wed, May 27, 2009 at 1:40 PM, sarang sarangd...@gmail.com wrote: Is this a bug in emulator 1.5 ? Yes, it's a known bug in the 1.5 emulator which will be fixed in the next SDK release. However, what others have mentioned is true, there is little you will be able to do in the emulator anyway; this is the kind of thing that requires a real device for proper testing. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Update message - how to check whether app has run before?
The way you suggested, but add versionCode to the setting name. On Jun 26, 12:40 pm, Anna PS annapowellsm...@googlemail.com wrote: Actually, I have realised that won't work, because it will also show the first time the app is installed. It should only show upon update. So, the question still stands. How can I check whether a user has just installed an update, in order to show an update message? Any ideas anyone? Thanks, Anna On Jun 25, 5:17 pm, Anna PS annapowellsm...@googlemail.com wrote: Hi all, I want to show anupdatemessagefor a new release - the first time the user opens the updated version of my app, a pop-up dialog should appear, saying what's new, with an OK button. After the user has read it once, it shouldn't appear again. Is there any inbuilt Android variable I can check to see whether the user has opened the app before? Of course, I can define my own boolean in the app settings (hasUserSeenUpdateMessage) to check each time the app runs - setting it to false initially, and then true when the user clicks OK. Just wondered if there was a slightly more sophisticated way of doing it, or if that's the way to go :) thanks! Anna --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: xml write
I already answered your question the first time you asked it. On Jun 26, 9:41 am, brilliant winger stw...@gmail.com wrote: HI I can't find it(method) in class xmlpullparser. I would like to write attributes in res/xml/*.xml. maybe, I use the other parser. follow that is samplecode. / InputStream stream = cn.getInputStream(); DocumentBuilder docBuild = DocumentBuilderFactory.newInstance ().newDocumentBuilder(); Document manifestDoc = docBuild.parse(stream); ... ... ... How can I use res/xml/*.xml, instead of stream ? (the stream is urlconnection, ) is possible? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: xml write
Or actually, I see you're asking a different question, although it doesn't make sense this time. XmlPullParser, as the name suggests, pulls and parses, so it's got nothing to do with writing. You can't write to the resource because that would be modifying the apk and thus breaking the signature. On Jun 26, 1:55 pm, Neil neilb...@gmail.com wrote: I already answered your question the first time you asked it. On Jun 26, 9:41 am, brilliant winger stw...@gmail.com wrote: HI I can't find it(method) in class xmlpullparser. I would like to write attributes in res/xml/*.xml. maybe, I use the other parser. follow that is samplecode. / InputStream stream = cn.getInputStream(); DocumentBuilder docBuild = DocumentBuilderFactory.newInstance ().newDocumentBuilder(); Document manifestDoc = docBuild.parse(stream); ... ... ... How can I use res/xml/*.xml, instead of stream ? (the stream is urlconnection, ) is possible? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: httpclient multipart form upload
I got my jars from: http://hc.apache.org/downloads.cgi The dependencies are included in the Binary with dependencies download. regards, gard On 10 Jun, 10:08, Urs Grob grob@gmail.com wrote: Yes, I also couldn't find the jars for httpmime. I just created a jar from the sources and included that in the project. If anybody knows of some official jar, then I'd also like to know where I could get it (also to stay up to date) Thanks -- Urs On Wed, Jun 10, 2009 at 3:43 AM, Jason Proctor ja...@particularplace.comwrote: a kind soul has forwarded the jars on. community rules. -- jason.software.particle --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: httpclient multipart form upload
2009/6/26 gard gard.honnin...@gmail.com I got my jars from: http://hc.apache.org/downloads.cgi The dependencies are included in the Binary with dependencies download. regards, gard On 10 Jun, 10:08, Urs Grob grob@gmail.com wrote: Yes, I also couldn't find the jars for httpmime. I just created a jar from the sources and included that in the project. If anybody knows of some official jar, then I'd also like to know where I could get it (also to stay up to date) It's not hard to make your own code for this and it saves quite a bit of space by not including those jar files. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Paid applications and market feedback/rating
I think another option is to add ads (adMob or google AdSense) into the app. You may not need a paid version. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] MediaController without VideoView ?
Is it possible to create and use a MediaController that is not attached to a VideoView? The obvious/trivial way does not seem to work, ie; mc = new MediaController(this); mc.setAnchorView(myView); mv.setMediaPlayer(this); doesnt seem to do anything... -- Sasq --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Thread
hello, how can i trigger in tread A a methode from thread B? the methode schould be than executetd in thread b. I want to manipulate within a thread A a View from Thread B, how can i do that? rgds mr.no --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How to change default intent action?
Hi, I am customising native phonebook application as a third party application which can be launched by the same intent as the native application. I have installed that application in my G1 phone. When I have clicked on Contacts icon in launcher menu it a menu pops out and asks me to select which app to lauch i.e., native contacts or my customised contact application. I have selected my application and I have also selected to use this selection as my default choice. After that system never put a pop-up and whenever I clicked on contacts it launches my customised application. Now my problem is, I do not know how do I change this setting i.e., tell the phone to put the pop-up again so that I can select native app or my app? Does anyone has 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Thread
I assume that Thread B is the main UI-thread, handling messages, 'holding' the View. Thread A is a background thread doing some computation or other stuff. If I'm correct in this assumption, you can just post to the View from thread A. While in thread A: myViewInThreadB.post(new Runnable() { public void run() { // This run() method will run in the thread on which // this view 'mViewInThreadB' was created. ... doSomethingWith(mViewInThreadB); ... } }); On Jun 26, 10:06 am, Mr.No f.hi...@arcor.de wrote: hello, how can i trigger in tread A a methode from thread B? the methode schould be than executetd in thread b. I want to manipulate within a thread A a View from Thread B, how can i do that? rgds mr.no --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: LinearLayout in LinearLayout
it's wird, it's work for me,so it's a problem for you if you set the orientation to vertical? On Jun 25, 9:02 pm, Mr.No f.hi...@arcor.de wrote: dont work, only if i setOrientation to vertical. On 25 Jun., 17:21, JdbcDroid jd.bens...@gmail.com wrote: try to use l1.setOrientation(...) just before l1.addView(...) On Jun 25, 4:42 pm, Mr.No f.hi...@arcor.de wrote: Ive tried it with layoutparams its the same. the default layoutarams will be assigned to the layout. On 25 Jun., 16:26, Peli peli0...@googlemail.com wrote: You have not set any layout parameters.http://developer.android.com/reference/android/widget/LinearLayout.La... l2.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT)); Peliwww.openintents.org On Jun 25, 3:28 pm, Mr.No f.hi...@arcor.de wrote: Hi folks, ive a little problem: Why is the following code causing an exception? The Code throws a mBaselineAlignedChildIndex of LinearLayout set to an index that is out of bounds exception. public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); LinearLayout l1 = new LinearLayout(this); LinearLayout l2 = new LinearLayout(this); l1.addView(l2); this.setContentView(l1); } If l2 is dont added to l1 than it works. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Strange TabHost NullPointerException
I am also having the same problem Can anyone help us telling the possible scenarios in which this bug might occur. On Jun 25, 10:17 pm, nEx.Software justin.shapc...@gmail.com wrote: I get no errors when I use TrackBall click to select a tab in TabActivity. Tested on my apps targeting each 1.1 SDK and 1.5 SDK. Now, I am not using separate activities for my tab contents, so that may make a difference. On Jun 25, 2:21 am, Explore Android stetest...@googlemail.com wrote: I am also facing the same issue, not sure this is framework issue or application issue. Any experts have a say on this issue? (I am working with Android 1.5 SDK) On Jun 17, 2:26 pm, roland roland...@gmail.com wrote: I just found a strange issue in my application which contains a ListView. When one item is clicked, a TabActivity will be launched, i got a NullPointerException when i press the item by using trackball. But it's fine when i press the item by using finger. This is the logcat message: D/AndroidRuntime(32224): Shutting down VM W/dalvikvm(32224): threadid=3: thread exiting with uncaught exception (group=0x4000fe70) E/AndroidRuntime(32224): Uncaught handler: thread main exiting due to uncaught exception E/AndroidRuntime(32224): java.lang.NullPointerException E/AndroidRuntime(32224): at android.widget.TabHost.onTouchModeChanged (TabHost.java:178) E/AndroidRuntime(32224): at android.view.ViewTreeObserver.dispatchOnTouchModeChanged (ViewTreeObserver.java:591) E/AndroidRuntime(32224): at android.view.ViewRoot.ensureTouchModeLocally(ViewRoot.java:1736) E/AndroidRuntime(32224): at android.view.ViewRoot.performTraversals (ViewRoot.java:667) E/AndroidRuntime(32224): at android.view.ViewRoot.handleMessage (ViewRoot.java:1482) E/AndroidRuntime(32224): at android.os.Handler.dispatchMessage (Handler.java:99) E/AndroidRuntime(32224): at android.os.Looper.loop(Looper.java:123) E/AndroidRuntime(32224): at android.app.ActivityThread.main (ActivityThread.java:3948) E/AndroidRuntime(32224): at java.lang.reflect.Method.invokeNative (Native Method) E/AndroidRuntime(32224): at java.lang.reflect.Method.invoke (Method.java:521) E/AndroidRuntime(32224): at com.android.internal.os.ZygoteInit $MethodAndArgsCaller.run(ZygoteInit.java:782) E/AndroidRuntime(32224): at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:540) E/AndroidRuntime(32224): at dalvik.system.NativeStart.main(Native Method) Has anyone met this kind of issue? Thanks for sharing your experience. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Flv to mp4 Convertion
Hi All, I want to play the flv files in Android. So what I thought is to convert the flv file to mp4 or 3gp(for which there is a decoder in Android). OpenCore can be used to convert. I have looked into opencore code, there is a class in opencore /android/external/opencore/ fileformats/mp4/composer to create the mp4 file. It has apis like AddTrack, AddSampleToTrack.. I should give the input as frames, but in Flv I will get the Sorenson Video and Mp3 audio frame(after doing some trivial string operations to remove the headers). Can I use these directly as input to above apis or is there any good way to convert flv to mp4? And also I have looked into /android/external/opencore/ nodes/pvmp4ffcomposernode but it reads from ports not able to know how to send input to this class. Let me know your thoughts. With Regards Vinayakumara T V --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to change default intent action?
you have to goto the application settings by pressing menu then settings then goto applications then scroll down to your app and clear the default setting On Jun 26, 9:12 am, Explore Android stetest...@googlemail.com wrote: Hi, I am customising native phonebook application as a third party application which can be launched by the same intent as the native application. I have installed that application in my G1 phone. When I have clicked on Contacts icon in launcher menu it a menu pops out and asks me to select which app to lauch i.e., native contacts or my customised contact application. I have selected my application and I have also selected to use this selection as my default choice. After that system never put a pop-up and whenever I clicked on contacts it launches my customised application. Now my problem is, I do not know how do I change this setting i.e., tell the phone to put the pop-up again so that I can select native app or my app? Does anyone has 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Attempting to pass data via NotificationManager - Seeking Help/Advice
If I understand you correctly, you just need to call Activity.getIntent () within Activity.onCreate(). Thing is that onCreate does not get called. That activity starts, resume gets called. At the point when resume gets called the intent has changed from my intent with extras to the MAIN/LAUNCHER intent. I have a more detailed description of what is going on in the beginner group - here ... http://groups.google.com/group/android-beginners/browse_thread/thread/363ef9d6a59670 I am really stuck - and may be trying to do something that Android is not meant to do. I have spent way too much time trying to solve this riddle. Thanks, j --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Attempting to pass data via NotificationManager - Seeking Help/Advice
some additional details in case someone here does not go there ...from logcat ... Starting activity: Intent { comp={com.blah.blahs/com.blah.blahs.Blahs} (has extras) } *** notice ... this is my intent called from the status bar *** startActivity called from non-Activity context; forcing Intent.FLAG_ACTIVITY_NEW_TASK for: Intent { comp={com.blah.blahs/com.blah.blahs.Blahs} (has extras) } *** does this message mean my intent has been overridden? *** RESUMED CALLED Intent { action=android.intent.action.MAIN categories={android.intent.category.LAUNCHER} flags=0x1020 comp={com.blah.blahs/com.blah.blahs.Blahs} } ** this is what appears when I call getIntent() under onResume, no more extras ... looks like intent got changed --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Update message - how to check whether app has run before?
Thank you - good thinking. For the benefit of others reading, this is how I did it in the end: String vc = null; try { vc = getPackageManager().getPackageInfo(getPackageName(), 0).versionName; } catch (NameNotFoundException e) e.printStackTrace(); } boolean hasSeenUpdateVersion = settings.getBoolean( hasSeenUpdateVersion, false); if (!hasSeenUpdateVersion) { // show a dialog here SharedPreferences.Editor editor = settings.edit(); editor.putBoolean(hasSeenUpdateVersion + vc, true); editor.commit(); } On Jun 26, 1:54 pm, Neil neilb...@gmail.com wrote: The way you suggested, but add versionCode to the setting name. On Jun 26, 12:40 pm, Anna PS annapowellsm...@googlemail.com wrote: Actually, I have realised that won't work, because it will also show the first time the app is installed. It should only show uponupdate. So, the question still stands. How can I check whether a user has just installed anupdate, in order to show anupdatemessage? Any ideas anyone? Thanks, Anna On Jun 25, 5:17 pm, Anna PS annapowellsm...@googlemail.com wrote: Hi all, I want to show anupdatemessagefor a new release - the first time the user opens the updated version of my app, a pop-up dialog should appear, saying what's new, with an OK button. After the user has read it once, it shouldn't appear again. Is there any inbuilt Android variable I can check to see whether the user has opened the app before? Of course, I can define my own boolean in the app settings (hasUserSeenUpdateMessage) to check each time the app runs - setting it to false initially, and then true when the user clicks OK. Just wondered if there was a slightly more sophisticated way of doing it, or if that's the way to go :) thanks! Anna --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Update message - how to check whether app has run before?
duh - that should be boolean hasSeenUpdateVersion = settings.getBoolean( hasSeenUpdateVersion + vc, false); of course :) On Jun 26, 6:08 pm, Anna PS annapowellsm...@googlemail.com wrote: Thank you - good thinking. For the benefit of others reading, this is how I did it in the end: String vc = null; try { vc = getPackageManager().getPackageInfo(getPackageName(), 0).versionName; } catch (NameNotFoundException e) e.printStackTrace(); } boolean hasSeenUpdateVersion = settings.getBoolean( hasSeenUpdateVersion, false); if (!hasSeenUpdateVersion) { // show a dialog here SharedPreferences.Editor editor = settings.edit(); editor.putBoolean(hasSeenUpdateVersion + vc, true); editor.commit(); } On Jun 26, 1:54 pm, Neil neilb...@gmail.com wrote: The way you suggested, but add versionCode to the setting name. On Jun 26, 12:40 pm, Anna PS annapowellsm...@googlemail.com wrote: Actually, I have realised that won't work, because it will also show the first time the app is installed. It should only show uponupdate. So, the question still stands. How can I check whether a user has just installed anupdate, in order to show anupdatemessage? Any ideas anyone? Thanks, Anna On Jun 25, 5:17 pm, Anna PS annapowellsm...@googlemail.com wrote: Hi all, I want to show anupdatemessagefor a new release - the first time the user opens the updated version of my app, a pop-up dialog should appear, saying what's new, with an OK button. After the user has read it once, it shouldn't appear again. Is there any inbuilt Android variable I can check to see whether the user has opened the app before? Of course, I can define my own boolean in the app settings (hasUserSeenUpdateMessage) to check each time the app runs - setting it to false initially, and then true when the user clicks OK. Just wondered if there was a slightly more sophisticated way of doing it, or if that's the way to go :) thanks! Anna --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] concurrency of AsyncTasks
Hi, I am replacing the multithreaded code in my app with the AsyncTask from 1.5. I found that two AsyncTasks do not work concurrently. I investigated a bit and found a workaround; I would like second opinion if my solution is right. OR if there is a better solution. AsyncTask allows the app to do a task on a thread other than the UI thread. But IIUC, it only provides a single thread on which a queue of tasks is performed. Therefore, if one of the task is to wait on some event (n/w or sleep) then all other tasks will wait for it to finish. To elaborate with the coding example: code public class MyTask extends AsyncTask... { ... } // On the UI thread execute two tasks MyTask mt1 = new MyTask().execute(args); MyTask mt2 = new MyTask().execute(args); /code In the above code both the execute calls will return immediately and free up the UI thread; however mt1 will be executed first and mt2 will have to wait until mt1 finishes. Thanks to the android's open source, we can see implementation of AsyncTask. http://google.com/codesearch/p?hl=ensa=Ncd=2ct=rc#uX1GffpyOZk/core/java/android/os/AsyncTask.javaq=lang:java%20AsyncTask I copied AsyncTask.java as UserTask.java in my project and changed the value of CORE_POOL_SIZE to 5. This makes the thread pool to use 5 threads to multiplex the queued AsyncTasks. This indeed solved my problem. Now if mt1 blocks on a sleep; mt2 goes ahead and finishes its job. Here are some questions for those who know more about AsyncTask implementation: Is this work-around right? If yes, can the CORE_POOL_SIZE be made configurable in future, via an API call? Is there a solution by which multiple thread pools can be used? Let me add that, I am aware that this is a phone and not a web server - I am not using 10s of threads to do network I/O. However a single thread is not sufficient for my app either. Please let me know. Thanks in advance. Jayesh --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Attempting to pass data via NotificationManager - Seeking Help/Advice
Be sure you read app fundamentals, especially about tasks: http://developer.android.com/guide/topics/fundamentals.html#acttask The entity launching the intent (the status bar) is not part of a task, so it is starting an activity outside of a task, so the system forces the NEW_TASK flag on the intent because there is nothing else it could do. The only reason you would not be seeing onCreate() is if your activity is already running. To deal with this, you should make your activity android:launchMode=singleTop and you will receive the intent in onNewIntent. Also you most likely want to use PendingIntent.FLAG_UPDATE_CURRENT when creating the pending intent. On Fri, Jun 26, 2009 at 9:00 AM, Jason Van Anden jason.van.an...@gmail.comwrote: some additional details in case someone here does not go there ...from logcat ... Starting activity: Intent { comp={com.blah.blahs/com.blah.blahs.Blahs} (has extras) } *** notice ... this is my intent called from the status bar *** startActivity called from non-Activity context; forcing Intent.FLAG_ACTIVITY_NEW_TASK for: Intent { comp={com.blah.blahs/com.blah.blahs.Blahs} (has extras) } *** does this message mean my intent has been overridden? *** RESUMED CALLED Intent { action=android.intent.action.MAIN categories={android.intent.category.LAUNCHER} flags=0x1020 comp={com.blah.blahs/com.blah.blahs.Blahs} } ** this is what appears when I call getIntent() under onResume, no more extras ... looks like intent got changed -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Sensor and Compass APIDemo failing on emulator 1.5
I am going to strongly, strongly recommend that people test such code on a real device. I don't know what you were doing, but every case I know of using sensors required a fair amount of tuning on the device to achieve the right feel. For example, the auto-rotation code went through many many iterations of tuning parameters for appropriate angles and introducing checks to avoid unintended rotation. On Fri, Jun 26, 2009 at 4:47 AM, Peli peli0...@googlemail.com wrote: Actually, the sensor code I had written with the SensorSimulator ( http://code.google.com/p/openintents/wiki/SensorSimulator ) before any Android hardware was available publicly, worked perfectly on the G1 when it came out - apart from the known issues with the wrong orientation sensor values that are returned by the G1 hardware :-) It is one of the reasons that kept me from updating the SensorSimulator so far: I wanted to include a G1 compatibility mode that reproduces the wrong G1 readings for orientation - but it is a very ungrateful task (it is not so trivial to simulate exactly the same wrong readings), but unless this is done, I am slightly hesitant to call it a true sensor simulator... It should be mentioned that accelerometer and magnetic compass values are fine - only the calculated orientation values on the G1 had some issues. Peli www.openintents.org On Jun 26, 3:32 am, Dianne Hackborn hack...@android.com wrote: But also, there is no way you are going to be able to implement a working app like this without doing it on real hardware. It would be kind-of like trying to implement a touch user interface without a touch screen. :) On Thu, Jun 25, 2009 at 10:05 AM, Mark Murphymmur...@commonsware.com wrote: Is there any update on this? I need to build a compuss application but the API Demo doesn't work in the emulator. You will need actual hardware to test sensor-related applications. Partly, this is due to the emulator bug. -- Mark Murphy (a Commons Guy) http://commonsware.com Android App Developer Books:http://commonsware.com/books.html -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Sensor and Compass APIDemo failing on emulator 1.5
On Jun 26, 10:03 am, Dianne Hackborn hack...@android.com wrote: I am going to strongly, strongly recommend that people test such code on a real device. I don't know what you were doing, but every case I know of using sensors required a fair amount of tuning on the device to achieve the right feel. For example, the auto-rotation code went through many many iterations of tuning parameters for appropriate angles and introducing checks to avoid unintended rotation. I strongly agree with Dianne. Being an embedded designer, I know that simulations are good and can be a very valuable tool, but you must always follow up with a test on the actual hardware. Believe it or not, there are times when the simulation looks great and works as expected, but then when you go and test the actual hardware you find out that it does not work as planned. Long story short, follow Dianne's advice and test on the actual hardware. You will be doing a disservice to the users of your application if you do not. ~L!TH --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Passing in a Bitmap as the EXTRA_STREAM parameter when launching an Intent
On Thu, Jun 25, 2009 at 10:44 PM, Sujay Krishna Sureshsujay.coold...@gmail.com wrote: one thing u could do is use a fileobserver, check when the file is opened,accessed n closed, on close delete it... this is also jus a suggestion... i havent tried it yet... If I call the Camera activity like this: i = new Intent( android.provider.MediaStore.ACTION_IMAGE_CAPTURE, null); Does it actually write the captured image to the disk? If yes, can i just get the URL of the captured from the disk of th phone? Thank you. On Fri, Jun 26, 2009 at 11:13 AM, Sujay Krishna Suresh sujay.coold...@gmail.com wrote: If u wanna delete the file once the Target activity is over, u can do that in ur onActivityResult(). but i wont guarantee that this will always work bec, if the activity internally triggers a service n dies then u'll have a problem deleting it... if u r mainitaining the status of the file(sent or yet to be sent), then u could have a thread that deletes all files that have been sent... but this is jus a suggestion, there're millions of other ways to do it... On Fri, Jun 26, 2009 at 11:06 AM, n179911 n179...@gmail.com wrote: Thank you. But if I write the image to a file, and invoke an Intent ACTION_SEND, passing that image to the intent. When/how can I delete the file? I can't rely on the ACTION_SEND removes that file for me, since it does not know I wrote the Bitmap to a temp file before I invoke the ACTION_SEND. Thank you for any more tip. On Thu, Jun 25, 2009 at 10:24 PM, Sujay Krishna Sureshsujay.coold...@gmail.com wrote: If u need the image, u definitely have to write it to a file... Use the Images.EXTERNAL_CONTENT_URI.buildUpon() to build a new uri for ur image then use getcontentresolver.openoutputstream to get the outputstream for the uri, write the image content to the outputstream... now u hv persisted ur image n also hv a uri associated to it... On Fri, Jun 26, 2009 at 5:48 AM, hap 497 hap...@gmail.com wrote: HI, From the JavaDoc, the EXTRA_STREAM parameter when launching an intent needs to be an URI. How can I pass a Bitmap object which I get from launching a android.provider.MediaStore.ACTION_IMAGE_CAPTURE intent? /** * A content: URI holding a stream of data associated with the Intent, * used with {...@link #ACTION_SEND} to supply the data being sent. */ public static final String EXTRA_STREAM = android.intent.extra.STREAM; Thank you. -- Regards, Sujay Princess Margaret - I have as much privacy as a goldfish in a bowl. -- Regards, Sujay Yogi Berra - I never said most of the things I said. -- Regards, Sujay Bill Cosby - A word to the wise ain't necessary - it's the stupid ones that need the advice. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: concurrency of AsyncTasks
Hi, It's a bug and your workaround is correct. I'll fix this right away. On Fri, Jun 26, 2009 at 9:27 AM, Jayesh Salvijayeshsa...@gmail.com wrote: Hi, I am replacing the multithreaded code in my app with the AsyncTask from 1.5. I found that two AsyncTasks do not work concurrently. I investigated a bit and found a workaround; I would like second opinion if my solution is right. OR if there is a better solution. AsyncTask allows the app to do a task on a thread other than the UI thread. But IIUC, it only provides a single thread on which a queue of tasks is performed. Therefore, if one of the task is to wait on some event (n/w or sleep) then all other tasks will wait for it to finish. To elaborate with the coding example: code public class MyTask extends AsyncTask... { ... } // On the UI thread execute two tasks MyTask mt1 = new MyTask().execute(args); MyTask mt2 = new MyTask().execute(args); /code In the above code both the execute calls will return immediately and free up the UI thread; however mt1 will be executed first and mt2 will have to wait until mt1 finishes. Thanks to the android's open source, we can see implementation of AsyncTask. http://google.com/codesearch/p?hl=ensa=Ncd=2ct=rc#uX1GffpyOZk/core/java/android/os/AsyncTask.javaq=lang:java%20AsyncTask I copied AsyncTask.java as UserTask.java in my project and changed the value of CORE_POOL_SIZE to 5. This makes the thread pool to use 5 threads to multiplex the queued AsyncTasks. This indeed solved my problem. Now if mt1 blocks on a sleep; mt2 goes ahead and finishes its job. Here are some questions for those who know more about AsyncTask implementation: Is this work-around right? If yes, can the CORE_POOL_SIZE be made configurable in future, via an API call? Is there a solution by which multiple thread pools can be used? Let me add that, I am aware that this is a phone and not a web server - I am not using 10s of threads to do network I/O. However a single thread is not sufficient for my app either. Please let me know. Thanks in advance. Jayesh -- Romain Guy Android framework engineer romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: httpclient multipart form upload
http://www.mirrorservice.org/sites/ftp.apache.org/httpcomponents/httpclient/binary/httpcomponents-client-4.0-beta2-bin-with-dependencies.tar.gz Extract and the lib folder contains all relevant jars, regards, saad On Jun 10, 9:08 am, Urs Grob grob@gmail.com wrote: Yes, I also couldn't find the jars for httpmime. I just created a jar from the sources and included that in the project. If anybody knows of some official jar, then I'd also like to know where I could get it (also to stay up to date) Thanks -- Urs On Wed, Jun 10, 2009 at 3:43 AM, Jason Proctor ja...@particularplace.comwrote: a kind soul has forwarded the jars on. community rules. -- jason.software.particle --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Bug? Geo fix and sdk 1.5
test --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Location Provider - Coarse Location Problem
The way we are retrieving locations from our Android phones is to 1st get a Coarse Location followed by a Fine Location. This is for the case where the user may be inside a building initially and unable to track satellites. After we get our coarse location we transition to a fine location to track satellites. This method has been working fine for several months. We recently upgraded to 1.5 and our mapping application, to my recollection continued to work. For the past couple of days we have not been able to get a coarse location and we are receiving a status message in the onStatusChange callback of LocationProvider.TEMPORARILY_UNAVAILABLE. We have re- installed previous versions our code that used 1.1 and we are receiving the same status message of .TEMPORARILY_UNAVAILABLE. Other than the obvious description of the constant, we can find no meaningful information. We are still able to track positions using FINE_LOCATION. Has anybody seen this message? Are my local towers not providing the required data? Any thoughts? Setup: Using Android G1 phones Firmware: 1.5, Build# CRB43 Eclipse IDE 3.4.2 – 1700 with latest Android plug-ins API - Google API (1.5) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] My Buttons are not Clickable in the Incall Screen
Hi I have a Querry, I am trying to add buttons to the Incall screen. But after adding the buttons, my buttons are not Clickable. That’s UI is present in the screen. I am able to select the Buttons using the up down arrow Key. And on pressing OK control is going to my OnClickListener But I am not able to Click the Buttons directly on the UI. It looks like some kind of Blocking is there for Click events on the Incall Screen, But still I need to get rid of it. Do suggest. What’s the possible way? My code is as follows. public class InCallScreen extends Activity implements View.OnClickListener, View.OnTouchListener, CallerInfoAsyncQuery.OnQueryCompleteListener { .. .. private Button mEndCall; mEndCall = (Button) findViewById(R.id.EndCall); mEndCall.setOnClickListener(new View.OnClickListener(){ public void onClick(View v) { PhoneUtils.hangup(mPhone); //handle the click and End Control here }}); Thanks and regards Zealousian --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Touch Mode and ListViewItems with a Compound View
Hello, I have read related posts and blogs about how a list item loses selection on entering touch mode and the suggestion to use onClick/ onSelect listeners or selection modes, but I am still having the following problem. I have a list view, where each item row is a compound view, consisting of an edit box and a check box. I want to track the position of the compound view item on which the user is working currently (even if the row is not selected but the edit box in the compound view has focus). Currently I am trying to use ListView's onItemClick/OnItemSelect listeners to track the current item row. I am remembering the last selected item's row position in an instance variable in the list activity. The problem is, when I select an item and then touch the edit box of another item, my tracked item position is not of the edit box I have focused on, it's the last selected items position. How can I track the position of the compound view whose edit box just got touched? Any help will be much appreciated. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Gettings files to a web server with Cupcake
It's only day 2 for me on Android/Cupcake and generally finding it a breeze. But one thing is confounding me: I cannot get data files off the device to a server. A multipart POST request would be my choice. All examples I've tried to date either don't compile (missing classes eg Part, or compile but don't work). Many people seem to be asking the same question and I'm surprised this is not one of the items on the developer's FAQ. I would really appreciate a pointer to a working code example for the latest API. Thanks in advance, Joe. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Bug? Geo fix and sdk 1.5
With SDK 1.5r1 I had this problem using an AVD for Android 1.1 (target id 1). When I use an AVD for Android 1.5 (target id 2) I don't experience this problem - the locations received by the onLocationChanged() reflect the location entered via geo fix Axel --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Best practices for library with UI component
Hi -- My company is in the process of evaluating if we can add support for Android to our product. I am currently working on porting our existing J2ME library to the Android framework and I have a question regarding our UI component. Right now, we have a custom menu that we allow our developers to bring up on the device. On J2ME, we simply have a single call that the developer makes to enter into the menu and then we handle the rest. On Android, it seems the best way to handle this is an Activity. But I have a few questions regarding this approach -- including is the really the best way to do something like this? Second, if it is, if there are multiple applications on the device that are using our library, are there going to be conflicts with them all having the same Activity embedded in them? Is it possible to create an Actvity at runtime and use it directly? Would there be any side effects of going about it this way? Thanks! dennis --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to add Google Maps library, Maps to the Android 1.5 version device?
Hi all I've pushed 3 files to the required path, but Maps is still invisible. Anyone has idea what's going on with this? ps. I'm using android sdk 1.5r2 Elvis On Jun 3, 8:10 am, Subba raochoud...@gmail.com wrote: Thanks. I was able to install Maps library and Maps application in my device. On Jun 1, 6:27 pm, XC He schosnab...@gmail.com wrote: Try adb remount XC He 2009/6/2 Subba raochoud...@gmail.com I extracted com.google.android.map.jar and com.google.android.map.xml and Map.apk files from the another development device which has google maps in it. I started with following procedure.. 1. adb -d shell 2. # mount -o rw -t yaffs2 /dev/block/mtdblock3 /system mount -o rw -t yaffs2 /dev/block/mtdblock3 /system mount: Device or resource busy I can't copy the above files to the /system/framework/ , /system/etc/ permissions/ , and /system/app to these directories. C:\adb -d push C:\GoogleMAPS\Maps.apk /system/framework/ failed to copy 'C:\GoogleMAPS\Maps.apk' to '/system/framework// Maps.apk': Read-only file system Is there any way to change the system image to Read write mode.? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: no classfiles specified and Conversion to Dalvik format failed with error 1
I don't understand this. I do a fresh clean install of everything, follow the HelloAndroid example to the letter, and as soon as I create the new project I get these errors. [2009-06-25 11:33:21 - HelloAndroid] no classfiles specified [2009-06-25 11:33:21 - HelloAndroid] Conversion to Dalvik format failed with error 1 It would seem to me this is a bug. It has happened exactly this way on two different XP machines with Eclipse. Who can fix this? On Jun 20, 2:14 am, Jiri Danek jur...@gmail.com wrote: Check this:http://www.anddev.org/viewtopic.php?p=22705 You have to simply reload the project in Eclipse. Click on the project in the Package explorer on the left and press F5(reload) On 15 čvn, 02:12, xerberus bastian.seiff...@gmail.com wrote: Hi Guys, I have a working(Released) project that needs some updating. The Project was created with SDK 1.1 on Windows and Ecplise 3.4. A couple months ago i moved away from Windows to Mac and installed all tools on the mac including Android SDK 1.1. Everything was working fine at that time. I never bothered compiling the project against SDK 1.5 as the program was running fine on a 1.5 Device. But now i need to do some changes and installed SDK 1.5, following the installation guideline (http://developer.android.com/sdk/1.5_r1/ upgrading.html#UpdateYourProjects). So I build my project against SDK 1.1 (as suggested) andfailedwith the followingerrormessages : - no classfiles specified -ConversiontoDalvikformatfailedwitherror1 I receive the sameerrorif I compile with SDK 1.5 (clean + build). First i thought there is something wrong with my code but could not find anything. After that I tried the example JetBoy and received the sameerror. Using Fix Project Properties was without effect for booth projects. I am kind of clueless right know and happy for any suggestion --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Keeping an application running in the background
Hi -- Yet another question -- we have an application that connects to a device and therefore needs to keep running in the background even when there are no Activities active. What is the recommended way to indicate that our application is still active and for it not to be killed automatically? Thanks! dennis --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] with android sdk 1.5, i got a problem.
I am fail to install my apk file on device, in the logcat it show error message: 01-28 01:41:22.944: ERROR/PackageManager(958): Package test.android.media has no signatures that match those in shared user android.media; ignoring! 01-28 01:41:22.944: WARN/PackageManager(958): Package couldn't be installed in /data/app/test.android.media.apk i use the share user id: android.media. I try to signatures my apk file like this keytool -genkey -alias wwa -keyalg RSA -validity 2 -keystore wwa jarsigner -verbose -keystore wwa -signedjar test_signed.apk test.apk wwa it is also failed How should I solve this problem? By the way when i use emulator,it is ok. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] help
How to detect key event without activty? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: SDK 1.5: unable to send SMS to another emulator
hi I have tried by disabling IPv6 from network connection but still it don't work and show me error: could not connect to client socket to 1:5556: unknown error On May 25, 3:18 am, David Turner di...@android.com wrote: On Sun, May 24, 2009 at 6:17 PM, Steve steveoliv...@gmail.com wrote: Not working for me either, running a Mac with SDK 1.5. I wonder if the new AVD's have somehow broken the port numbers, and since you have to run each emulator against a separate AVD, now the 2 emulators can't see each other. Argh! No, the issue is related to IPv6 and a bug in the emulator's name resolution code. A fix will be available in the next release. In the meantime, you could try disabling IPv6 on your localhost interface and see if it helps. (Yes, I know it's gruesome, sorry). On May 13, 1:59 pm, Laurie mamla...@gmail.com wrote: Same for me. With the 1.5 SDK toolkit, I cannot send or receiveSMS/ Calls using TWO EMULATOR INSTANCES on the same development machine. **Simulating incoming calls andSMSmessages using the emulator console via telnet works fine. Using DDMS in Eclipse works fine. I am using Windows Vista, using distinct AVDs, both the Dialer/ Messaging applications and port numbers (eg. 5554 and 5556). I have tried both launching both emulator instances through Eclipse, as well as one with Eclipse and one from the command line. Neither method works. These features worked fine in Android 1.1. I hope we get an answer to this query soon. -LED --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Android App Widgets
HI I have recently started using android and wanted to try App Widgets. I have coded all the primary features for the app widget (in the manifest file, xml resources..). But I dont know how do I publish my app widget in another application. And does my App Widget always need to be a broadcaster receiver or can it launch another application as well. Thanks prat --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: httpclient multipart form upload
Hi Urs, Download HttpClient binary from here: http://hc.apache.org/downloads.cgi ; be sure to download the distribution under the heading 'binary with distribution'. After extracting, you will find a number of jars in the lib folder. saad On Jun 10, 9:08 am, Urs Grob grob@gmail.com wrote: Yes, I also couldn't find the jars for httpmime. I just created a jar from the sources and included that in the project. If anybody knows of some official jar, then I'd also like to know where I could get it (also to stay up to date) Thanks -- Urs On Wed, Jun 10, 2009 at 3:43 AM, Jason Proctor ja...@particularplace.comwrote: a kind soul has forwarded the jars on. community rules. -- jason.software.particle --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] increase application speed
For Details download the MS word file at http://alturl.com/bv92 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Open source and diagramming
Dear open source contributors, I am Eunyoung Chung, a Masters student at Oregon State University. I am currently doing a research to understand how contributors communicate and collaborate in Open Source Software (OSS) projects, including diagramming practices. We are seeking volunteers for a quick survey on this topic. Any person who is actively working on a OSS project is eligible. The survey takes approximately 10-15 minutes, and the 5 volunteers will be picked to receive a $30 Amazon gift certificate. Your participation is anonymous (unless you consent to have us contact you) Here is the survey address. https://secure.engr.oregonstate.edu/limesurvey/58564/lang-en We really appreciate your help! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Fail to install Maps.apk on cupcake
Hi all~~ I was unable to install Maps.apk into emulator cupcake. I've tried 2 method, both are failure. 1. adb install Maps.apk -- [INSTALL_FAILED_MISSING_SHARED_LIBRARY] 2. Copy Maps.apk to /system/app/, com.google.android.maps.jar to / system/framework/, com.google.android.maps.xml to /etc/permissions/ Map application is still invisible, can anyone help me how to accomplish this issue. Or there's other security issue? Elvis --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Question about getFileStreamPath
In the following code, which create a File object using getFileStreamPath() with temp-wallpaper as parameter. File f = getFileStreamPath(temp-wallpaper); (new File(f.getParent())).mkdirs(); Can you please tell me where is the file actually located? Thank you. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Sensor and Compass APIDemo failing on emulator 1.5
There is a considerable amount of development that can be done, even without actual sensor hardward. Having to comment out all sensor related code to get graphics, keystrokes and all the other minutia working is not productive. The emulator really needs to get fixed. Rud On Jun 25, 8:32 pm, Dianne Hackborn hack...@android.com wrote: But also, there is no way you are going to be able to implement a working app like this without doing it on real hardware. It would be kind-of like trying to implement a touch user interface without a touch screen. :) On Thu, Jun 25, 2009 at 10:05 AM, Mark Murphymmur...@commonsware.com wrote: Is there any update on this? I need to build a compuss application but the API Demo doesn't work in the emulator. You will need actual hardware to test sensor-related applications. Partly, this is due to the emulator bug. -- Mark Murphy (a Commons Guy) http://commonsware.com Android App Developer Books:http://commonsware.com/books.html -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them.- 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Read inbox SMS
Hi, I want to develop application which read sms from inbox. Can any one tell me how can I do it. Thanks in Advance. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: ClassNotFoundException
Mike, please to put this on your manifest: application ... activity android:name=.. .. /activity uses-library android:name=com.google.android.maps / /application uses-permission android:name=android.permission.INTERNET / uses-permission android:name=android.permission.ACCESS_FINE_LOCATION / --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Security Exception
Just wondering if anyone can help Just wondering if anyone can help on the security exception I am getting. 06-18 22:21:48.637 156 162 W Parcel : enforceInterface() expected 'android.os.IPowerManager' but read '-ä' 06-18 22:21:48.707 253 253 W dalvikvm: threadid=3: thread exiting with uncaught exception (group=0x4000fe70) 06-18 22:21:48.707 253 253 E AndroidRuntime: Uncaught handler: thread main exiting due to uncaught exception 06-18 22:21:48.777 253 253 E AndroidRuntime: java.lang.SecurityException: Binder invocation to an incorrect interfac e 06-18 22:21:48.777 253 253 E AndroidRuntime:at android.os.Parcel.readException(Parcel.java:1234) 06-18 22:21:48.777 253 253 E AndroidRuntime:at android.os.Parcel.readException(Parcel.java:1222) 06-18 22:21:48.777 253 253 E AndroidRuntime:at android.os.IPowerManager$Stub$Proxy.acquireWakeLock(IPowerMan ager.java:178) 06-18 22:21:48.777 253 253 E AndroidRuntime:at android.os.PowerManager$WakeLock.acquire(PowerManager.java:23 1) 06-18 22:21:48.777 253 253 E AndroidRuntime:at com.android.internal.telephony.gsm.RIL.acquireWakeLock(RIL.ja va:1706) 06-18 22:21:48.777 253 253 E AndroidRuntime:at com.android.internal.telephony.gsm.RIL.send(RIL.java:1735) 06-18 22:21:48.777 253 253 E AndroidRuntime:at com.android.internal.telephony.gsm.RIL.setFacilityLock(RIL.ja va:1402) 06-18 22:21:48.777 253 253 E AndroidRuntime:at com.android.internal.telephony.gsm.GsmSimCard.setSimLockEnabl ed(GsmSimCard.java:235) 06-18 22:21:48.777 253 253 E AndroidRuntime:at com.android.settings.SimLockSettings.tryChangeSimLockState(Si mLockSettings.java:274) 06-18 22:21:48.777 253 253 E AndroidRuntime:at com.android.settings.SimLockSettings.onPinEntered(SimLockSett ings.java:229) 06-18 22:21:48.777 253 253 E AndroidRuntime:at com.android.settings.EditPinPreference.onDialogClosed(EditPin Preference.java:76) 06-18 22:21:48.777 253 253 E AndroidRuntime:at android.preference.DialogPreference.onDismiss(DialogPreferenc e.java:359) 06-18 22:21:48.777 253 253 E AndroidRuntime:at android.app.Dialog$DismissCancelHandler.handleMessage(Dialog. java:946) 06-18 22:21:48.777 253 253 E AndroidRuntime:at android.os.Handler.dispatchMessage(Handler.java:99) 06-18 22:21:48.777 253 253 E AndroidRuntime:at android.os.Looper.loop(Looper.java:123) 06-18 22:21:48.777 253 253 E AndroidRuntime:at android.app.ActivityThread.main(ActivityThread.java:3948) 06-18 22:21:48.777 253 253 E AndroidRuntime:at java.lang.reflect.Method.invokeNative(Native Method) 06-18 22:21:48.777 253 253 E AndroidRuntime:at java.lang.reflect.Method.invoke(Method.java:521) 06-18 22:21:48.777 253 253 E AndroidRuntime:at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(Zy goteInit.java:782) 06-18 22:21:48.777 253 253 E AndroidRuntime:at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:540) 06-18 22:21:48.777 253 253 E AndroidRuntime:at dalvik.system.NativeStart.main(Native Method) 06-18 22:21:48.877 156 454 V DumpStateReceiver: Running: /system/ bin/dumpcrash 06-18 22:21:48.967 156 454 I DumpStateReceiver: Finished: 2509 bytes read; status 0 06-18 22:21:49.007 156 454 I DumpStateReceiver: Added state dump to 1 crashes Thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Need Help Dream!!!
Hi, my name is Serena and I'm writing from Italy. I have a G1 brad Tim Italia, 2 days ago I installed RC7...and now my phone now is T-Mobile and has problem with keyboard, and I cant'use Telnet. Beside my pc don't see the phone in fastboot, and when i try to install something the phone give me this message:E:cant'open /cache/ recovery/command, or No signature ora something like this. When I Holding the side camera button + power I have only a rainbow screen and I can't do anything :( Please could you help me? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to change default intent action?
Thanks, it works. On Jun 26, 4:53 pm, schwiz sch...@gmail.com wrote: you have to goto the application settings by pressing menu then settings then goto applications then scroll down to your app and clear the default setting On Jun 26, 9:12 am, Explore Android stetest...@googlemail.com wrote: Hi, I am customising native phonebook application as a third party application which can be launched by the same intent as the native application. I have installed that application in my G1 phone. When I have clicked on Contacts icon in launcher menu it a menu pops out and asks me to select which app to lauch i.e., native contacts or my customised contact application. I have selected my application and I have also selected to use this selection as my default choice. After that system never put a pop-up and whenever I clicked on contacts it launches my customised application. Now my problem is, I do not know how do I change this setting i.e., tell the phone to put the pop-up again so that I can select native app or my app? Does anyone has any idea? Thanks- 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Wat to buy???
you can purchase the android developer phone. its the same thing as the G1, only difference being that its unlocked and will work with any GSM service provider. check out the following link - this guy has purchased the developer phone in india and recounts his first-hand experience http://www.shekhargovindarajan.com/google/anroid-to-india-a-shipping-faq/ On Jun 25, 11:08 am, Sujay Krishna Suresh sujay.coold...@gmail.com wrote: Hi everyone, i live in India and i wanna own an android phone... can anyone gimme suggestions as to wat phone i can buy, from where to buy wat'd be d approx cost??? -- Regards, Sujay Laurence J. Peterhttp://www.brainyquote.com/quotes/authors/l/laurence_j_peter.html - If two wrongs don't make a right, try three. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Retrieving Google/GTalk Account bound to Android?
Hi all, I'm working on a program that will need to read user's GTalk contacts, and also I need to find out which Gtalk account the user is using. I heard that each android is bound with a google account (to be extactly, the username/email of user's google account). I wonder any one can tellme how can I get this account? thanks --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] SimpleCursorAdapter()
Hi, I am trying to pull data from a cursor which is initialized as follows: Uri inboxUri = Uri.parse(content://sms/); Cursor c = managedQuery(inboxUri, null, null, null, null); this effectively gets me to latest text message that has been sent/ received. I am now trying to put certain fields into a listView, but need to format them before displaying them. The date is represented in the table in milliseconds and I want to convert it to a date before placing it in the list. Here is where I am trying to place the date in my list. How can I format these fields before placing them into my listview? private static int[] TO = { R.id.from, R.id.body, R.id.date, }; private static String[] FROMTWO = { FROM, BODY, DATE, }; SimpleCursorAdapter adapter; adapter = new SimpleCursorAdapter(this,R.layout.item, c, FROMTWO, TO); setListAdapter(adapter); --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to recover stopped activities
Hi, Can someone help me? I tried to use android:allowTaskReparenting=true android:taskAffinity=PACKAGE_NAME.ACTIVITY_NAME but it doesn't work. Thanks On 6/25/09, Thomas perd...@gmail.com wrote: Hi All, I've some problems with a task. There are an activity A stopped and I start activity B in the same task. But if activity A is stopped, activity B needs to discover that and launch activity A. Can someone 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Security Exception
On Thu, Jun 25, 2009 at 6:36 PM, Rab73raben...@gmail.com wrote: Just wondering if anyone can help Just wondering if anyone can help on the security exception I am getting. It might help if you also included the code that is triggering this. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] listeners in popupwindow
Hi all, I have one activity , Which has the menu update .Whenever i click on update button. I am creating pop up window.In that , following is the code snippet , PopupWindow loginPopUp = new PopupWindow(this); loginPopUp.setContentView(this.getLayoutInflater().inflate (R.layout.login_page, null, false)); Here i am setting login_page.xml to content view.In this i have two buttons.I need to perform something in click of those buttons. I have tried , I created one activity in that I am loading the same XML in contentView , There I have registered with onClickListeners but whenever i click that button public void onClick(View v) {} this function is not getting triggered. any solution ? -Ashok. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Location Provider - Coarse Location Problem
The way we are retrieving locations from our Android phones is to 1st get a Coarse Location followed by a Fine Location. This is for the case where the user may be inside a building initially and unable to track satellites. After we get our coarse location we transition to a fine location to track satellites. This method has been working fine for several months. We recently upgraded to 1.5 and our mapping application, to my recollection continued to work. For the past couple of days we have not been able to get a coarse location and we are receiving a status message in the onStatusChange callback of LocationProvider.TEMPORARILY_UNAVAILABLE. We have re- installed previous versions our code that used 1.1 and we are receiving the same status message of .TEMPORARILY_UNAVAILABLE. Other than the obvious description of the constant, we can find no meaningful information. We are still able to track positions using FINE_LOCATION. Has anybody seen this message? Are my local towers not providing the required data? Any thoughts? Setup: Using Android G1 phones Firmware: 1.5, Build# CRB43 Eclipse IDE 3.4.2 – 1700 with latest Android plug-ins API - Google API (1.5) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: concurrency of AsyncTasks
Thanks Romain for quick response. Jayesh On Fri, Jun 26, 2009 at 10:54 PM, Romain Guy romain...@google.com wrote: Hi, It's a bug and your workaround is correct. I'll fix this right away. On Fri, Jun 26, 2009 at 9:27 AM, Jayesh Salvijayeshsa...@gmail.com wrote: Hi, I am replacing the multithreaded code in my app with the AsyncTask from 1.5. I found that two AsyncTasks do not work concurrently. I investigated a bit and found a workaround; I would like second opinion if my solution is right. OR if there is a better solution. AsyncTask allows the app to do a task on a thread other than the UI thread. But IIUC, it only provides a single thread on which a queue of tasks is performed. Therefore, if one of the task is to wait on some event (n/w or sleep) then all other tasks will wait for it to finish. To elaborate with the coding example: code public class MyTask extends AsyncTask... { ... } // On the UI thread execute two tasks MyTask mt1 = new MyTask().execute(args); MyTask mt2 = new MyTask().execute(args); /code In the above code both the execute calls will return immediately and free up the UI thread; however mt1 will be executed first and mt2 will have to wait until mt1 finishes. Thanks to the android's open source, we can see implementation of AsyncTask. http://google.com/codesearch/p?hl=ensa=Ncd=2ct=rc#uX1GffpyOZk/core/java/android/os/AsyncTask.javaq=lang:java%20AsyncTask I copied AsyncTask.java as UserTask.java in my project and changed the value of CORE_POOL_SIZE to 5. This makes the thread pool to use 5 threads to multiplex the queued AsyncTasks. This indeed solved my problem. Now if mt1 blocks on a sleep; mt2 goes ahead and finishes its job. Here are some questions for those who know more about AsyncTask implementation: Is this work-around right? If yes, can the CORE_POOL_SIZE be made configurable in future, via an API call? Is there a solution by which multiple thread pools can be used? Let me add that, I am aware that this is a phone and not a web server - I am not using 10s of threads to do network I/O. However a single thread is not sufficient for my app either. Please let me know. Thanks in advance. Jayesh -- Romain Guy Android framework engineer romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Attempting to pass data via NotificationManager - Seeking Help/Advice
Hi Dianne, This worked! You rock. My forehead and desktop thank you for the break. Not to sound too defensive but ... I have read the documentation thoroughly and repeatedly. I have also watched any and all videos from the conference, etc. I have been developing with Android since November. I am a professional software engineer with around 20 years of experience. I was still stumped! A cookbook of examples using different launchModes may have helped me out in this case. Thank You, Jason Van Anden http://www.smileproject.com --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Delete non empty folders
Hi ne way of incorporating the new File(...).delete(); command to delete non delete files ? or ne other command that does tht ? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Android 1.5 SDK now available
Can you post a link to ROM you downloaded for the 1.5 cupcake update for the G1 Developer phone. On May 6, 1:32 pm, DJMoran danmo...@blueyonder.co.uk wrote: Never mind I've got it from HTC.com now On May 6, 9:30 pm, DJMoran danmo...@blueyonder.co.uk wrote: I've got a dev phone but I ahven't received the firmware update, nor is it available through the system update option On May 5, 6:04 pm, Sonert soner...@gmail.com wrote: Any idea when the update is going to be pushed to all android phone not just Dev models? On Apr 27, 11:12 am, Xavier Ducrohet x...@android.com wrote: Hello developers, The Android 1.5 SDK, and the 1.5 images for ADP1 are now available for download. More information athttp://android-developers.blogspot.com/2009/04/android-15-is-here.html Xav -- Xavier Ducrohet Android Developer Tools Engineer Google Inc. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How to increase speaker volume using AudioTrack
Hey everyone, Does anybody knows how to increase the volume of speaker using AudioTrack? the streamed audio is playing in speaker, but not loud as voice call. Here my code mPlayer = new AudioTrack(AudioManager.STREAM_RING, AUDIO_SAMPLE_FREQUENCY_8000HZ, AudioFormat.CHANNEL_CONFIGURATION_MONO, AudioFormat.ENCODING_PCM_16BIT, 32000, AudioTrack.MODE_STREAM); mAudioManager = (AudioManager) (App.getSystemService (Context.AUDIO_SERVICE)); mAudioManager.setMode(AudioManager.MODE_NORMAL); //this line, apparently, has no effect mAudioManager.setStreamVolume(AudioManager.STREAM_MUSIC, mAudioManager.getStreamMaxVolume (AudioManager.STREAM_MUSIC), 0); 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Strange activity stack issue
Thanks for the info Dianne. On Jun 24, 1:54 am, Dianne Hackborn hack...@android.com wrote: Yeah ADT launches apps differently than the home screen does. Assume the home screen is correct, and ignore this behavior from ADT. On Tue, Jun 23, 2009 at 1:34 PM, Al alcapw...@googlemail.com wrote: Hi, I've come across a very annoying problem, which only seems to happen when I launch my app from eclipse for testing. If I launch it normally, it doesn't seem to have this problem. This is how I can reproduce it: - Launch app via Eclipse - Press Home - Relaunch app via icon - Click menu-exit which tells the Service to clean up and calls finish () when the Service finishes cleaning up For some reason, there seem to be two instances of the activity, one exits normally and the other one gains focus. Clicking exit does nothing since the Service has stopped but the Service variable is not null. Attempting to use the app launches errors since the resource it uses have been closed. I can force a close via the crash and relaunch the app, and it exits normally this time. As I said, it only happens when launching the app via Eclipse. Anyone know what could cause this? My launchMode is set to singleTask, however, that shouldn't cause an issue, I used that mode before. I tried calling finish() regardless of the state of the Service, but it doesn't seem to help. -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Problems with shared library JAR
I'm trying to use an external library packaged in one JAR file (openRDF Sesame 2.2.4 [1]). As suggested in this group, I first added the JAR to a new folder in my project, then added it to the Java build path via the project properties in Eclipse. Now I could already use the classes from the library in my source code without getting any errors. I also added the line uses-library android:name=org.openrdf / to the manifest file inside application. The problem is that as soon as I try to run the app, I get an installation error (INSTALL_FAILED_MISSING_SHARED_LIBRARY) on the console and I'm told (via logcat) that my package requires unavailable shared library org.openrdf. Where's my mistake? Thanks, Max [1] http://ovh.dl.sourceforge.net/sourceforge/sesame/openrdf-sesame-2.2.4-onejar.jar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Reusable Spans
Hi, I have a styled Spannable String, which gets append()ed to other Spannables. Rather then restyle it each time, I was hoping to style it once and reuse it over and over. It seems there isn't possible because the styles get removed when append()ing to other SpannableStringBuilders after the initial append. Is there a way to work around this? I've attached some example code that shows the problem: TextView t = (TextView) findViewById(R.id.tv); final SpannableStringBuilder sp = new SpannableStringBuilder(foobar \n); sp.setSpan(new ForegroundColorSpan(Color.RED), 0, sp.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE); final SpannableStringBuilder sp2 = new SpannableStringBuilder(foo ); sp2.append(sp); t.append(sp2); //ok, foobar is red final SpannableStringBuilder sp3 = new SpannableStringBuilder(bar ); sp3.append(sp); t.append(sp3); //foobar is no longer red --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] How to hide user dictionary? or suggested words on keyboard
How can I hide the suggested words or turn off auto complete for the virtual keyboard? Thanks ;) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Sensor and Compass APIDemo failing on emulator 1.5
I just tried to run a Compass example in r2 and it hung on getting the sensor manager. I don't think the bug is fixed and isn't just a compass bug. But if you have any suggestions I am open to trying them. @L!TH!UM - I also am a long time embedded developer. Yes, you have to get onto the real hardware eventually. I don't know how many times I had to write special code to prove to the hardware guys that their design had something wrong. But it is still very productive to work in an emulator for a lot of development. It is one thing to have the emulator be incomplete or something missing. But to hang trying to get the sensor manager is a major hindarence. Rud On Jun 26, 6:47 am, Shang Hao sahilz...@gmail.com wrote: Firstly, openIntents sensor simulator is a very good tool for compass applications. I have used it without any breakage.. Further,, the compass bug in 1.5 r1 is FIXED in SDK 1.5 r2. Go ahead, there's no breakage now. Cheers. Peli wrote: Unless of course one has a sensor simulator :-) http://code.google.com/p/openintents/wiki/SensorSimulator (I should mention that we did not have time yet to upgrade it to SDK 1.5, but some people already got this to work in the 1.5 emulator). I'd say simulating the sensors in this way can be quite useful if one wants to work out the basic trigonometric relations (which vectors correspond to which orientation, etc.), just as it is useful to test touch interfaces in the emulator with the mouse, or to think through a user interface with pen and pencil. Of course, nothing replaces testing on the real device in the end. Peli www.openintents.org On Jun 26, 9:19 am, David Turner di...@android.com wrote: On Wed, May 27, 2009 at 1:40 PM, sarang sarangd...@gmail.com wrote: Is this a bug in emulator 1.5 ? Yes, it's a known bug in the 1.5 emulator which will be fixed in the next SDK release. However, what others have mentioned is true, there is little you will be able to do in the emulator anyway; this is the kind of thing that requires a real device for proper testing.- 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: JIS conversion is ignored!
On Thu, Jun 25, 2009 at 8:31 PM, Hirohiroy...@hotmail.com wrote: unicode = new String(unicode.getBytes(ISO2022JP), I believe the encoding name you are looking for is ISO-2022-JP (with dashes). The system should also recognize the name Shift_JIS (which is a different encoding). -dan --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: How to recover stopped activities
Your question is vague enough that it is really hard to answer. For example, what do you mean by stopped? What do you mean by launching A (is it going on top of B?)? It is very useful if questions are posted as solutions to be solved (I want to implement navigation through my app that looks like this, this, and that) vs. isolated tasks (I want to tell B that A is stopped), since the specific task being attempted may already be done the wrong road. And please give enough detail for people to actually answer: background context for what you are doing, specifics of what your code is doing (actual code the best), full details of what you are observing that is wrong and what exactly you want to have happen instead. On Fri, Jun 26, 2009 at 10:54 AM, Thomas perd...@gmail.com wrote: Hi, Can someone help me? I tried to use android:allowTaskReparenting=true android:taskAffinity=PACKAGE_NAME.ACTIVITY_NAME but it doesn't work. Thanks On 6/25/09, Thomas perd...@gmail.com wrote: Hi All, I've some problems with a task. There are an activity A stopped and I start activity B in the same task. But if activity A is stopped, activity B needs to discover that and launch activity A. Can someone help me? Thanks a lot. -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer 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 android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Design
Here is where my questions arose: Is there a way to find a suitable happy medium without trial and error testing on a huge database? Profiling with real data is the right way to optimize in a perfect world. If that is unworkable here in this world, then you'll have to get out the slide rule and estimate how long various tasks will take, and more importantly which task has the largest impact on the user experience, such as responsiveness. Then optimize that one. - Load and decompress in a non-UI thread: I understand what you mean, and also sense this might be a good solution. Though, I do not have any idea how to begin with this. Links to any guidelines would be appreciated. There are various ways to do this. The cleanest way in my not particularly humble opinion would be to implement an Android Service: http://developer.android.com/reference/android/app/Service.html This service would be the one that talks with the server and provides the processed data to/from the UI. Yusuf Saib Android ·T· · ·Mobile· stick together The views, opinions and statements in this email are those of the author solely in their individual capacity, and do not necessarily represent those of T-Mobile USA, Inc. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: SimpleCursorAdapter()
elzee wrote: How can I format these fields before placing them into my listview? private static int[] TO = { R.id.from, R.id.body, R.id.date, }; private static String[] FROMTWO = { FROM, BODY, DATE, }; SimpleCursorAdapter adapter; adapter = new SimpleCursorAdapter(this,R.layout.item, c, FROMTWO, TO); setListAdapter(adapter); Subclass SimpleCursorAdapter and override newView() and bindView(). You can either: 1. Chain upward to the superclass implementations (which will do what it is doing today), then fix up the things that need formatting, or 2. Inflate the row Views and populate them all yourself, which is more efficient but requires more code http://wiki.andmob.org/samplecode On the above Web page, you will find links my Fancy ListViews blog post series. It covers overriding getView() instead of newView() and bindView(), but the concepts are basically the same. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android App Developer Books: http://commonsware.com/books.html --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---