[android-developers] Re: How to parse JSON in Java?
To parse the json file it is very much similar to parsing the xml file . first of all u need to create a json array which will captur all ur elements for array posts and then make a json object for each element of jsin array using the function jsonarray.getJSONObject(i) where i is the index I think this will help u put for more details got hrouth the json apis provided by android On Apr 7, 2:05 pm, Maxood maqs...@salsoft.net wrote: I have the following JSON text that i need to parse to get pageName, pagePic, post_id, etc. What is the required code? pageInfo: { pageName: abc pagePic:http://profile.ak.fbcdn.net/object2/367/…} posts: [ { post_id: 160119538822_302076968822 actor_id: 1183856639 picOfPersonWhoPosted:http://profile.ak.fbcdn.net/hprofile-ak-… nameOfPersonWhoPosted: Andrea Raquel message: Sounds cool. Can't wait to see it! likesCount: 2 comments: [ ] timeOfPost: 1266036226 }- 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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Google Checkout Merchant Account for Swiss Developer/Seller
On Apr 11, 4:12 pm, oxonom phyrum@sign.ch wrote: Maybe only a Googler can answer the following questions: - Is some working on activating Google Checkout Merchant Accounts for Swiss developers? - If so, when will it be ready? Looking at the struggles of canadian developers, I think it would be faster to join EU that to persuade google to extend checkout to yet another country... -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: About how to make new buttons in a row?
Hi, I hope you are using LinearLayout as your base Layout.. If so, look for orientation in the properties of this obj and change it to horizontal. Vinay On Apr 12, 10:47 am, xlshe dianyuangua...@gmail.com wrote: Hi all, I want to create three button on the layout. But the default align of the buttons is in a column like: Button1 Button2 Button3 But I want to the three buttons align in a row in order to save space. The align of the three buttons I need is : Button1 Botton2 Botton3 Would you please tell me how to do that? Thank you very much! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] how to track all http/https requests
Hi, How to collect URLs of all http/https requests made by the phone as well as well as the return status code and user agent from the headers. This information should be coming for all browser requests and other applications too. Please let me know this information can be retrieved on App level or we have to go to system level for this. Thanks, Amardeep -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: How to apply different textures on different faces of a cylinder
Kirti - Get either the OpenGL superbible or the redbook. It's money well-spent. On Apr 12, 12:15 am, kirti kaul kirti.k...@wipro.com wrote: Hello, Can anybody tell me how to apply apply different textures on different faces of a cylinder?I am able to apply one texture which covers the whole cylinder.But I want one texture for each face. 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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Device Seeding Program for Top Android Market Developers
It cost you nothing, so lighten up. So what if the shipping that you didn't pay for takes longer than was in the original email?, Google are the ones paying for this, so it's entirely under their control, and it's up to them when want to do something about it. If you really are desperate for a Nexus one / Droid go out and buy one then sell it on eBay once your free one arrives. Yes, you'll lose some money, but hey, you're the one desperate for the 'phone and convenience costs. I'd like to suggest that everyone gives up on they Still haven't got my free 'phone emails until the end of April. By that point we'll be well past the timeframe in the email and it's then worth contacting Google directly (not via this list) because if 'phones are getting lost in shipping and Google don't make an insurance claim are not made then the shipping partner involved won't start looking into why 'phones weren't delivered. Al. On Apr 11, 10:29 pm, Genc gmt...@gmail.com wrote: Nothing for London, Grrr... On Apr 10, 10:43 am, Thomas Riley tomrile...@googlemail.com wrote: Still nothing for me in UK either. From what Google have said via email, it's likely to be a few more weeks. Worth the wait though ;) On Apr 10, 9:28 am, dgoemans dgoem...@gmail.com wrote: Still no-one in Europe? Myself and another dev i know in the Netherlands have not got ours yet. On Apr 8, 11:57 pm, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: Sorry, I meant in Europe, no phone seems to have been received outside the US yet except for ADC2 phones (and yes I think I've read the 600+ messages in hope to find one :-)). I think us European will have to wait a couple of weeks more but it's ok, it's a free phone, it's a gift, it could arrive in a few month time and still be a great surprise and a nice touch from Google! On Apr 8, 11:37 pm, ~ TreKing treking...@gmail.com wrote: On Thu, Apr 8, 2010 at 3:52 PM, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: I'm still surprised about Google's comment that many people have already received their phone (for MarketSeedingProgram). If this is true, none of them is reading this thread I guess. If you trudge through the 600+ posts in this thread, you will find that many of them are people posting Got [X Phone] in [Y Location]. Also, those that got their phones are probably busy playing with / developing on them and have long since lost interest in this thread. --- -- TreKing - Chicago transit tracking app for Android-powered deviceshttp://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Database insertion timings
Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] video playing in appwidget.
is it possible to play a video in an appwidget? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: About how to make new buttons in a row?
Thank you. But when I change the orientation of the layout to horizontal, I can only make the all the buttons align in a row. I have so many buttons on the layout, I need them align like this: Button1 Botton2 Botton3 Button4 Button5 Button6 Button7 Button8 Button9 I want to align them both in rows and in columns like the keys in the dial keyboard. Any suggestions? Thank you very much. On Mon, Apr 12, 2010 at 1:30 AM, Vinay S s.vinay@gmail.com wrote: Hi, I hope you are using LinearLayout as your base Layout.. If so, look for orientation in the properties of this obj and change it to horizontal. Vinay On Apr 12, 10:47 am, xlshe dianyuangua...@gmail.com wrote: Hi all, I want to create three button on the layout. But the default align of the buttons is in a column like: Button1 Button2 Button3 But I want to the three buttons align in a row in order to save space. The align of the three buttons I need is : Button1 Botton2 Botton3 Would you please tell me how to do that? Thank you very much! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Compiling fails for Webkit instrumentation flag WEBCORE_INSTRUMENTATION
Hi All, In Eclair 2.1, we have enabled the flag WEBCORE_INSTRUMENTATION for instrumenting Webkit for performance evaluation. But, we get following compiling errors: out/target/product/test/obj/STATIC_LIBRARIES/libwebcore_intermediates/ libwebcore.a(Parser.o): In function `JSC::Parser::parse(JSC::JSGlobalData*, int*, JSC::UString*)': /vrukeshp/test_pack/external/webkit/JavaScriptCore/parser/Parser.cpp: 47: undefined reference to `android::TimeCounter::start(android::TimeCounter::Type)' /vrukeshp/test_pack/external/webkit/JavaScriptCore/parser/Parser.cpp: 76: undefined reference to `android::TimeCounter::record(android::TimeCounter::Type, char const*)' collect2: ld returned 1 exit status Any suggestions for solving this ? Thanks and Regards, Vrukesh V. Panse -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] JavaScript problem in webview
Hello, I have a JavaScript function which returns a value and i want to use that value in my Android program. Can anyone please tell me how to do that. Regards, Brijesh Masrani -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 make GLSurfaceView show smoothly
Hi Guys, I've been block by this question for about a week. I tried to implement a simple application: show a image, when user touch on screen, I want to create a GLSurfaceView to cover the previous image. Then show some 3D effects on this GLSurfaceView. The logic is quite simple. But I have a serious problem. When GLSurfaceView comes out, the whole screen become black, after 1-2 seconds, the GLSurfaceView with texture shows up. Is there any way to make this smoothly? The 1-2 second black screen is really a bad user experience. Thanks a lot. Any idea/suggestion is appreciated. -- Best Regards, TANG Jiyu Blog: http://jiyu.wordpress.com.cn/ ezkeypad: http://ezkeypad.tool100.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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: About how to make new buttons in a row?
On Apr 12, 7:51 am, ecss utdallas dianyuangua...@gmail.com wrote: the layout, I need them align like this: Button1 Botton2 Botton3 Button4 Button5 Button6 Button7 Button8 Button9 You'll need 4 LinearLayouts, a parent with an orientation of vertical containing 3 child LinearLayouts (each with horizontal orientation) that contain your actual buttons, 3 each. String -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Device Seeding Program for Top Android Market Developers
Al, Thanks and i completely agree... my concern is there's been a big change of situation on my side: no one is available at that address anymore, and i'm moving, so that address will no longer be valid soon. Google have said they're all shipped, so there's nothing i can do about it. And that was 2 weeks ago when i requested the change of address. This is why i'm actively watching this thread. David On Apr 12, 8:44 am, Al Sutton a...@funkyandroid.com wrote: It cost you nothing, so lighten up. So what if the shipping that you didn't pay for takes longer than was in the original email?, Google are the ones paying for this, so it's entirely under their control, and it's up to them when want to do something about it. If you really are desperate for a Nexus one / Droid go out and buy one then sell it on eBay once your free one arrives. Yes, you'll lose some money, but hey, you're the one desperate for the 'phone and convenience costs. I'd like to suggest that everyone gives up on they Still haven't got my free 'phone emails until the end of April. By that point we'll be well past the timeframe in the email and it's then worth contacting Google directly (not via this list) because if 'phones are getting lost in shipping and Google don't make an insurance claim are not made then the shipping partner involved won't start looking into why 'phones weren't delivered. Al. On Apr 11, 10:29 pm, Genc gmt...@gmail.com wrote: Nothing for London, Grrr... On Apr 10, 10:43 am, Thomas Riley tomrile...@googlemail.com wrote: Still nothing for me in UK either. From what Google have said via email, it's likely to be a few more weeks. Worth the wait though ;) On Apr 10, 9:28 am, dgoemans dgoem...@gmail.com wrote: Still no-one in Europe? Myself and another dev i know in the Netherlands have not got ours yet. On Apr 8, 11:57 pm, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: Sorry, I meant in Europe, no phone seems to have been received outside the US yet except for ADC2 phones (and yes I think I've read the 600+ messages in hope to find one :-)). I think us European will have to wait a couple of weeks more but it's ok, it's a free phone, it's a gift, it could arrive in a few month time and still be a great surprise and a nice touch from Google! On Apr 8, 11:37 pm, ~ TreKing treking...@gmail.com wrote: On Thu, Apr 8, 2010 at 3:52 PM, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: I'm still surprised about Google's comment that many people have already received their phone (for MarketSeedingProgram). If this is true, none of them is reading this thread I guess. If you trudge through the 600+ posts in this thread, you will find that many of them are people posting Got [X Phone] in [Y Location]. Also, those that got their phones are probably busy playing with / developing on them and have long since lost interest in this thread. --- -- TreKing - Chicago transit tracking app for Android-powered deviceshttp://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] findViewById -observation for dynamic Views (not created using layout file)
This is an observation I made while using findViewById() for views which I had made dynamically(they were not in a layout file). I had made these views in onCreate() of Activity, and set their top-level parent view as the content of the Activity thorugh setContentView() within the onCreate() method. When I tried to search a view by parentView.findViewById(id), I sometimes got null. But whenever I tried to search them through activity.findViewById(id) - I was always able to get the View object. I was earlier assuming parentView.findViewById(id) should always return the child View - however, perhaps the fact that these Views are not created through a layout file is causing these quirks. Just posting it here, for the benefit of others who may be trying to find a dynamic view by its Id. If anybody has had other experiences in this regard, please let me know. Thanks, Priyanka -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: .apk and system.img
Hello ! I think your are in the wrong group for this question, as this seems to be more related to android-platform. As a short hint : look at ../vendor/google/apps .. these Apps coming as Prebuild ones .. This is controlled via the Android.mk thier and the line include $ (BUILD_PREBUILT) Good luck ! Frank On 7 Apr., 12:08, elham elhamna...@gmail.com wrote: Hi All! I know how to push a 3rd party app into system.img given the source code but is it possible to push a 3rd party app into system.img with only .apk file . If so please let me know the steps for doing it . 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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Device Seeding Program for Top Android Market Developers
Hopefully Fedex (or whoever is delivering) have your contact information so that they can get in touch and get an alternate address. Still no phone in Norway :-) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] How to set PIN code(in SIM card) ?
When I power on the device, it always appear a input PIN(personal identification number) code screen. The screen has emerge call button, ok button and number button. How to implement the function about auto input PIN code? Can someone give me a hint? Thank you, Vere Perrot -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] newline in toast text
i'm trying to display a toast...that works. but i can't find how to start a newline..so that it looks better. Toast toast = Toast.makeText(this,line1+ '\n' + line2 , Toast.LENGTH_LONG); isn't working. any ideas's -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: how to track all http/https requests
Hi Amardeep, It really depends what you want to do with the data. If it is only for debug purposes, you can set your connection to use wifi and then use WireShark on your pc to log the network traffic. If it is for your app to spy on the phone system wide, I don't know if it is even possible, but I saw a japanese app a few month ago that showed graphs of the diffeent network use in real time. Not sure how it worked or the systems allows such a fine filtering of network data. Yahel On 12 avr, 08:36, Amardeep Jaiman amardeep.jai...@gmail.com wrote: Hi, How to collect URLs of all http/https requests made by the phone as well as well as the return status code and user agent from the headers. This information should be coming for all browser requests and other applications too. Please let me know this information can be retrieved on App level or we have to go to system level for this. Thanks, Amardeep -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Database insertion timings
Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) Yahel On 12 avr, 08:50, Alok Kulkarni kulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] java.io.IOException: sad result from adb:
Hi Folks, I am using eclipse to create an android app. I have recently started getting the following error (and others that also say 'sad result from adb') a lot java.io.IOException: sad result from adb: After this error, the emulator gets disconnected and is not identified when eclipse is asked to relaunch the application. I have to do a 'adb kill-server' and then 'adb start-server' to get it to be identified by eclipse again. Has anybody else run into this? Any ideas why I am getting this and how I can fix it? Thanks Saurabh -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Database insertion timings
According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Did you take into account that the sqlite documentation is probably taking a standard PC (2GHz, 1GB of ram) as its default value not a mobile device with a quarter of the resources ? Yahel -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: Database insertion timings
On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: JavaScript problem in webview
HI brijesh, Take a look at the JavascriptInterface : http://developer.android.com/intl/de/reference/android/webkit/WebView.html#addJavascriptInterface(java.lang.Object, java.lang.String) It allows you to create a bridge between your Android app and the javascript inside the webview. Yahel On 12 avr, 09:26, brijesh masrani masrani.brij...@gmail.com wrote: Hello, I have a JavaScript function which returns a value and i want to use that value in my Android program. Can anyone please tell me how to do that. Regards, Brijesh Masrani -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 make GLSurfaceView show smoothly
Why don't you create your glsurface from the beginning make it transparent and already on top of your image and simply render your 3d objects when the user touches the screen ? The initialization would occurs before the user is presented the image and you would avoid the flickering. Yahel -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Reusable Android library packaging: interest?
We are very aware of the need for this use case (in-house sharing of code/resources), and are working on something. That is good to hear! OpenIntents might be a good place to host a repository of public widgets, as there is already a list of open intents and reusable libraries. I support Mark's effort! Friedger --- www.openintents.org www.droidcon.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] Determining alternate resources selected
Hi QUESTION: How can I determine which alternate resources Android has decided to load? Even simply detecting the language loaded for a particular string (such as the screen title string) would be sufficient. SCENARIO: My application retrieves some localized information from a server. The application currently only supports a few languages and when a particular language is not supported Android falls back to the default application language which is English. I am concerned about the following case: A user's phone is set to a language which my application does not support (for example, Russian). The server nevertheless happens to support Russian. If I ask the phone for its locale using getApplicationContext().getResources().getConfiguration().locale.toString() , I will receive ru , for Russian, since that is what the user set. If I send 'ru' to the server, the server will respond with Russian-language text. My application though is currently displaying everything in English, since that's the default fallback language. Even though the user probably will understand the Russian text (since the phone is set to Russian), it looks quite strange to have the mix of languages on the same screen. (The naive solution is for me to manually crawl my resource folders and then implement a selection process which mimics the selection process that Android performs as described in, How Android finds the best matching directory of http://developer.android.com/guide/topics/resources/resources-i18n.html#AlternateResources . This in general sounds like a bad idea for obvious reasons). 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 To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: How to make GLSurfaceView show smoothly
On Mon, Apr 12, 2010 at 5:11 PM, Yahel kaye...@gmail.com wrote: Why don't you create your glsurface from the beginning make it transparent and already on top of your image and simply render your 3d objects when the user touches the screen ? The initialization would occurs before the user is presented the image and you would avoid the flickering. Yahel Thanks a lot. I will try. I remember I use SetEGLConfigure to make it transparent. Seems that it doesn't work well. I may use it in a incorrect way. I will check my source code right now. Thanks again. -- Best Regards, TANG Jiyu Blog: http://jiyu.wordpress.com.cn/ ezkeypad: http://ezkeypad.tool100.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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Your feedback on Samples/Tutorials/Articles
On Apr 9, 8:02 pm, mike enervat...@gmail.com wrote: On 04/09/2010 11:52 AM, Matt Kanninen wrote: I've been using Sidewiki, it's an easy way to comment on problems with documentation, it's almost as good as directly fixing the docs myself. In principle, is there any reason why this has to be a google-sponsored thing? Couldn't you essentially frame the doc content tree and overlay a comments section? No, but I don't think it will get much use if it isn't. You could use frames (essentially the same as sidewiki), but a better approach might be to modify javadoc to add a comments section to each documentation icon and regenerate the docs using that. This actually looks fairly easy. We need some kind of comments server, and to modify the 'standard doclet': http://java.sun.com/j2se/1.4.2/docs/tooldocs/javadoc/standard-doclet.html to add some javascript to each item. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] How to Validate the Data
Hi Was going through some apps, I found out there was one application with validation, lets say we validate the data on web, similarly can anyone suggest and show a piece of code so that can get it how to do it. Thanks NUBH -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: How to parse JSON in Java?
You can use JSON Parser readily available for this purpose. Since Android platform is compliant with standard J2SE JDK, you can use the readily available open source JSON parsers. You can try http://www.json.org/java Or http://json-lib.sourceforge.net I have used second one. Thanks and Regards Venkatesh T R On Apr 12, 11:10 am, prachi prachi.tya...@wipro.com wrote: To parse the json file it is very much similar to parsing the xml file . first of all u need to create a json array which will captur all ur elements for array posts and then make a json object for each element of jsin array using the function jsonarray.getJSONObject(i) where i is the index I think this will help u put for more details got hrouth the json apis provided by android On Apr 7, 2:05 pm, Maxood maqs...@salsoft.net wrote: I have the following JSON text that i need to parse to get pageName, pagePic, post_id, etc. What is the required code? pageInfo: { pageName: abc pagePic:http://profile.ak.fbcdn.net/object2/367/…} posts: [ { post_id: 160119538822_302076968822 actor_id: 1183856639 picOfPersonWhoPosted:http://profile.ak.fbcdn.net/hprofile-ak-… nameOfPersonWhoPosted: Andrea Raquel message: Sounds cool. Can't wait to see it! likesCount: 2 comments: [ ] timeOfPost: 1266036226 }- 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] Android Phones
hey how to buy a phone for testing applications, can anyone suggest. Other phones in market are way to expensive. NUBH -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Text in a circle that rotates on touch
Hi , I have the same requirement, I have to rotate an image of a wheel as the user moves finger on the wheel on screen. Can u pls tell me how I can use this code thr? What is cx, cy, mPreviousX, mPreviousY? Thanks On Mar 6, 2:56 am, Nathan nathan.d.mel...@gmail.com wrote: On Mar 5, 3:25 am, Bart bvandep...@gmail.com wrote: Hi, I'd like to display a given String in acircle(so bend the string so that the end of the string touches the beginning of the string). And Then I'd like to let the user rotate thecircleby grabbing and dragging it clockwise or counterclockwise. Do you guys know what would be the best (simplest, smoothest) way to do this? I already saw that using drawOnPath i can drawtextin a circle. Do you have any tips on how to proceed with dragging and rotating the textcircle? I've done this, and as mentioned, Canvas.translate and canvas.rotate are the way to go. If you are just using a hold and drag, you wouldn't have to worry so much about angular velocity. Code like this would work: @Override public boolean onTouchEvent(MotionEvent e) { float x = e.getX(); float y = e.getY(); switch (e.getAction()) { case MotionEvent.ACTION_MOVE: //find an approximate angle between them. float dx = x-cx; float dy = y-cy; double a=Math.atan2(dy,dx); float dpx= mPreviousX-cx; float dpy= mPreviousY-cy; double b=Math.atan2(dpy, dpx); double diff = a-b; this.bearing -= Math.toDegrees(diff); this.invalidate(); } mPreviousX = x; mPreviousY = y; return true; } Nathan -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Android Phones
Hi, You will need to purchase either the Android developer phone or you will need some other device by HTC or some other manufacturer. If you still think that its way too expensive then you can with Remote Device testing from sites such as http://www.deviceanywhere.com Hope this helps youp out. Regards Sunil -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Device Seeding Program for Top Android Market Developers
David, Whilst I understand your concern, even if someone posted I got mine and they lived right next door to your old address that doesn't mean yours will have arrived. Yes, we've been told all of the 'phones have been sent out, but the shipping was most likely done in batches and so there could be days or weeks between the first and last UK deliveries. So I'd still suggest you hold out until the end of the month. If your 'phone arrives then great, if it doesn't arrive by the end of the month then drop another email to google and see if they're willing to do something about it, but even if the worst comes to the worst and you don't get a 'phone you're not out of pocket and no worse off than you were before Google decided to give you a freebie. Al. On Apr 12, 8:55 am, dgoemans dgoem...@gmail.com wrote: Al, Thanks and i completely agree... my concern is there's been a big change of situation on my side: no one is available at that address anymore, and i'm moving, so that address will no longer be valid soon. Google have said they're all shipped, so there's nothing i can do about it. And that was 2 weeks ago when i requested the change of address. This is why i'm actively watching this thread. David On Apr 12, 8:44 am, Al Sutton a...@funkyandroid.com wrote: It cost you nothing, so lighten up. So what if the shipping that you didn't pay for takes longer than was in the original email?, Google are the ones paying for this, so it's entirely under their control, and it's up to them when want to do something about it. If you really are desperate for a Nexus one / Droid go out and buy one then sell it on eBay once your free one arrives. Yes, you'll lose some money, but hey, you're the one desperate for the 'phone and convenience costs. I'd like to suggest that everyone gives up on they Still haven't got my free 'phone emails until the end of April. By that point we'll be well past the timeframe in the email and it's then worth contacting Google directly (not via this list) because if 'phones are getting lost in shipping and Google don't make an insurance claim are not made then the shipping partner involved won't start looking into why 'phones weren't delivered. Al. On Apr 11, 10:29 pm, Genc gmt...@gmail.com wrote: Nothing for London, Grrr... On Apr 10, 10:43 am, Thomas Riley tomrile...@googlemail.com wrote: Still nothing for me in UK either. From what Google have said via email, it's likely to be a few more weeks. Worth the wait though ;) On Apr 10, 9:28 am, dgoemans dgoem...@gmail.com wrote: Still no-one in Europe? Myself and another dev i know in the Netherlands have not got ours yet. On Apr 8, 11:57 pm, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: Sorry, I meant in Europe, no phone seems to have been received outside the US yet except for ADC2 phones (and yes I think I've read the 600+ messages in hope to find one :-)). I think us European will have to wait a couple of weeks more but it's ok, it's a free phone, it's a gift, it could arrive in a few month time and still be a great surprise and a nice touch from Google! On Apr 8, 11:37 pm, ~ TreKing treking...@gmail.com wrote: On Thu, Apr 8, 2010 at 3:52 PM, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: I'm still surprised about Google's comment that many people have already received their phone (for MarketSeedingProgram). If this is true, none of them is reading this thread I guess. If you trudge through the 600+ posts in this thread, you will find that many of them are people posting Got [X Phone] in [Y Location]. Also, those that got their phones are probably busy playing with / developing on them and have long since lost interest in this thread. --- -- TreKing - Chicago transit tracking app for Android-powered deviceshttp://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group
[android-developers] Re: Device Seeding Program for Top Android Market Developers
Please read UK deliveries as European deliveries, small brain-fart on my part, sorry. On Apr 12, 10:49 am, Al Sutton a...@funkyandroid.com wrote: David, Whilst I understand your concern, even if someone posted I got mine and they lived right next door to your old address that doesn't mean yours will have arrived. Yes, we've been told all of the 'phones have been sent out, but the shipping was most likely done in batches and so there could be days or weeks between the first and last UK deliveries. So I'd still suggest you hold out until the end of the month. If your 'phone arrives then great, if it doesn't arrive by the end of the month then drop another email to google and see if they're willing to do something about it, but even if the worst comes to the worst and you don't get a 'phone you're not out of pocket and no worse off than you were before Google decided to give you a freebie. Al. On Apr 12, 8:55 am, dgoemans dgoem...@gmail.com wrote: Al, Thanks and i completely agree... my concern is there's been a big change of situation on my side: no one is available at that address anymore, and i'm moving, so that address will no longer be valid soon. Google have said they're all shipped, so there's nothing i can do about it. And that was 2 weeks ago when i requested the change of address. This is why i'm actively watching this thread. David On Apr 12, 8:44 am, Al Sutton a...@funkyandroid.com wrote: It cost you nothing, so lighten up. So what if the shipping that you didn't pay for takes longer than was in the original email?, Google are the ones paying for this, so it's entirely under their control, and it's up to them when want to do something about it. If you really are desperate for a Nexus one / Droid go out and buy one then sell it on eBay once your free one arrives. Yes, you'll lose some money, but hey, you're the one desperate for the 'phone and convenience costs. I'd like to suggest that everyone gives up on they Still haven't got my free 'phone emails until the end of April. By that point we'll be well past the timeframe in the email and it's then worth contacting Google directly (not via this list) because if 'phones are getting lost in shipping and Google don't make an insurance claim are not made then the shipping partner involved won't start looking into why 'phones weren't delivered. Al. On Apr 11, 10:29 pm, Genc gmt...@gmail.com wrote: Nothing for London, Grrr... On Apr 10, 10:43 am, Thomas Riley tomrile...@googlemail.com wrote: Still nothing for me in UK either. From what Google have said via email, it's likely to be a few more weeks. Worth the wait though ;) On Apr 10, 9:28 am, dgoemans dgoem...@gmail.com wrote: Still no-one in Europe? Myself and another dev i know in the Netherlands have not got ours yet. On Apr 8, 11:57 pm, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: Sorry, I meant in Europe, no phone seems to have been received outside the US yet except for ADC2 phones (and yes I think I've read the 600+ messages in hope to find one :-)). I think us European will have to wait a couple of weeks more but it's ok, it's a free phone, it's a gift, it could arrive in a few month time and still be a great surprise and a nice touch from Google! On Apr 8, 11:37 pm, ~ TreKing treking...@gmail.com wrote: On Thu, Apr 8, 2010 at 3:52 PM, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: I'm still surprised about Google's comment that many people have already received their phone (for MarketSeedingProgram). If this is true, none of them is reading this thread I guess. If you trudge through the 600+ posts in this thread, you will find that many of them are people posting Got [X Phone] in [Y Location]. Also, those that got their phones are probably busy playing with / developing on them and have long since lost interest in this thread. --- -- TreKing - Chicago transit tracking app for Android-powered deviceshttp://sites.google.com/site/rezmobileapps/treking -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android
Re: [android-developers] Re: What to use prefrences or Databases
Hey where to write the prefrences in the create block removing the, public class MyOnItemSelectedListener implements OnItemSelectedListener because i mostly seen that while writing preferences to use and the problem is I have four spinners over this place I need to write the same code for four, my basic motto is to save the values and then pass it to the ACTION_CALL as i previously explained can you please suggest. Thanks in Advance NUBH -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: how to track all http/https requests
Can you give me that name of japanese app? actully i want to make a sniffer background application which tracks all the https/https requests made by phone's browser and any other app. i think you have got my requirement. Can anyone else let me know about this ? Thanks, Amardeep On Mon, Apr 12, 2010 at 2:26 PM, Yahel kaye...@gmail.com wrote: Hi Amardeep, It really depends what you want to do with the data. If it is only for debug purposes, you can set your connection to use wifi and then use WireShark on your pc to log the network traffic. If it is for your app to spy on the phone system wide, I don't know if it is even possible, but I saw a japanese app a few month ago that showed graphs of the diffeent network use in real time. Not sure how it worked or the systems allows such a fine filtering of network data. Yahel On 12 avr, 08:36, Amardeep Jaiman amardeep.jai...@gmail.com wrote: Hi, How to collect URLs of all http/https requests made by the phone as well as well as the return status code and user agent from the headers. This information should be coming for all browser requests and other applications too. Please let me know this information can be retrieved on App level or we have to go to system level for this. Thanks, Amardeep -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] CTS Sensnor testcase fail
Hi, I am getting below error from CTS tools for sensor apps. not able to pingpoint what exactly is going wrong during executio of sensor testcases. pls pls help me asap. Issue Category Test Category Issue Description Java Exception testSensorOperationsandroid.hardware.cts.SensorTest java.lang.NullPointerException at android.hardware.cts.SensorTest.testSensorOperations(SensorTest.java: 82) java.lang.NullPointerException Thanks, Saikat -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] DrawableBitmap, Canvas and OR
Hi, Is it in some way possible to draw something with bitwise OR? I.e. I want the pixel values to be OR:ed with the pixel values that already had been drawn. I could invoke get pixel, and use OR, and then set the pixel again, but that would be too slow. Thanks 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 To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: Database insertion timings
Ok, @Yahel:- For the insertion of same records on a Palm device(Say Palm Pre) , its taking 3 seconds.. On an IPhone , its taking 1 or 2 seconds.. Here is an example of what i am doing.. private Boolean addAlbumDB(int AlbumId, String Name, String Label, int MultipleArtists, int ArtistId) { long result = -1; try { ContentValues initialValues = new ContentValues(); initialValues.put(KEY_ID, AlbumId); initialValues.put(KEY_NAME, Name); initialValues.put(KEY_LABEL, Label); initialValues.put(KEY_ARTIST_ID, ArtistId); initialValues.put(KEY_MULTIPLE_ARTISTS, MultipleArtists); result = db.insert(DATABASE_TABLE, null, initialValues); } catch (Exception e) { Log.i(Exception in addAlbumDB, + e.toString()); return false; } if (result == -1) return false; return true; } The above function is called for around 2000 times.. Similarly there are 2 3 more functions for other tables. Thanks, Alok. On Mon, Apr 12, 2010 at 2:33 PM, Michael Rueger mike.rue...@gmail.comwrote: On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Database insertion timings
I have started the transaction before the 1st insert , and ended it after the last insert Thanks, Alok. On Mon, Apr 12, 2010 at 4:01 PM, Alok Kulkarni kulsu...@gmail.com wrote: Ok, @Yahel:- For the insertion of same records on a Palm device(Say Palm Pre) , its taking 3 seconds.. On an IPhone , its taking 1 or 2 seconds.. Here is an example of what i am doing.. private Boolean addAlbumDB(int AlbumId, String Name, String Label, int MultipleArtists, int ArtistId) { long result = -1; try { ContentValues initialValues = new ContentValues(); initialValues.put(KEY_ID, AlbumId); initialValues.put(KEY_NAME, Name); initialValues.put(KEY_LABEL, Label); initialValues.put(KEY_ARTIST_ID, ArtistId); initialValues.put(KEY_MULTIPLE_ARTISTS, MultipleArtists); result = db.insert(DATABASE_TABLE, null, initialValues); } catch (Exception e) { Log.i(Exception in addAlbumDB, + e.toString()); return false; } if (result == -1) return false; return true; } The above function is called for around 2000 times.. Similarly there are 2 3 more functions for other tables. Thanks, Alok. On Mon, Apr 12, 2010 at 2:33 PM, Michael Rueger mike.rue...@gmail.comwrote: On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Device Seeding Program for Top Android Market Developers
The waiting is half the fun of getting a new gadget, and I'm quite enjoying coming on here and watching the progress reports each day, and wondering when it will be time to start getting excited because the European deliveries are starting to arrive. And also hoping that I'll get home from work one day and find that I'm the first :) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] CTS testcase fail for sensor
Hi, I am running CTS tool and got an error related to sensor. Belwo is the error details. testSensorOperationsandroid.hardware.cts.SensorTest java.lang.NullPointerException at android.hardware.cts.SensorTest.testSensorOperations(SensorTest.java: 82) java.lang.NullPointerException I am not able to understand in which scenario this sensor testcase is failing and not able to ping point exact problem. pls pls help me asap. Thanks, kabita -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: How to let soft keyboard overlap the footer of window
Thanks, Murphy. This can not make our customer happy. 1. They want only footer is invisible, not half screen. 2. when scrolling to the EditText at bottom, not all of it is visible. We wonder if there is any event that notifies IME coming out. James -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Video is not rendering
Hi, I have downloaded the video application from google site,ie from http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/media/index.html But copied some video file to my emulator sdcard. But vedio is not rendering instead i am able to listen audio. I installed the same application in android 2.1 real hardware there is also problem and my phone is getting restarted. Any one can help me Regards, Saikiran -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Device Seeding Program for Top Android Market Developers
Nobody here is ungrateful, but I don't think it is unfair of us to be disappointed that our phones have not arrived after 6 weeks, when we're told 2-4. And it's a little naive to think that they aren't doing this for their own benefit, they are being sent so that established developers - who may or may not be considering putting out new applications (considerably more likely to now that they have a shiny new phone), so that we can develop things for their market place, and ultimately they can make money from the app sales. The 30% in transaction fee's that's been taken through my sales could have bought me more than one N1, and cover the cost of manufacturing about half a dozen. And my paid apps are far from top-sellers. But again, I'm not remotely ungrateful, just sad that it hasn't turned up in the time that we were promised. On Apr 12, 10:49 am, Al Sutton a...@funkyandroid.com wrote: David, Whilst I understand your concern, even if someone posted I got mine and they lived right next door to your old address that doesn't mean yours will have arrived. Yes, we've been told all of the 'phones have been sent out, but the shipping was most likely done in batches and so there could be days or weeks between the first and last UK deliveries. So I'd still suggest you hold out until the end of the month. If your 'phone arrives then great, if it doesn't arrive by the end of the month then drop another email to google and see if they're willing to do something about it, but even if the worst comes to the worst and you don't get a 'phone you're not out of pocket and no worse off than you were before Google decided to give you a freebie. Al. On Apr 12, 8:55 am, dgoemans dgoem...@gmail.com wrote: Al, Thanks and i completely agree... my concern is there's been a big change of situation on my side: no one is available at that address anymore, and i'm moving, so that address will no longer be valid soon. Google have said they're all shipped, so there's nothing i can do about it. And that was 2 weeks ago when i requested the change of address. This is why i'm actively watching this thread. David On Apr 12, 8:44 am, Al Sutton a...@funkyandroid.com wrote: It cost you nothing, so lighten up. So what if the shipping that you didn't pay for takes longer than was in the original email?, Google are the ones paying for this, so it's entirely under their control, and it's up to them when want to do something about it. If you really are desperate for a Nexus one / Droid go out and buy one then sell it on eBay once your free one arrives. Yes, you'll lose some money, but hey, you're the one desperate for the 'phone and convenience costs. I'd like to suggest that everyone gives up on they Still haven't got my free 'phone emails until the end of April. By that point we'll be well past the timeframe in the email and it's then worth contacting Google directly (not via this list) because if 'phones are getting lost in shipping and Google don't make an insurance claim are not made then the shipping partner involved won't start looking into why 'phones weren't delivered. Al. On Apr 11, 10:29 pm, Genc gmt...@gmail.com wrote: Nothing for London, Grrr... On Apr 10, 10:43 am, Thomas Riley tomrile...@googlemail.com wrote: Still nothing for me in UK either. From what Google have said via email, it's likely to be a few more weeks. Worth the wait though ;) On Apr 10, 9:28 am, dgoemans dgoem...@gmail.com wrote: Still no-one in Europe? Myself and another dev i know in the Netherlands have not got ours yet. On Apr 8, 11:57 pm, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: Sorry, I meant in Europe, no phone seems to have been received outside the US yet except for ADC2 phones (and yes I think I've read the 600+ messages in hope to find one :-)). I think us European will have to wait a couple of weeks more but it's ok, it's a free phone, it's a gift, it could arrive in a few month time and still be a great surprise and a nice touch from Google! On Apr 8, 11:37 pm, ~ TreKing treking...@gmail.com wrote: On Thu, Apr 8, 2010 at 3:52 PM, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: I'm still surprised about Google's comment that many people have already received their phone (for MarketSeedingProgram). If this is true, none of them is reading this thread I guess. If you trudge through the 600+ posts in this thread, you will find that many of them are people posting Got [X Phone] in [Y Location]. Also, those that got their phones are probably busy playing with / developing on them and have long since lost interest in this thread.
Re: [android-developers] Re: how an activity transfers the value from one activity
Thanks, can you please suggest me how to write preferences code, I havent done that and getting complications while doing so, as I am not able to retreive the data from the other activity, please help. Regards NUBH -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] number of lines in a webview Urgent
Hi all, I'm using webview which loads a html file. When the html file is too large the user has to scroll down all the time. I want to implement it similar to a e-book reader ie.. as pages, by placing a button so that when clicked it shows the next page. But i am unable to remove the scroll bar of the webview. When i reduce the width, the webview width decreases but the scroll bar still remains. How can i disable the scrollbar. Can i control the number of lines to be displayed in a webview. Please help its very urgent 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 To unsubscribe, reply using remove me as the subject.
[android-developers] What should be the image resolution for Nexus One or Droid?
Hi, As Android supports multiple devices from different manufacturers there are different screen resolutions supported. The table that is available at http://developer.android.com/intl/fr/guide/practices/screens_support.html#screen-independence is not very clear to me. It shows WVGA and FWVGA in MDPI for Large Screens and HDPI for Normal screens. So, if the image is kept in drawable-mdpi and its resolution is 320 * 480 then which image will be taken by Large Screens device of MDPI. Moreover, there are two screen resolutions for HDPI i.e. 480 * 800 and 480 * 854. So, with what screen resolution the image should be built. I want to place the background image which looks distorted in WVGA emulator since its resolution is 320 * 480. I have read about nine patchable images but I think they are better for button images and edittext images so that they can stretch according to the data in it. Can someone please guide me in this? Regards Sunil -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] video playing in appwidget.
tina lincon wrote: is it possible to play a video in an appwidget? No, sorry. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.0 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Android Phones
Well depends on what you mean with in market... Are you referring to the ADP's ? Otherwise you might want to look for a second-hand device in your country ? Via ebay or something similar... On 12 apr, 11:35, Nubh nubh.bharg...@gmail.com wrote: hey how to buy a phone for testing applications, can anyone suggest. Other phones in market are way to expensive. NUBH -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: Steps to transfer a simple object from server to android using XML
Anthoni wrote: Hi raqz, I saw your previous post in that you were sending lists of friends via serialization and were advised to use xml instead. Instead of XML you could also use JSON as it is more lightweight than using XML and doesn't take long to implement. I was using XML as my back end for my database to communicate with my application but I changed it all to JSON and haven't looked back since. Here is an article on parsing JSON with Java http://www.androidcompetencycenter.com/2009/10/json-parsing-in-android/ Read through that and it should give you some ideas. There is an article on getting JSON back from the server but I can't find that at moment. Will try and dig it out though. Another advantage of JSON is that there is code built into Android to generate JSON (for shipping *to* a Web server). There is no equivalent of that for XML. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Training...At Your Office: http://commonsware.com/training -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: Internal links in Webview
Anthoni wrote: Hi, Just to interject. Mark explains this beautifully in his book 'Beginning Android', but even more in his PDF books and it is what I use for my details page for items in my database. Basically I have a front activity that shows a search box, that then populates a listview with the headers. The user then clicks a header and the details are retrieved from the database and parsed into a WebView on a separate activity. Inside this WebView I have 'internal' links that allow me to retrieve yet more information that the user might want to know. I do it this way so it doesn't put unnecessary strain on both my database and the users phone. His books are amazing for learning all the nuances of the Android system, so much so I've only had to ask here once about a problem I was having, but that was my mistake lol. Kudos to Mark. Thanks! -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Training...At Your Office: http://commonsware.com/training -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: How to make GLSurfaceView show smoothly
On Mon, Apr 12, 2010 at 5:11 PM, Yahel kaye...@gmail.com wrote: Why don't you create your glsurface from the beginning make it transparent and already on top of your image and simply render your 3d objects when the user touches the screen ? The initialization would occurs before the user is presented the image and you would avoid the flickering. Yahel Tried several times, still cannot make transparent glsurface work. I use setEGLConfigChooser(8, 8, 8, 8, 16, 0) before I setRender(), then use setFormat(PixelFormat.TRANSLUCENT), and use glClearColor(0, 0, 0, 0) in onDrawFrame. I thought this three is the key part of transparent glsurface (I compare the samples in ApiDemo). But I still cannot get what I want. Could anybody give me a hand? Thanks a lot. -- Best Regards, TANG Jiyu Blog: http://jiyu.wordpress.com.cn/ ezkeypad: http://ezkeypad.tool100.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 To unsubscribe, reply using remove me as the subject.
[android-developers] Bluetooth application
Hi All, This is regarding to bluetooth application in Android. When scanning of devices is active, if I invoke Device rename option, then some times the dialog for rename option is not coming. When I see the log, the onClick method of device name change is not invoked!. After scanning completes then that dialog comes or some time it will not display. Why this behavior and what may be the problem for this? Thanks Gururaja B O -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Steps to transfer a simple object from server to android using XML
Thought you actually could according to this article I read couple of weeks ago : http://www.ibm.com/developerworks/opensource/library/x-android/index.html#N1029E Says you can use the XmlSerializer object for that ? On 12 apr, 14:34, Mark Murphy mmur...@commonsware.com wrote: Anthoni wrote: Hi raqz, I saw your previous post in that you were sending lists of friends via serialization and were advised to use xml instead. Instead of XML you could also use JSON as it is more lightweight than using XML and doesn't take long to implement. I was using XML as my back end for my database to communicate with my application but I changed it all to JSON and haven't looked back since. Here is an article on parsing JSON with Java http://www.androidcompetencycenter.com/2009/10/json-parsing-in-android/ Read through that and it should give you some ideas. There is an article on getting JSON back from the server but I can't find that at moment. Will try and dig it out though. Another advantage of JSON is that there is code built into Android to generate JSON (for shipping *to* a Web server). There is no equivalent of that for XML. -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android Training...At Your Office:http://commonsware.com/training -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Disable scroll in webview
Hi all, Is it possible to disable the scrollbar in the webview? If possible how? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Device Seeding Program for Top Android Market Developers
If they were only going to paid-app developers I'd understand your point, but the seeding program is getting devices to lab attendees, forum supporters and free app developers as well as paid ones, so there are a fair number of people in there that won't be making anything back for Google because either they won't release apps or they won't charge for them. As you're no worse off than before you got your email I don't see why you're sad, I'd understand being sad if you'd had to do something or pay something specifically to qualify for the 'phone, but in this case they're rewards for past actions, so you haven't really been put-out and you're definitely not out of pocket if the 'phone doesn't turn up. Al. On Apr 12, 12:48 pm, Richard rtaylor...@googlemail.com wrote: Nobody here is ungrateful, but I don't think it is unfair of us to be disappointed that our phones have not arrived after 6 weeks, when we're told 2-4. And it's a little naive to think that they aren't doing this for their own benefit, they are being sent so that established developers - who may or may not be considering putting out new applications (considerably more likely to now that they have a shiny new phone), so that we can develop things for their market place, and ultimately they can make money from the app sales. The 30% in transaction fee's that's been taken through my sales could have bought me more than one N1, and cover the cost of manufacturing about half a dozen. And my paid apps are far from top-sellers. But again, I'm not remotely ungrateful, just sad that it hasn't turned up in the time that we were promised. On Apr 12, 10:49 am, Al Sutton a...@funkyandroid.com wrote: David, Whilst I understand your concern, even if someone posted I got mine and they lived right next door to your old address that doesn't mean yours will have arrived. Yes, we've been told all of the 'phones have been sent out, but the shipping was most likely done in batches and so there could be days or weeks between the first and last UK deliveries. So I'd still suggest you hold out until the end of the month. If your 'phone arrives then great, if it doesn't arrive by the end of the month then drop another email to google and see if they're willing to do something about it, but even if the worst comes to the worst and you don't get a 'phone you're not out of pocket and no worse off than you were before Google decided to give you a freebie. Al. On Apr 12, 8:55 am, dgoemans dgoem...@gmail.com wrote: Al, Thanks and i completely agree... my concern is there's been a big change of situation on my side: no one is available at that address anymore, and i'm moving, so that address will no longer be valid soon. Google have said they're all shipped, so there's nothing i can do about it. And that was 2 weeks ago when i requested the change of address. This is why i'm actively watching this thread. David On Apr 12, 8:44 am, Al Sutton a...@funkyandroid.com wrote: It cost you nothing, so lighten up. So what if the shipping that you didn't pay for takes longer than was in the original email?, Google are the ones paying for this, so it's entirely under their control, and it's up to them when want to do something about it. If you really are desperate for a Nexus one / Droid go out and buy one then sell it on eBay once your free one arrives. Yes, you'll lose some money, but hey, you're the one desperate for the 'phone and convenience costs. I'd like to suggest that everyone gives up on they Still haven't got my free 'phone emails until the end of April. By that point we'll be well past the timeframe in the email and it's then worth contacting Google directly (not via this list) because if 'phones are getting lost in shipping and Google don't make an insurance claim are not made then the shipping partner involved won't start looking into why 'phones weren't delivered. Al. On Apr 11, 10:29 pm, Genc gmt...@gmail.com wrote: Nothing for London, Grrr... On Apr 10, 10:43 am, Thomas Riley tomrile...@googlemail.com wrote: Still nothing for me in UK either. From what Google have said via email, it's likely to be a few more weeks. Worth the wait though ;) On Apr 10, 9:28 am, dgoemans dgoem...@gmail.com wrote: Still no-one in Europe? Myself and another dev i know in the Netherlands have not got ours yet. On Apr 8, 11:57 pm, olivier.bo...@gmail.com olivier.bo...@gmail.com wrote: Sorry, I meant in Europe, no phone seems to have been received outside the US yet except for ADC2 phones (and yes I think I've read the 600+ messages in hope to find one :-)). I think us European will have to wait a couple of weeks more but it's ok, it's a free phone, it's a gift, it could arrive in a few
[android-developers] Re: Database insertion timings
do you have some code specifically showing the sequence and the syntax ? AAfaik a transaction SHOULD make it faster accroding to this documentation : http://web.utk.edu/~jplyon/sqlite/SQLite_optimization_FAQ.html#transactions On 12 apr, 12:32, Alok Kulkarni kulsu...@gmail.com wrote: I have started the transaction before the 1st insert , and ended it after the last insert Thanks, Alok. On Mon, Apr 12, 2010 at 4:01 PM, Alok Kulkarni kulsu...@gmail.com wrote: Ok, @Yahel:- For the insertion of same records on a Palm device(Say Palm Pre) , its taking 3 seconds.. On an IPhone , its taking 1 or 2 seconds.. Here is an example of what i am doing.. private Boolean addAlbumDB(int AlbumId, String Name, String Label, int MultipleArtists, int ArtistId) { long result = -1; try { ContentValues initialValues = new ContentValues(); initialValues.put(KEY_ID, AlbumId); initialValues.put(KEY_NAME, Name); initialValues.put(KEY_LABEL, Label); initialValues.put(KEY_ARTIST_ID, ArtistId); initialValues.put(KEY_MULTIPLE_ARTISTS, MultipleArtists); result = db.insert(DATABASE_TABLE, null, initialValues); } catch (Exception e) { Log.i(Exception in addAlbumDB, + e.toString()); return false; } if (result == -1) return false; return true; } The above function is called for around 2000 times.. Similarly there are 2 3 more functions for other tables. Thanks, Alok. On Mon, Apr 12, 2010 at 2:33 PM, Michael Rueger mike.rue...@gmail.comwrote: On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: Steps to transfer a simple object from server to android using XML
MobDev wrote: Thought you actually could according to this article I read couple of weeks ago : http://www.ibm.com/developerworks/opensource/library/x-android/index.html#N1029E Says you can use the XmlSerializer object for that ? Every day, I find something else tucked away in some obscure corner of Android... Yes, that should work, at least to the limits of the XmlSerializer class. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 2.0 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: number of lines in a webview Urgent
Did you try using setBuiltInZoomControls(boolean)... http://developer.android.com/reference/android/webkit/WebSettings.html#setBuiltInZoomControls(boolean) May be this is the one you need.. On Apr 12, 5:26 pm, mmkr manutd...@gmail.com wrote: Hi all, I'm using webview which loads a html file. When the html file is too large the user has to scroll down all the time. I want to implement it similar to a e-book reader ie.. as pages, by placing a button so that when clicked it shows the next page. But i am unable to remove the scroll bar of the webview. When i reduce the width, the webview width decreases but the scroll bar still remains. How can i disable the scrollbar. Can i control the number of lines to be displayed in a webview. Please help its very urgent 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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Device Seeding Program for Top Android Market Developers
I agree with Al, in some ways, If Google suddenly said it's not doing the program any more we couldn't complain as it's a free gift. However, the lab attendees, forum supporters and free app developers all have a combined positive effect on the Android platform. Anyway Al, fancy doing an AndAppStore Device Seeding program ? :p Tom. On Apr 12, 1:49 pm, Al Sutton a...@funkyandroid.com wrote: If they were only going to paid-app developers I'd understand your point, but the seeding program is getting devices to lab attendees, forum supporters and free app developers as well as paid ones, so there are a fair number of people in there that won't be making anything back for Google because either they won't release apps or they won't charge for them. As you're no worse off than before you got your email I don't see why you're sad, I'd understand being sad if you'd had to do something or pay something specifically to qualify for the 'phone, but in this case they're rewards for past actions, so you haven't really been put-out and you're definitely not out of pocket if the 'phone doesn't turn up. Al. On Apr 12, 12:48 pm, Richard rtaylor...@googlemail.com wrote: Nobody here is ungrateful, but I don't think it is unfair of us to be disappointed that our phones have not arrived after 6 weeks, when we're told 2-4. And it's a little naive to think that they aren't doing this for their own benefit, they are being sent so that established developers - who may or may not be considering putting out new applications (considerably more likely to now that they have a shiny new phone), so that we can develop things for their market place, and ultimately they can make money from the app sales. The 30% in transaction fee's that's been taken through my sales could have bought me more than one N1, and cover the cost of manufacturing about half a dozen. And my paid apps are far from top-sellers. But again, I'm not remotely ungrateful, just sad that it hasn't turned up in the time that we were promised. On Apr 12, 10:49 am, Al Sutton a...@funkyandroid.com wrote: David, Whilst I understand your concern, even if someone posted I got mine and they lived right next door to your old address that doesn't mean yours will have arrived. Yes, we've been told all of the 'phones have been sent out, but the shipping was most likely done in batches and so there could be days or weeks between the first and last UK deliveries. So I'd still suggest you hold out until the end of the month. If your 'phone arrives then great, if it doesn't arrive by the end of the month then drop another email to google and see if they're willing to do something about it, but even if the worst comes to the worst and you don't get a 'phone you're not out of pocket and no worse off than you were before Google decided to give you a freebie. Al. On Apr 12, 8:55 am, dgoemans dgoem...@gmail.com wrote: Al, Thanks and i completely agree... my concern is there's been a big change of situation on my side: no one is available at that address anymore, and i'm moving, so that address will no longer be valid soon. Google have said they're all shipped, so there's nothing i can do about it. And that was 2 weeks ago when i requested the change of address. This is why i'm actively watching this thread. David On Apr 12, 8:44 am, Al Sutton a...@funkyandroid.com wrote: It cost you nothing, so lighten up. So what if the shipping that you didn't pay for takes longer than was in the original email?, Google are the ones paying for this, so it's entirely under their control, and it's up to them when want to do something about it. If you really are desperate for a Nexus one / Droid go out and buy one then sell it on eBay once your free one arrives. Yes, you'll lose some money, but hey, you're the one desperate for the 'phone and convenience costs. I'd like to suggest that everyone gives up on they Still haven't got my free 'phone emails until the end of April. By that point we'll be well past the timeframe in the email and it's then worth contacting Google directly (not via this list) because if 'phones are getting lost in shipping and Google don't make an insurance claim are not made then the shipping partner involved won't start looking into why 'phones weren't delivered. Al. On Apr 11, 10:29 pm, Genc gmt...@gmail.com wrote: Nothing for London, Grrr... On Apr 10, 10:43 am, Thomas Riley tomrile...@googlemail.com wrote: Still nothing for me in UK either. From what Google have said via email, it's likely to be a few more weeks. Worth the wait though ;) On Apr 10, 9:28 am, dgoemans dgoem...@gmail.com wrote: Still no-one in Europe? Myself and another dev i know in the Netherlands have not got ours
[android-developers] Input/Output Api in android
Hi All, I am having one doubt in java i/o APIs which api should use for input output operation in android applications java i/o or nio APIs ? For basic operation to read input stream which one is recommended ? 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 To unsubscribe, reply using remove me as the subject.
[android-developers] Input/Output Api in android
Hi All, I am having one doubt in java i/o APIs which api should use for input output operation in android applications java i/o or nio APIs ? For basic operation to read input stream which one is recommended ? 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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Downloading a file from a URL extremely slow, optimization advice needed.
is there any suggestion on this issue? On Mar 21, 2:38 am, Stormtap Studios r...@stormtapstudios.com wrote: Hello folks, I have the following code todownloada binaryfilefrom a URL: private static final int BUFFER_SIZE = 1024 * 1024; BufferedInputStream stream = new BufferedInputStream(new URL(MY URL).openStream(), BUFFER_SIZE); BufferedOutputStream fos = new BufferedOutputStream(new FileOutputStream(outputFile)); byte buf[] = new byte[BUFFER_SIZE]; int numBytesRead; do { numBytesRead = stream.read(buf); if (numBytesRead 0) { fos.write(buff, 0, numBytesRead); }} while (numBytesRead 0); fos.flush(); fos.close(); stream.close(); buf = null; Thefilethat I'm downloading is 6.5MB. On the iPhone version of my app it takes about a minute todownload, maybe less on good days. On the Android Dev Phone 2 I'm testing on it takes 10 - 15 minutes todownload, it's EXTREMELY slow. I am looking for any and all advice on how to speed up thedownload for large binary files. One thing I tried was to speed up the writing to the SD card by filling up buf, and then only doing fos.write() when the buffer was full (so roughly 6 and a half writes instead of lots of mini writes). This seemed to have no effect on the overall process, which confirms IMO that the slow part is definitely reading from the URL stream. Thanks very much. Robert Hawkey -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: Database insertion timings
This is a standard class DatabaseHelper extending SQLiteOpenHelper... private static class DatabaseHelper extends SQLiteOpenHelper { DatabaseHelper(Context context, String databaseName) { super(context, databaseName, null, DATABASE_VERSION); } @Override public void onCreate(SQLiteDatabase db) { // Nothing to do } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { Log .w(Upgrade, Upgrading database from version + oldVersion + to + newVersion + , which will destroy all old data); db.execSQL(DROP TABLE IF EXISTS titles); onCreate(db); } } Then i have private SQLiteDatabase db; This db object is used to perform insert operations. Thanks, Alok. // ---opens the database--- public void open() throws SQLException { db = DBHelper.getWritableDatabase(); } On Mon, Apr 12, 2010 at 6:20 PM, MobDev developm...@mobilaria.com wrote: do you have some code specifically showing the sequence and the syntax ? AAfaik a transaction SHOULD make it faster accroding to this documentation : http://web.utk.edu/~jplyon/sqlite/SQLite_optimization_FAQ.html#transactionshttp://web.utk.edu/%7Ejplyon/sqlite/SQLite_optimization_FAQ.html#transactions On 12 apr, 12:32, Alok Kulkarni kulsu...@gmail.com wrote: I have started the transaction before the 1st insert , and ended it after the last insert Thanks, Alok. On Mon, Apr 12, 2010 at 4:01 PM, Alok Kulkarni kulsu...@gmail.com wrote: Ok, @Yahel:- For the insertion of same records on a Palm device(Say Palm Pre) , its taking 3 seconds.. On an IPhone , its taking 1 or 2 seconds.. Here is an example of what i am doing.. private Boolean addAlbumDB(int AlbumId, String Name, String Label, int MultipleArtists, int ArtistId) { long result = -1; try { ContentValues initialValues = new ContentValues(); initialValues.put(KEY_ID, AlbumId); initialValues.put(KEY_NAME, Name); initialValues.put(KEY_LABEL, Label); initialValues.put(KEY_ARTIST_ID, ArtistId); initialValues.put(KEY_MULTIPLE_ARTISTS, MultipleArtists); result = db.insert(DATABASE_TABLE, null, initialValues); } catch (Exception e) { Log.i(Exception in addAlbumDB, + e.toString()); return false; } if (result == -1) return false; return true; } The above function is called for around 2000 times.. Similarly there are 2 3 more functions for other tables. Thanks, Alok. On Mon, Apr 12, 2010 at 2:33 PM, Michael Rueger mike.rue...@gmail.com wrote: On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more
Re: [android-developers] Re: Downloading a file from a URL extremely slow, optimization advice needed.
Engin Arslan wrote: is there any suggestion on this issue? http://groups.google.com/group/android-beginners/browse_thread/thread/fd4b684435b00463/5751bac16fcac8e2 Net: there is no issue, other than with the OP's phone. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _The Busy Coder's Guide to *Advanced* Android Development_ Version 1.4 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Conversion to Dalvik format failed with error
Hi I am a newbie in developing android applications. There are few problems while development. I’ll start with few, [2010-03-25 14:24:22 - Dialing]Conversion to Dalvik format failed with error I don’t know why it is generation some error of this sort read there are some settings we need to do while setting up an android project I don’t understand from where to go there as I am new to android environment . [2010-03-25 14:17:39 - Dialing]java.io.IOException: Unable to upload file: Local file doesn't exist. [2010-03-25 14:17:39 - Dialing]Launch canceled! [2010-03-25 14:24:22 - Dialing] trouble processing java/lang/Object.class: [2010-03-25 14:24:22 - Dialing] Attempt to include a core VM class in something other than a core library. It is likely that you have attempted to include the core library from a desktop virtual machine into an application, which will most assuredly not work. If you really intend to build a core library -- which is only appropriate as part of creating a full virtual machine binary, as opposed to compiling an application -- then use the --core-library option to suppress this error message. If you go ahead and use --core-library but are in fact building an application, then please be aware that your build will still fail at some point; you will simply be denied the pleasure of reading this helpful error message. This is the exact message that is coming in the eclipse, I searched on the Google also got response that some settings in eclipse has to be changed like below and followed this mail “ The problem is that GAE plugin for Eclipse is default configured with a JRE instead of a JDK. To change this, do the following: Preferences Java Installed JRE's Add... For 'JRE Type' select 'Standard VM' Next Directory: select your JDK directory (instead of JRE) (in my case: C:\Program Files\Java\jdk1.6.0_16 ), press OK. Now, you are back at 'Installed JRE's', select the JDK here also. ” Still the problem is persistent can u help.. The problem is with particular programs where I am trying to call an activity after clicking a button in the main activity. Thanking in advance for the solution, nubh -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Database insertion timings
I don't see a specific transaction ??? Anyways transaction should only be used if you have multiple actions you are doing on your database (like several insert/update operations)... On 12 apr, 15:43, Alok Kulkarni kulsu...@gmail.com wrote: This is a standard class DatabaseHelper extending SQLiteOpenHelper... private static class DatabaseHelper extends SQLiteOpenHelper { DatabaseHelper(Context context, String databaseName) { super(context, databaseName, null, DATABASE_VERSION); } @Override public void onCreate(SQLiteDatabase db) { // Nothing to do } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { Log .w(Upgrade, Upgrading database from version + oldVersion + to + newVersion + , which will destroy all old data); db.execSQL(DROP TABLE IF EXISTS titles); onCreate(db); } } Then i have private SQLiteDatabase db; This db object is used to perform insert operations. Thanks, Alok. // ---opens the database--- public void open() throws SQLException { db = DBHelper.getWritableDatabase(); } On Mon, Apr 12, 2010 at 6:20 PM, MobDev developm...@mobilaria.com wrote: do you have some code specifically showing the sequence and the syntax ? AAfaik a transaction SHOULD make it faster accroding to this documentation : http://web.utk.edu/~jplyon/sqlite/SQLite_optimization_FAQ.html#transa...http://web.utk.edu/%7Ejplyon/sqlite/SQLite_optimization_FAQ.html#tran... On 12 apr, 12:32, Alok Kulkarni kulsu...@gmail.com wrote: I have started the transaction before the 1st insert , and ended it after the last insert Thanks, Alok. On Mon, Apr 12, 2010 at 4:01 PM, Alok Kulkarni kulsu...@gmail.com wrote: Ok, @Yahel:- For the insertion of same records on a Palm device(Say Palm Pre) , its taking 3 seconds.. On an IPhone , its taking 1 or 2 seconds.. Here is an example of what i am doing.. private Boolean addAlbumDB(int AlbumId, String Name, String Label, int MultipleArtists, int ArtistId) { long result = -1; try { ContentValues initialValues = new ContentValues(); initialValues.put(KEY_ID, AlbumId); initialValues.put(KEY_NAME, Name); initialValues.put(KEY_LABEL, Label); initialValues.put(KEY_ARTIST_ID, ArtistId); initialValues.put(KEY_MULTIPLE_ARTISTS, MultipleArtists); result = db.insert(DATABASE_TABLE, null, initialValues); } catch (Exception e) { Log.i(Exception in addAlbumDB, + e.toString()); return false; } if (result == -1) return false; return true; } The above function is called for around 2000 times.. Similarly there are 2 3 more functions for other tables. Thanks, Alok. On Mon, Apr 12, 2010 at 2:33 PM, Michael Rueger mike.rue...@gmail.com wrote: On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com android-developers%2bunsubscr...@googlegroups.comandroid-developers%252bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at
[android-developers] Problem accessing Layer-List items
Hi guys I have a Style declared as follows *XML:* ?xml version=1.0 encoding=utf-8? layer-list xmlns:android=http://schemas.android.com/apk/res/android; item android:id=@android:id/background android:drawable= @drawable/progbar2_320x480 /item item android:id=@android:id/secondaryProgress clip shape solid android:color=#4A7116 / /shape /clip /item item android:id=@android:id/progress clip shape solid android:color=#95BB1C / /shape /clip /item /layer-list I want to change the color of progressbar and secondary progressbar at runtime. How can i do that.. There is a function in LayerDrawable as * * findDrawableByLayerId(android.R.id.progress); or * * findDrawableByLayerId(android.R.id.secondaryProgress); but i am not getting how to use that.. Thanks , Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] how add TextView/Layout to map's Overlay or OverlayItem?
When a marker is clicked on google map, a small square area is displayed with hyperlinks. I guess OverlayItem does not render hyperlinks for its snippet. How to achieve this? Ideally I want to assign a layout with all sorts widgets. Presume I can display a small floating activity window when the marker is clicked, but is this the standard way doing this? The drawback of floating activity window is that if want to click another marker, user has to dismiss the current window first. Thanks, Derek -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: Database insertion timings
Before the 1st insert call i am doing db.beginTransaction(); for(i = 0 i 2000 ; i++) addAlbumDB(); for(i = 0 i 3000 ; i++) addArtistDB(); for(i = 0 i 2000 ; i++) addSongDB(); try { db.setTransactionSuccessful(); } finally { db.endTransaction(); } On Mon, Apr 12, 2010 at 7:18 PM, MobDev developm...@mobilaria.com wrote: I don't see a specific transaction ??? Anyways transaction should only be used if you have multiple actions you are doing on your database (like several insert/update operations)... On 12 apr, 15:43, Alok Kulkarni kulsu...@gmail.com wrote: This is a standard class DatabaseHelper extending SQLiteOpenHelper... private static class DatabaseHelper extends SQLiteOpenHelper { DatabaseHelper(Context context, String databaseName) { super(context, databaseName, null, DATABASE_VERSION); } @Override public void onCreate(SQLiteDatabase db) { // Nothing to do } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { Log .w(Upgrade, Upgrading database from version + oldVersion + to + newVersion + , which will destroy all old data); db.execSQL(DROP TABLE IF EXISTS titles); onCreate(db); } } Then i have private SQLiteDatabase db; This db object is used to perform insert operations. Thanks, Alok. // ---opens the database--- public void open() throws SQLException { db = DBHelper.getWritableDatabase(); } On Mon, Apr 12, 2010 at 6:20 PM, MobDev developm...@mobilaria.com wrote: do you have some code specifically showing the sequence and the syntax ? AAfaik a transaction SHOULD make it faster accroding to this documentation : http://web.utk.edu/~jplyon/sqlite/SQLite_optimization_FAQ.html#transa..http://web.utk.edu/%7Ejplyon/sqlite/SQLite_optimization_FAQ.html#transa.. .http://web.utk.edu/%7Ejplyon/sqlite/SQLite_optimization_FAQ.html#tran.. . On 12 apr, 12:32, Alok Kulkarni kulsu...@gmail.com wrote: I have started the transaction before the 1st insert , and ended it after the last insert Thanks, Alok. On Mon, Apr 12, 2010 at 4:01 PM, Alok Kulkarni kulsu...@gmail.com wrote: Ok, @Yahel:- For the insertion of same records on a Palm device(Say Palm Pre) , its taking 3 seconds.. On an IPhone , its taking 1 or 2 seconds.. Here is an example of what i am doing.. private Boolean addAlbumDB(int AlbumId, String Name, String Label, int MultipleArtists, int ArtistId) { long result = -1; try { ContentValues initialValues = new ContentValues(); initialValues.put(KEY_ID, AlbumId); initialValues.put(KEY_NAME, Name); initialValues.put(KEY_LABEL, Label); initialValues.put(KEY_ARTIST_ID, ArtistId); initialValues.put(KEY_MULTIPLE_ARTISTS, MultipleArtists); result = db.insert(DATABASE_TABLE, null, initialValues); } catch (Exception e) { Log.i(Exception in addAlbumDB, + e.toString()); return false; } if (result == -1) return false; return true; } The above function is called for around 2000 times.. Similarly there are 2 3 more functions for other tables. Thanks, Alok. On Mon, Apr 12, 2010 at 2:33 PM, Michael Rueger mike.rue...@gmail.com wrote: On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com
Re: [android-developers] Re: Database insertion timings
Each of these above functions insert records in 3 seperate tables in the same database. Thanks , Alok On Mon, Apr 12, 2010 at 7:51 PM, Alok Kulkarni kulsu...@gmail.com wrote: Before the 1st insert call i am doing db.beginTransaction(); for(i = 0 i 2000 ; i++) addAlbumDB(); for(i = 0 i 3000 ; i++) addArtistDB(); for(i = 0 i 2000 ; i++) addSongDB(); try { db.setTransactionSuccessful(); } finally { db.endTransaction(); } On Mon, Apr 12, 2010 at 7:18 PM, MobDev developm...@mobilaria.com wrote: I don't see a specific transaction ??? Anyways transaction should only be used if you have multiple actions you are doing on your database (like several insert/update operations)... On 12 apr, 15:43, Alok Kulkarni kulsu...@gmail.com wrote: This is a standard class DatabaseHelper extending SQLiteOpenHelper... private static class DatabaseHelper extends SQLiteOpenHelper { DatabaseHelper(Context context, String databaseName) { super(context, databaseName, null, DATABASE_VERSION); } @Override public void onCreate(SQLiteDatabase db) { // Nothing to do } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { Log .w(Upgrade, Upgrading database from version + oldVersion + to + newVersion + , which will destroy all old data); db.execSQL(DROP TABLE IF EXISTS titles); onCreate(db); } } Then i have private SQLiteDatabase db; This db object is used to perform insert operations. Thanks, Alok. // ---opens the database--- public void open() throws SQLException { db = DBHelper.getWritableDatabase(); } On Mon, Apr 12, 2010 at 6:20 PM, MobDev developm...@mobilaria.com wrote: do you have some code specifically showing the sequence and the syntax ? AAfaik a transaction SHOULD make it faster accroding to this documentation : http://web.utk.edu/~jplyon/sqlite/SQLite_optimization_FAQ.html#transa..http://web.utk.edu/%7Ejplyon/sqlite/SQLite_optimization_FAQ.html#transa.. .http://web.utk.edu/%7Ejplyon/sqlite/SQLite_optimization_FAQ.html#tran.. . On 12 apr, 12:32, Alok Kulkarni kulsu...@gmail.com wrote: I have started the transaction before the 1st insert , and ended it after the last insert Thanks, Alok. On Mon, Apr 12, 2010 at 4:01 PM, Alok Kulkarni kulsu...@gmail.com wrote: Ok, @Yahel:- For the insertion of same records on a Palm device(Say Palm Pre) , its taking 3 seconds.. On an IPhone , its taking 1 or 2 seconds.. Here is an example of what i am doing.. private Boolean addAlbumDB(int AlbumId, String Name, String Label, int MultipleArtists, int ArtistId) { long result = -1; try { ContentValues initialValues = new ContentValues(); initialValues.put(KEY_ID, AlbumId); initialValues.put(KEY_NAME, Name); initialValues.put(KEY_LABEL, Label); initialValues.put(KEY_ARTIST_ID, ArtistId); initialValues.put(KEY_MULTIPLE_ARTISTS, MultipleArtists); result = db.insert(DATABASE_TABLE, null, initialValues); } catch (Exception e) { Log.i(Exception in addAlbumDB, + e.toString()); return false; } if (result == -1) return false; return true; } The above function is called for around 2000 times.. Similarly there are 2 3 more functions for other tables. Thanks, Alok. On Mon, Apr 12, 2010 at 2:33 PM, Michael Rueger mike.rue...@gmail.com wrote: On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe
[android-developers] Draw Text on GLSurfaceView
Hi, Can anyone help me to understand how to draw text on GLSurfaceView in Android ? Thanks in advance Ren -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] how add TextView/Layout to map's Overlay or OverlayItem?
Derek wrote: When a marker is clicked on google map, a small square area is displayed with hyperlinks. I guess OverlayItem does not render hyperlinks for its snippet. How to achieve this? Ideally I want to assign a layout with all sorts widgets. Presume I can display a small floating activity window when the marker is clicked, but is this the standard way doing this? The drawback of floating activity window is that if want to click another marker, user has to dismiss the current window first. Pop up a panel over the map when the user taps on a marker: http://github.com/commonsguy/cw-advandroid/tree/master/Maps/EvenNooerYawk/ What you put in the panel -- buttons, links, etc. -- is up to you. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _Beginning Android 2_ from Apress Now Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Draw Text on GLSurfaceView
On Mon, Apr 12, 2010 at 10:39 PM, Renjith renjithkum...@gmail.com wrote: Hi, Can anyone help me to understand how to draw text on GLSurfaceView in Android ? Thanks in advance Ren You cannot draw text on glsurface. What you can do is draw text on a bitmap, then bind this bitmap as texture to glsurface, user drawElement to show this bitmap. You could check ApiDemo to learn how to draw bitmap on glsurface. Good luck. -- Best Regards, TANG Jiyu Blog: http://jiyu.wordpress.com.cn/ ezkeypad: http://ezkeypad.tool100.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 To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Disable scroll in webview
On Mon, Apr 12, 2010 at 8:48 PM, mmkr manutd...@gmail.com wrote: Hi all, Is it possible to disable the scrollbar in the webview? If possible how? Maybe not exactly, I remember there are some interfaces like enable/disable scroll bar in WebView.java. Is that OK for you? -- Best Regards, TANG Jiyu Blog: http://jiyu.wordpress.com.cn/ ezkeypad: http://ezkeypad.tool100.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 To unsubscribe, reply using remove me as the subject.
[android-developers] sending MMS programming
Hi, Is there any options to send MMS(not calling activity ) - no user action for example a service that run in the background and send MMS with the a random pictures . I found solution to SMS but not to MMS 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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: ListView Example
Any sample code please??? Thanks, -DK On Apr 9, 3:50 pm, Martin Obreshkov manig...@gmail.com wrote: I think ArrayAdapter is the think you're looking for. For more infohttp://developer.android.com/reference/android/widget/ArrayAdapter.htmlit supports add/delete methods which automatically update listview. On Fri, Apr 9, 2010 at 10:38 PM, dillipk codersnet2...@gmail.com wrote: Hi, I am looking for a ListView example which would have functionalities such as add/delete/deleteall items from the list view at run time. Also all the items should be added to the ListView dynamically. Each item may contain an image, couple of textview, one Button. Probably using a Custom class extends from BaseAdapter I would really appreciate for your help. Thanks, -DK -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- When I raise my flashing sword, and my hand takes hold on judgment, I will take vengeance upon mine enemies, and I will repay those who haze me. Oh, Lord, raise me to Thy right hand and count me among Thy saints. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 WebView render the webpage
Hi Guys, I'm reading the source code of Android browser, try to figure out how WebView render the webpage. In native (external/webkit/WebKit/android/jni/WebViewCore.cpp), seems the whole webpage is stored in WebViewCore.m_content (a PictureSet). In every onDraw, native just draw the PictureSet on canvas. But I think the whole page is kind of a logical picture, why here use a vector to store a bunch of Pictures (defined in PictureSet.h). What are they for? When drag the webpage, why the rendering time of each onDraw is different? I think if the webpage (or we can say Pictures) is the same, rendering time should be same. What's you guys opinion? Thanks for sharing. -- Best Regards, TANG Jiyu Blog: http://jiyu.wordpress.com.cn/ ezkeypad: http://ezkeypad.tool100.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 To unsubscribe, reply using remove me as the subject.
[android-developers] How to enable klogd / syslogd for debuggin
Hi all, I am developing the android device and system will hang randomly, I like to enable klogd / syslogd to keep log for debugging at next boot. would you please provide your experience to guide me how to enable this function. BTW, I know the busybox contain the klogd / syslogd function, did anyone use this function before? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] How to enable klogd / syslogd for debuggin
android-developers is for application developers, try android-porting if you're trying to port the system to a different device. On Mon, Apr 12, 2010 at 8:27 AM, Luke vagrant...@gmail.com wrote: Hi all, I am developing the android device and system will hang randomly, I like to enable klogd / syslogd to keep log for debugging at next boot. would you please provide your experience to guide me how to enable this function. BTW, I know the busybox contain the klogd / syslogd function, did anyone use this function before? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Disable scroll in webview
ya it will be. my requirement is i want to display a large html file in number of pages such that each page would fit exactly into a single screen. I will place a button so that when clicked it would show the next page. On Mon, Apr 12, 2010 at 8:22 PM, A.TNG tang.j...@gmail.com wrote: On Mon, Apr 12, 2010 at 8:48 PM, mmkr manutd...@gmail.com wrote: Hi all, Is it possible to disable the scrollbar in the webview? If possible how? Maybe not exactly, I remember there are some interfaces like enable/disable scroll bar in WebView.java. Is that OK for you? -- Best Regards, TANG Jiyu Blog: http://jiyu.wordpress.com.cn/ ezkeypad: http://ezkeypad.tool100.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.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Database insertion timings
Actually, Im just guessing here, shouldnt you use staretTransaction and endTransaction instead of setTransactionSuccesfull() ??? Right now you as a developer are specifically marking the transaction as succesfull, is that what you want ? On 12 apr, 16:22, Alok Kulkarni kulsu...@gmail.com wrote: Each of these above functions insert records in 3 seperate tables in the same database. Thanks , Alok On Mon, Apr 12, 2010 at 7:51 PM, Alok Kulkarni kulsu...@gmail.com wrote: Before the 1st insert call i am doing db.beginTransaction(); for(i = 0 i 2000 ; i++) addAlbumDB(); for(i = 0 i 3000 ; i++) addArtistDB(); for(i = 0 i 2000 ; i++) addSongDB(); try { db.setTransactionSuccessful(); } finally { db.endTransaction(); } On Mon, Apr 12, 2010 at 7:18 PM, MobDev developm...@mobilaria.com wrote: I don't see a specific transaction ??? Anyways transaction should only be used if you have multiple actions you are doing on your database (like several insert/update operations)... On 12 apr, 15:43, Alok Kulkarni kulsu...@gmail.com wrote: This is a standard class DatabaseHelper extending SQLiteOpenHelper... private static class DatabaseHelper extends SQLiteOpenHelper { DatabaseHelper(Context context, String databaseName) { super(context, databaseName, null, DATABASE_VERSION); } @Override public void onCreate(SQLiteDatabase db) { // Nothing to do } @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { Log .w(Upgrade, Upgrading database from version + oldVersion + to + newVersion + , which will destroy all old data); db.execSQL(DROP TABLE IF EXISTS titles); onCreate(db); } } Then i have private SQLiteDatabase db; This db object is used to perform insert operations. Thanks, Alok. // ---opens the database--- public void open() throws SQLException { db = DBHelper.getWritableDatabase(); } On Mon, Apr 12, 2010 at 6:20 PM, MobDev developm...@mobilaria.com wrote: do you have some code specifically showing the sequence and the syntax ? AAfaik a transaction SHOULD make it faster accroding to this documentation : http://web.utk.edu/~jplyon/sqlite/SQLite_optimization_FAQ.html#transa..http://web.utk.edu/%7Ejplyon/sqlite/SQLite_optimization_FAQ.html#transa.. .http://web.utk.edu/%7Ejplyon/sqlite/SQLite_optimization_FAQ.html#tran.. . On 12 apr, 12:32, Alok Kulkarni kulsu...@gmail.com wrote: I have started the transaction before the 1st insert , and ended it after the last insert Thanks, Alok. On Mon, Apr 12, 2010 at 4:01 PM, Alok Kulkarni kulsu...@gmail.com wrote: Ok, @Yahel:- For the insertion of same records on a Palm device(Say Palm Pre) , its taking 3 seconds.. On an IPhone , its taking 1 or 2 seconds.. Here is an example of what i am doing.. private Boolean addAlbumDB(int AlbumId, String Name, String Label, int MultipleArtists, int ArtistId) { long result = -1; try { ContentValues initialValues = new ContentValues(); initialValues.put(KEY_ID, AlbumId); initialValues.put(KEY_NAME, Name); initialValues.put(KEY_LABEL, Label); initialValues.put(KEY_ARTIST_ID, ArtistId); initialValues.put(KEY_MULTIPLE_ARTISTS, MultipleArtists); result = db.insert(DATABASE_TABLE, null, initialValues); } catch (Exception e) { Log.i(Exception in addAlbumDB, + e.toString()); return false; } if (result == -1) return false; return true; } The above function is called for around 2000 times.. Similarly there are 2 3 more functions for other tables. Thanks, Alok. On Mon, Apr 12, 2010 at 2:33 PM, Michael Rueger mike.rue...@gmail.com wrote: On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite
[android-developers] Problem Observed with gestureoverlay method
Hi, I am using gestureoverlay metod to detect gesture in my application.I have a view group in which i have multiple text views embedded into it.I have set the onlongclicklistener for the individual views but observed that when I set gesture listener through gestures.addOnGesturePerformedListener(this) control is not coming to the onlongclick() function(when i long click on the view).When i disable the gestures.addOnGesturePerformedListener(this) control comes to onlongclick(). What could be the problem? Thanks, Shekhar -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] Re: how to track all http/https requests
Name of the app was something like 91nettraffic. As for a sniffer, i'm not sure the framework gives you access to such low level function. But if it does, then it will be a great and very useful app for developpersand spies, and trojan, and...Hmmm well with great power, comes great responsability :D Yahel On 12 avr, 12:13, Amardeep Jaiman amardeep.jai...@gmail.com wrote: Can you give me that name of japanese app? actully i want to make a sniffer background application which tracks all the https/https requests made by phone's browser and any other app. i think you have got my requirement. Can anyone else let me know about this ? Thanks, Amardeep On Mon, Apr 12, 2010 at 2:26 PM, Yahel kaye...@gmail.com wrote: Hi Amardeep, It really depends what you want to do with the data. If it is only for debug purposes, you can set your connection to use wifi and then use WireShark on your pc to log the network traffic. If it is for your app to spy on the phone system wide, I don't know if it is even possible, but I saw a japanese app a few month ago that showed graphs of the diffeent network use in real time. Not sure how it worked or the systems allows such a fine filtering of network data. Yahel On 12 avr, 08:36, Amardeep Jaiman amardeep.jai...@gmail.com wrote: Hi, How to collect URLs of all http/https requests made by the phone as well as well as the return status code and user agent from the headers. This information should be coming for all browser requests and other applications too. Please let me know this information can be retrieved on App level or we have to go to system level for this. Thanks, Amardeep -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2Bunsubs cr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: Android Phones
javame Have you used device anywhere? I have been checking them out and considering on trying them out but wanted the opinion of anyone that has used them and if they are worth the money to test with. Thank you -Chris On Mon, Apr 12, 2010 at 6:28 AM, MobDev developm...@mobilaria.com wrote: Well depends on what you mean with in market... Are you referring to the ADP's ? Otherwise you might want to look for a second-hand device in your country ? Via ebay or something similar... On 12 apr, 11:35, Nubh nubh.bharg...@gmail.com wrote: hey how to buy a phone for testing applications, can anyone suggest. Other phones in market are way to expensive. NUBH -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Database insertion timings
Ok, you are right if the pre and the iphone are 10x faster, it can't be right. I don't see anything wrong in your code, so only two things come to mind : - Instead of using ContentValues, try to create an insert sql statement and send it to via SQLiteDatabase.execSQL to see if there is any improvement - Maybe it's not the database writing that is slow but the reading from wherever your getting the data ? Yahel On 12 avr, 12:31, Alok Kulkarni kulsu...@gmail.com wrote: Ok, @Yahel:- For the insertion of same records on a Palm device(Say Palm Pre) , its taking 3 seconds.. On an IPhone , its taking 1 or 2 seconds.. Here is an example of what i am doing.. private Boolean addAlbumDB(int AlbumId, String Name, String Label, int MultipleArtists, int ArtistId) { long result = -1; try { ContentValues initialValues = new ContentValues(); initialValues.put(KEY_ID, AlbumId); initialValues.put(KEY_NAME, Name); initialValues.put(KEY_LABEL, Label); initialValues.put(KEY_ARTIST_ID, ArtistId); initialValues.put(KEY_MULTIPLE_ARTISTS, MultipleArtists); result = db.insert(DATABASE_TABLE, null, initialValues); } catch (Exception e) { Log.i(Exception in addAlbumDB, + e.toString()); return false; } if (result == -1) return false; return true; } The above function is called for around 2000 times.. Similarly there are 2 3 more functions for other tables. Thanks, Alok. On Mon, Apr 12, 2010 at 2:33 PM, Michael Rueger mike.rue...@gmail.comwrote: On 4/12/2010 10:59 AM, Yahel wrote: Hi Alok, Posting some logic, or some sql would help us see if you are missing something :) (excessive) use of indices comes to mind :-) Michael Yahel On 12 avr, 08:50, Alok Kulkarnikulsu...@gmail.com wrote: Hi, I am inserting around 7000 to 8000 records in my database having 4 tables each having 3 to 4 columns.Its taking me around 22 seconds to do the insertion which is i think is too long. I am using transaction while doing this without which its taking around 55 seconds. According to SQLite documentation , inserting 1 records in a database takes time around 2 to 3 seconds. Am i missing something , or is the behaviour correct? Thanks, Alok -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2Bunsubs cr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: unable to open database file after OS upgrade
Now a user was nice enough to run some commands for me. It seems that the database is there and is not corrupt: # ls -l /data/data/com.newsrob/databases ls -l /data/data/com.newsrob/databases -rw-rw app_108 app_108 16384 2010-04-11 13:12 webview.db -rw-rw app_108 app_108 6144 2010-04-11 13:12 webviewCache.db -rw-rw app_108 app_108277504 2010-04-11 16:38 newsrob.db And with sqlite3 from the command line: select count(*) from entries; 51 On Sat, Apr 10, 2010 at 9:10 AM, Mariano Kamp mariano.k...@gmail.com wrote: Yes, that worked for me too. Actually re-installing the apps on the users' phones alone was enough. But this is just dealing with the symptoms and would've liked to know why the OS updates break apps and if there are any counter measures the developer can do? And also meanwhile I got more than 50 of those issues (for a 65.000 active installs app) and it really takes away from my time to work on my app. As it seems that the Android OS developers don't chimp with enlightenment in here I will automate the workaround then and let the user know that this issue was caused by the OS updated and he should re-install my app and potentially others. On Sat, Apr 10, 2010 at 7:25 AM, Walter androidremotecont...@gmail.com wrote: Some users of my apps also reported same issue, also same exception in the log. What you can do is: Uninstall your app, power off, power on. if that doesn't work and the phone is rooted, ask the user to clean the app cache, and not install app on SDCard. That resolved all these kind of open database and file corruption issues. Walter On Apr 9, 12:46 pm, Mariano Kamp mariano.k...@gmail.com wrote: Mariano Kamp wrote: I could ask the people with custom ROMs to check if the db-file is still there. Or add your own exception handler for this, do some experiments, and then send the results to yourself via whatever mechanism you're using to get the stack trace. That's a good idea, but it will take some time to deploy. As I haven't gotten any other feedback I will still do that then. FWIW, I have not run into this problem as an end user. No, me neither. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] newline in toast text
line1\nline2 On Mon, Apr 12, 2010 at 3:50 AM, arnoldl arn...@fortuin.nl wrote: i'm trying to display a toast...that works. but i can't find how to start a newline..so that it looks better. Toast toast = Toast.makeText(this,line1+ '\n' + line2 , Toast.LENGTH_LONG); isn't working. any ideas's -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 make GLSurfaceView show smoothly
Hi, You should take a look at the api demo which is in the samples given with the android sdk : http://developer.android.com/intl/de/resources/samples/get.html Under Graphics/OpenGL Es/Translucent GLSurfaceView You'll find out how it is done. Yahel On 12 avr, 14:35, A.TNG tang.j...@gmail.com wrote: On Mon, Apr 12, 2010 at 5:11 PM, Yahel kaye...@gmail.com wrote: Why don't you create your glsurface from the beginning make it transparent and already on top of your image and simply render your 3d objects when the user touches the screen ? The initialization would occurs before the user is presented the image and you would avoid the flickering. Yahel Tried several times, still cannot make transparent glsurface work. I use setEGLConfigChooser(8, 8, 8, 8, 16, 0) before I setRender(), then use setFormat(PixelFormat.TRANSLUCENT), and use glClearColor(0, 0, 0, 0) in onDrawFrame. I thought this three is the key part of transparent glsurface (I compare the samples in ApiDemo). But I still cannot get what I want. Could anybody give me a hand? Thanks a lot. -- Best Regards, TANG Jiyu Blog:http://jiyu.wordpress.com.cn/ ezkeypad:http://ezkeypad.tool100.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 To unsubscribe, reply using remove me as the subject.
[android-developers] How to properly implement ParcelFileDescriptor.openFile() method.
Hi, I have a ContentProvider that serves an image to default built in image viewer. Ever since Android 2.1 the built in image viewer throws FileNotFound into the log. I also find this in the log: 04-12 09:28:54.066: ERROR/UriTexture(11541): Unable to load image from URI content://com.gnugu.secretboxplus.imageprovider/test.jpg The file indeed does exist, I write it on sdcard. Here is a piece of code in openFile() method: File FILE_NAME = new File(DataAdapter.DATABASE_FILE_PATH, test.jpg); FILE_NAME.createNewFile(); FileOutputStream fileStream = new FileOutputStream(FILE_NAME); fileStream.write(pictureData); fileStream.flush(); fileStream.close(); // now open the file descriptor ParcelFileDescriptor result = ParcelFileDescriptor.open(ctx.getFileStreamPath(FILE_NAME.toString()), ParcelFileDescriptor.MODE_WORLD_READABLE); return result; This used to work just fine before 2.1 upgrade. This also works fine in the emulator. What am I doing wrong? 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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: Service.startForeground() messes with scheduling?
*bump* It seems that the implementation of startForeground() delegates to this code: public void setServiceForeground(ComponentName className, IBinder token, 1781 #127f1bc903f2e1c4_l1781int id, Notification notification, boolean removeNotification) throws RemoteException { 1782 #127f1bc903f2e1c4_l1782 Parcel data = Parcel.obtain(); 1783 #127f1bc903f2e1c4_l1783 Parcel reply = Parcel.obtain(); 1784 #127f1bc903f2e1c4_l1784 data.writeInterfaceToken(IActivityManager.descriptor); 1785 #127f1bc903f2e1c4_l1785 ComponentName.writeToParcel(className, data); 1786 #127f1bc903f2e1c4_l1786 data.writeStrongBinder(token); 1787 #127f1bc903f2e1c4_l1787 data.writeInt(id); 1788 #127f1bc903f2e1c4_l1788 if (notification != null) { 1789 #127f1bc903f2e1c4_l1789 data.writeInt(1); 1790 #127f1bc903f2e1c4_l1790notification.writeToParcel(data, 0); 1791 #127f1bc903f2e1c4_l1791 } else { 1792 #127f1bc903f2e1c4_l1792 data.writeInt(0); 1793 #127f1bc903f2e1c4_l1793 } 1794 #127f1bc903f2e1c4_l1794data.writeInt(removeNotification ? 1 : 0); 1795 #127f1bc903f2e1c4_l1795 mRemote.transact(SET_SERVICE_FOREGROUND_TRANSACTION, data, reply, 0); 1796 #127f1bc903f2e1c4_l1796 reply.readException(); 1797 #127f1bc903f2e1c4_l1797 data.recycle(); 1798 #127f1bc903f2e1c4_l1798 reply.recycle(); 1799 #127f1bc903f2e1c4_l1799 } Which isn't all that more helpful ;-( I don't see that it messes with priorities either. But then I also don't see the actual implementation of making this foreground/background service more unkillable. It seems just to be the IPC code. Any ideas? On Thu, Apr 8, 2010 at 6:40 PM, Mariano Kamp mariano.k...@gmail.com wrote: Hi. I updated my app to use the new startForeground() method of Service. Now beta testers are complaining about the foreground app going slow. Is that a coincidence or does startForeground() mess with the thread's prio or does anything else but what is written below? Just as an additional information the background activity does some syncing, reports the progress to the notification using remote views and as it is not latency dependent I use (and did that before already) this: Process.setThreadPriority(Process.THREAD_PRIORITY_LOWEST); Should I use another Priority? And if it makes any difference, how does that play with Android 1.5 devices? Cheers, Mariano http://developer.android.com/reference/android/app/Service.html#startForeground(int, android.app.Notification)http://developer.android.com/reference/android/app/Service.html#startForeground(int,+android.app.Notification) Make this service run in the foreground, supplying the ongoing notification to be shown to the user while in this state. By default services are background, meaning that if the system needs to kill them to reclaim more memory (such as to display a large page in a web browser), they can be killed without too much harm. You can set this flag if killing your service would be disruptive to the user, such as if your service is performing background music playback, so the user would notice if their music stopped playing. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Draw Text on GLSurfaceView
In OpenGL, you need to write a text renderer. There are several examples and implementations floating around on the web. For example, I wrote a class that, given a font and a font size, generates an atlas texture and stores all of the individual character locations and metrics for me. I then use that class to draw dynamic text everywhere in my scene. It took me a few hours to write and works great. The interface looks like: public TextRenderer(Context context, GL10 gl, GraphicsConfiguration graphicsConfig, Typeface tf, float fontSize, int stroke, int horizSpacing) {} public void drawTextLine(GL10 gl, int x, int y, char[] text, int length) {} I recommend doing something like that. There are other ways, of course. You can load in the geometry from a true-type font and render that, though I don't know how easy it will be in ES to handle the curves and lack of polygon mode. On Apr 12, 9:49 am, A.TNG tang.j...@gmail.com wrote: On Mon, Apr 12, 2010 at 10:39 PM, Renjith renjithkum...@gmail.com wrote: Hi, Can anyone help me to understand how to draw text on GLSurfaceView in Android ? Thanks in advance Ren You cannot draw text on glsurface. What you can do is draw text on a bitmap, then bind this bitmap as texture to glsurface, user drawElement to show this bitmap. You could check ApiDemo to learn how to draw bitmap on glsurface. Good luck. -- Best Regards, TANG Jiyu Blog:http://jiyu.wordpress.com.cn/ ezkeypad:http://ezkeypad.tool100.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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: How to properly implement ParcelFileDescriptor.openFile() method.
Here is the full error: 04-12 10:36:04.626: ERROR/UriTexture(18929): Unable to load image from URI content://com.gnugu.secretboxplus.imageprovider/test.jpg 04-12 10:36:04.636: WARN/System.err(18929): java.io.FileNotFoundException 04-12 10:36:04.636: WARN/System.err(18929): at android.database.DatabaseUtils.readExceptionWithFileNotFoundExceptionFromParcel(DatabaseUtils.java: 123) 04-12 10:36:04.636: WARN/System.err(18929): at android.content.ContentProviderProxy.openAssetFile(ContentProviderNative.java: 575) 04-12 10:36:04.636: WARN/System.err(18929): at android.content.ContentResolver.openAssetFileDescriptor(ContentResolver.java: 510) 04-12 10:36:04.636: WARN/System.err(18929): at android.content.ContentResolver.openInputStream(ContentResolver.java: 345) 04-12 10:36:04.636: WARN/System.err(18929): at com.cooliris.media.UriTexture.createFromUri(UriTexture.java:106) 04-12 10:36:04.646: WARN/System.err(18929): at com.cooliris.media.UriTexture.load(UriTexture.java:192) 04-12 10:36:04.646: WARN/System.err(18929): at com.cooliris.media.RenderView.loadTextureAsync(RenderView.java:213) 04-12 10:36:04.646: WARN/System.err(18929): at com.cooliris.media.RenderView.access$600(RenderView.java:31) 04-12 10:36:04.646: WARN/System.err(18929): at com.cooliris.media.RenderView$TextureLoadThread.load(RenderView.java: 1002) 04-12 10:36:04.646: WARN/System.err(18929): at com.cooliris.media.RenderView$TextureLoadThread.run(RenderView.java: 986) On Apr 12, 9:39 am, gnugu rho...@gmail.com wrote: Hi, I have a ContentProvider that serves an image to default built in image viewer. Ever since Android 2.1 the built in image viewer throws FileNotFound into the log. I also find this in the log: 04-12 09:28:54.066: ERROR/UriTexture(11541): Unable to load image from URI content://com.gnugu.secretboxplus.imageprovider/test.jpg The file indeed does exist, I write it on sdcard. Here is a piece of code in openFile() method: File FILE_NAME = new File(DataAdapter.DATABASE_FILE_PATH, test.jpg); FILE_NAME.createNewFile(); FileOutputStream fileStream = new FileOutputStream(FILE_NAME); fileStream.write(pictureData); fileStream.flush(); fileStream.close(); // now open the file descriptor ParcelFileDescriptor result = ParcelFileDescriptor.open(ctx.getFileStreamPath(FILE_NAME.toString()), ParcelFileDescriptor.MODE_WORLD_READABLE); return result; This used to work just fine before 2.1 upgrade. This also works fine in the emulator. What am I doing wrong? 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 To unsubscribe, reply using remove me as the subject.
[android-developers] Re: unable to open database file after OS upgrade
On Apr 9, 2:36 pm, Mariano Kamp mariano.k...@gmail.com wrote: *bump* On Fri, Apr 2, 2010 at 12:53 PM, Mariano Kamp mariano.k...@gmail.comwrote: Hi, recently I very often get error reports from users that upgrade their OS. This includes at least 1.5, 1.6, 2.1 and custom ROMs. Anybody else seeing these? Any idea what to do about it? Cheers, Mariano i had similar problem too, i solved it by adding flag SQLiteDatabase.NO_LOCALIZED_COLLATORS when calling SQLiteDatabase.openDatabase hth pskink -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
[android-developers] You Need An Extra Income? - Make Money Online[FINANCE4U.YOLASITE]
*You Need An Extra Income? - Make Money Online[FINANCE4U.YOLASITE]* Thousands of people want to make money online because the web is inundated with information that gives easy ways to do just that. When people start to make money online, they find out that it’s pretty hard, after all. Like in all aspects of earning money, one has to work hard to start earning. There are few things that guarantee to make you succeed in internet marketing. A few people succeed to make money online because they don’t know the real system that works. They usually grab the first opportunity without looking at the other possibilities. Try to read and absorb until you find what kind of method works for you. You can start joining well-known sites, auction sites, and sell products. Online shopping is really a big hit on the web and you don’t even need a huge capital to get started. Customers come from different countries, which means you can make money everywhere and you can be an international seller. *VISIT FOR MORE* * http://finance4u.yolasite.com/online-make-money/you-need-an-extra-income-make-money-online *http://finance4u.yolasite.com/online-make-money/you-need-an-extra-income-make-money-online In order for you to succeed in online business, you have to know the dos and don’ts of the business, you have to have some knowledge when using the market place and try to use the techniques you have learned. If you want to make money fast, set your prices lower than the others to attract customers and you can get ahead of your competitors. Furthermore, being an online seller, you need to sell popular products because the demand is high. A better approach to make money online is to set up your own website once you already have plenty of contacts on your list. Doing so can be easier for you to market your products because you have a personalized page. Be creative with your site, give offers and get in touch with your old customers to buy your products. There are lots of strategies to make money on the web. However, the most important factor is to have a big list of customers. You control your own business, you have to find prospects to be added on your list. Email marketing can also help. Knowing a lot about using your computer and the internet can let you make money in no time. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en To unsubscribe, reply using remove me as the subject.
Re: [android-developers] Re: Service.startForeground() messes with scheduling?
Mariano Kamp wrote: Is that a coincidence or does startForeground() mess with the thread's prio or does anything else but what is written below? Quoting myself: ...but a persistent concern for game developers on Android is the impacts that external forces have on their frame rates. For example, a year ago, the big concern was garbage collection going on in other processes -- garbage collection takes CPU time, even if that work is being done in a totally separate Linux process from the game itself. To counteract this, the core Android team made some improvements in Android 1.6, relegating all background processing to a class that is capped in terms of CPU utilization, leveraging some Linux process and thread control frameworks. Garbage collection in those background processes will no longer hog the CPU. Hence, games can run with minimal interference...so long as background processing stays in the background. (from http://www.androidguys.com/2010/03/16/code-pollution-background-foreground/) I suspect that startForeground() means the service will run with foreground priority, rather than residing in the background process class. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Training in NYC: 30 April-2 May 2010: http://guruloft.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 To unsubscribe, reply using remove me as the subject.