[android-developers]
Hi See this code even this also getting like force close wait Intent myintent=new Intent(Intent.ACTION_VIEW,Uri.parse(www.google.com)); startActivity(myintent); -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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]
Check logcat wots d error On 6 Aug 2011 11:32, jagadeesh mjagadeeshb...@gmail.com wrote: Hi See this code even this also getting like force close wait Intent myintent=new Intent(Intent.ACTION_VIEW,Uri.parse(www.google.com )); startActivity(myintent); -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] http connection to display a webpage
Hi i want to get data from the server ...i done using http connection but the webpage is not displaying am new to android and java...so plz any one can provide me guidance. // TODO Auto-generated method stub super.onCreate(savedInstanceState); setTitle(Fund Projects); try { URL url = new URL(directoryLocation); HttpURLConnection httpURLConnection = (HttpURLConnection) url .openConnection(); // The line below is where the exception is called int response = httpURLConnection.getResponseCode(); if (response == HttpURLConnection.HTTP_OK) { // Response successful InputStream inputStream = httpURLConnection.getInputStream(); // Parse it line by line BufferedReader bufferedReader = new BufferedReader( new InputStreamReader(inputStream)); String temp; while ((temp = bufferedReader.readLine()) != null) { // Parsing of data here } } else { Log.e(SAMES, INCORRECT RETURN CODE: + response); } } catch (MalformedURLException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } } Thankyou arun -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Android source line numbers in stack trace
On Friday, August 5, 2011 4:40:19 PM UTC-4, Tor Norbye wrote: On Fri, Aug 5, 2011 at 1:12 PM, Chris Stratton cs0...@gmail.com wrote: Who are you and how is this relevant to Caleb9's question? Caleb9 mentioned the adt-addons source plugin in his original post and Peco is the author of that plugin. Oops, sorry about that. At a too-quick glance the first person writing made me think it was either the original poster using a different account or someone tossing in an unrelated statement-as-question. I was frankly operating under the assumption that tracking down the precise source would be futile and thinking it more pragmatic to look at the application code instead - but I'll try to keep the possibility of original authors dropping by in mind next time! Chris -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] dispalying a webpage
Hi i want to display a webpage in the using http connection..am new to android and java so any one can give me guiadance how i can make this... // TODO Auto-generated method stub super.onCreate(savedInstanceState); setTitle(Fund Projects); try { URL url = new URL(directoryLocation); HttpURLConnection httpURLConnection = (HttpURLConnection) url .openConnection(); // The line below is where the exception is called int response = httpURLConnection.getResponseCode(); if (response == HttpURLConnection.HTTP_OK) { // Response successful InputStream inputStream = httpURLConnection.getInputStream(); // Parse it line by line BufferedReader bufferedReader = new BufferedReader( new InputStreamReader(inputStream)); String temp; while ((temp = bufferedReader.readLine()) != null) { // Parsing of data here } } else { Log.e(SAMES, INCORRECT RETURN CODE: + response); } } catch (MalformedURLException e) { // TODO Auto-generated catch block e.printStackTrace(); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Game engine example with library required
I have a free game engine library with complete example. The game engine is rokon. But unfortunately it is not displaying background image. I spent a complete day but in vain. If you people has correct version of rokon then please share. or share another game engine library with example -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Still confused about Google Checkout
There's a setting in AppMonger to Include Uncharged Orders, IIRC it's off by default. If you don't turn that on, you won't see orders until they're charged. There's also and Order List view; it's at the bottom of the list of charts (the dropdown with Revenue by Hour, Orders by Day, etc). It'll show you all the orders that AppMonger has imported. Having said all that, I think Appmonger has a problem this morning. As I write this, my copy is lagging 5 hours behind in order imports, which I've never seen happen before. Perhaps Google changed something about their data feed recently? At any rate, the Appmonger dev is pretty responsive, so I'm sure that whatever the problem is, he'll be on it. He is here in the UK, though, so he might well not be up yet (currently 7:40AM locally). I'm not usually up and online this early on a Saturday, either. :^) 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
[android-developers] Is there a callback that gets called right after onResume() ?
Is there a callback that gets a call when everything in the current Activity got rendered? Because I need to know the exact sizes of some of my ViewGroups (their width/height are set using layout_weight in the layout xml), so I know how many elements fit inside them without scrolling. But I can only measure them after onResume. Is there a way to do this without some hack? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: inApp soundgeneration possible without heavy use of CPU ?
Hello Paul, no, i have tried to keep within java. Since this is my first game: Do the big ones also use c(++) in the way you have described? Does it seamless integrate in Eclipse, or is it very complicated to do so? Kind regards, Peter On 2 Aug., 04:00, Paul Turchenko paul.turche...@gmail.com wrote: First guess: have you tried moving heavy stuff to C/C++ and linking via JNI? On Jul 31, 3:35 pm, Peter Pippinger pe...@pippinger.de wrote: Hello, I have now completed my first app (https://market.android.com/details?id=com.pippinger.android.frogthisw...). For the music I was working withhttp://www.warmplace.ru/soft/sunvox/which is a very powerful synthesizer in my opinion. I think the chiptunes-style fits best for android-apps. On the other side it takes much memory for having long music in the app if you are insert it by .ogg or something like that. So my question: is it possible to do some synthesizer-calculation in Java for the music with not to much CPU-consumption? Maybe you have some links (maybe also to some apps which are doing something like this)? Thanks a lot and kind regards, Peter -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Game engine example with library required
Try AndEngine. The examples are on the market as well as google code. On Sat, Aug 6, 2011 at 12:06 PM, Deeraf dee.dee...@gmail.com wrote: I have a free game engine library with complete example. The game engine is rokon. But unfortunately it is not displaying background image. I spent a complete day but in vain. If you people has correct version of rokon then please share. or share another game engine library with example -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Raghav Sood http://www.raghavsood.com/ http://wiki.androidappcheck.com/ http://www.telstop.tel/ https://market.android.com/developer?pub=Appaholics http://www.appaholics.in/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Do you want your large Android project builds to complete faster?
If so, please consider starring and commenting on the following bug report to give it attention: http://code.google.com/p/android/issues/detail?id=16263 Doug -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Market is showing incompatible with phone, but developer console says it is compatible
Are you sure that whatever the user rooted their phone with is compatible with whatever you are doing? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] how to use google ajax api
Hi, I am playing with web view but i can't get this to work with html files: http://code.google.com/apis/ajax/playground/?type=visualization#line_chart any idea how to use this charts with android. thanks a lot. cheers. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Uploading apps on Android Market
Google have already raised the limit to 4GB per apk some time ago... Is it not implemented yet? http://androidcommunity.com/android-market-upgrading-app-size-limit-to-4gb-20110511/ On Aug 6, 12:28 am, Thế Hiển Đoàn doanthehien1...@gmail.com wrote: Hello, I write my apps which are kind of 3D animations. My apps would run on Tablet devices, and their size exceed 50MB. How can I upload them when Google Market only allows the app size limit of 50MB? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: 3rdParty application icon
On Sat, Aug 6, 2011 at 1:46 AM, John android...@gmail.com wrote: In the case of the Gallery application i.e. com.google.android.gallery3d, which throws the Application is not installed error in the shortcut, it shows up both in getInstalledPackages and also in queryIntentActivities with the given Intent, also it only has one entry in the queryIntentActivities which confuses me even more. If it had more than one entry, that would make sense to me, I would need to specify which className to invoke. com.google.android.gallery3d doesn't exist in the Android open source project (at least Google Code Search doesn't turn it up), and the Gallery3D project doesn't use that package. Have you tried creating a shortcut based on the actual ResolveInfo object? Here's the code snippet for creating such an Intent: Intent buildLauncherIntent(ResolveInfo launchable) { ActivityInfo activity=launchable.activityInfo; ComponentName name=new ComponentName(activity.applicationInfo.packageName, activity.name); Intent i=new Intent(Intent.ACTION_MAIN); i.addCategory(Intent.CATEGORY_LAUNCHER); i.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED); i.setComponent(name); return(i); } -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.5 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
Re: [android-developers] need help on float picker
That widget does not have a constructor suitable for instantiating it from onCreate() of an activity. You will probably need to modify the code or simply inflate it via a layout XML resource. On Sat, Aug 6, 2011 at 1:04 AM, Dev_red sktniranjanad...@gmail.com wrote: Hi i am using float picker from this http://www.laurencegellert.com/software/android-float-picker-widget/ but now i want to create this picker dynamically.. i dont know how to create dynamically? any idea? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.5 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
Re: [android-developers] Still can't log in to update app...
On Fri, Aug 5, 2011 at 4:23 PM, Tobiah t...@tobiah.org wrote: Thanks, that's what I'm going to have to do. I can send this guy a link, but then the best way I can imagine to have him install it is to have the browser save it, then have him install and use Astro file manager to get to it. The stock browser on our phones doesn't seem to handle the .apk specially. Sure it does. You have to configure the Web server to serve the APK with the proper MIME type, no different than you do for any other piece of media you serve from the Web server. Or, use Dropbox, Amazon S3, or other hosts that have APK support pre-configured. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.5 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
[android-developers] Re: Upload Audio File over Server
dear Raghav Sood : i've tried the link. but why is the result is always false? i have no idea about it. thanks before... On Jul 21, 6:29 pm, Raghav Sood raghavs...@gmail.com wrote: Maybe you should visithttp://www.google.comand type your query once in a while: http://hoang17.com/posts/android/android-how-to-upload-a-file-via-ftp On Thu, Jul 21, 2011 at 4:40 PM, Ankit Kasliwal kasliwalankit2...@gmail.com wrote: Hello Everyone is any way to upload Audio file which i record through Application uploaded over My FTP server Folder. -- Thanks and Regards, Ankit Kasliwal kasliwalankit2...@gmail.com +91-9300-940-136 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Raghav Soodhttp://www.raghavsood.com/http://wiki.androidappcheck.com/http://www.telstop.tel/https://market.android.com/developer?pub=Raghav+Sood -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Market is showing incompatible with phone, but developer console says it is compatible
Does the market actually check with individual devices or just the model? He is having the same problem with some other apps, and I asked him if he rooted the phone and he said no, wasn't even sure what that is. On Saturday, August 6, 2011 6:35:13 AM UTC-4, rich friedel wrote: Are you sure that whatever the user rooted their phone with is compatible with whatever you are doing? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Still confused about Google Checkout
On Fri, Aug 05, 2011 at 11:39:43PM -0700, String wrote: There's a setting in AppMonger to Include Uncharged Orders, IIRC it's off by default. If you don't turn that on, you won't see orders until they're charged. That was checked (and still is). I heard my very unique (not associated with ANY other app, and created just for AppMonger) notification sound go off at 0500 (+/-) this morning, and when it still didn't display any data, I contacted the author, who was very helpful. Turns out that the default display has some limits---it won't display until there are a certain number (how many?) data points. He pointed me to the Show All Orders and the setting to show all times (i.e., don't limit based on the date---show everything). He also pointed out (as did the FAQ, which I read prior to sending the e-mail) that, while rare, sometimes there are delays. This one just happened to be more than the norm for this rare delay. There's also and Order List view; it's at the bottom of the list of charts (the dropdown with Revenue by Hour, Orders by Day, etc). It'll show you all the orders that AppMonger has imported. Yep, that's the one the author pointed me to. :-) Having said all that, I think Appmonger has a problem this morning. As I write this, my copy is lagging 5 hours behind in order imports, which I've never seen happen before. Perhaps Google changed something about their data feed recently? My first order came in at 2100L, and it didn't sound off via AppMonger until 0500L. That's a full 8 hour delay. So yeah, something was wrong. But from what I've gathered, it's on the Google side (not getting the CSV files produced promptly, or something like that). At any rate, the Appmonger dev is pretty responsive, so I'm sure that whatever the problem is, he'll be on it. He got back to me within a few minutes. I'd say that's about as responsive as any sane person could ever hope for. :-) Thanks, --jim -- 73 DE N5IAL (/4) ||\ _,,,---,,_ Running FreeBSD 7.0| ZZZzz /,`.-'`'-. ;-;;,_ spooky1...@gmail.com | |,4- ) )-,_. ,\ ( `'-' ICBM/Hurr.: 30.44406N 86.59909W | '---''(_/--' `-'\_) | | Kitty! --Crow T. Robot (MST3k) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Market is showing incompatible with phone, but developer console says it is compatible
I brought up the root idea because you stated they sent you a screenshot... I assumed you were talking about a screenshot of the device's screen. Anyway, they did some major stuff to the market recently and things have been abnormally out of whack for the last week or so. Maybe, this is the cause of the discrepency. You should probably consider contacting the market folks and see what they have to say. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Upload Audio File over Server
@Randy I would suggest asking the article author... or reading the comment where a bunch of people have already faced this issue with the article's code -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Still can't log in to update app...
You do realize that email can have attachments right? Why send them a link to download and install something you could send directly? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Uploading apps on Android Market
I would hate to have to pay for a tiered data plan and have to update a 4GB app more than once/month! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Still can't log in to update app...
On Sat, Aug 6, 2011 at 9:17 AM, rich friedel rich.frie...@gmail.com wrote: You do realize that email can have attachments right? Why send them a link to download and install something you could send directly? Unless the email client puts the proper MIME type in, the Android email app probably won't know what to do with it. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://github.com/commonsguy http://commonsware.com/blog | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.5 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
[android-developers] Re: I need a CamScanner like example
You have a lot of needs but what you really need is to do a damn search on google and find the information yourself and then come on back and ask specific questions ;) hint: seach this... android open source ocr -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Still can't log in to update app...
True, which is why they make tAttachApkInstaller ;) All this aside though, none of this drives to the heart of the problem... the OP cannot login to their account... I should also have asked what they have done to deal with that issue as well. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Connecting to a Zebra MZ 320 over bluetooth - without PIN
Hi, I'm trying to connect an Android with such printer. The printer has this information retrieved by BluetoothClass: Class: 1664/1536: Render What (BluetoothClass.Service.)Render means? Is there a specific UUID for it? I tried to connect to the device using the well known SPP UUID, however, Android keeps asking me for a PIN. The printer, with BT 2.0, has authentication mode turned off. I read in some places that Android requires a PIN to pair with a device. I tried and 1234 as suggested by the pairing dialog but the connection fails. Isn't really a way to pair without setting a PIN? Otherwise, i'll have to connect all 300 printers to a pc just to set a PIN so Android can connect to it. thanks in advance, guich www.totalcross.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
Re: [android-developers] Do you want your large Android project builds to complete faster?
you can enlarge eclipse heap 2011/8/6 Doug beafd...@gmail.com: If so, please consider starring and commenting on the following bug report to give it attention: http://code.google.com/p/android/issues/detail?id=16263 Doug -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Do you want your large Android project builds to complete faster?
Not quite the same thing as skipping PNG optimizations, or using multiple cores... 06.08.2011 19:10, a a пишет: you can enlarge eclipse heap 2011/8/6 Dougbeafd...@gmail.com: If so, please consider starring and commenting on the following bug report to give it attention: http://code.google.com/p/android/issues/detail?id=16263 Doug -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] I can't show random images in the ImageView
Nice day! I tried to show random images in my application in an ImageView. I tried this code: public class r extends Activity{ ImageView secret; @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.r); TextView txt = (TextView) findViewById(R.id.txt); secret = (ImageView) findViewById(R.id.secret); Runnable r1 = new Runnable() { @Override public void run() { // TODO Auto-generated method stub int imageArr[] = new int[3]; imageArr[0] = R.drawable.r1_mirror; imageArr[1] = R.drawable.s1_mirror; imageArr[2] = R.drawable.p2_mirror; int n = (int) Math.random()*3; secret.setImageResource(imageArr[n]); } }; secret.postDelayed(r1, 5000); } } But it only show the r1_mirror image, everytime, when I start my application in the emulator. What I made bad? I thought that it will working, but. Thanks for any helps -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Android source line numbers in stack trace
On Fri, Aug 5, 2011 at 11:09 PM, Chris Stratton cs07...@gmail.com wrote: I was frankly operating under the assumption that tracking down the precise source would be futile and thinking it more pragmatic to look at the application code instead You're right, that's a good assumption; it's usually the case that some API was called with invalid arguments or in an illegal state and investigating the last stack frame from your own application is the first place to look. This isn't specific to Android development obviously - almost anytime you're using a framework or library it's almost always going to be something in your own code. On the other hand, bugs exist and sometimes peeking at the library source code can help you realize the problem more quickly, especially if it's an illegal state issue rather than just an illegal argument issue. --Tor -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Is there a callback that gets called right after onResume() ?
There is no callback - you can set flags in onResume() to know when the activity is done with that part of the lifecycle. However, by using layout_weight, you're telling Android to decide the size, which it can't know until the screen is drawn, so a callback to change the size won't work without a Handler to request a redraw or cycling through onPause/onResume. So, you're going to need a Handler, which is effectively a hack (to avoid layout_weight, you can get screen and view dimensions and other data during onCreate/onStart/onResume to calculate the available screen space yourself, determine which elements will show and then calculate/recalculate certain element sizes to get what you want, but that's a lot of work - a hack is probably a better approach for this type of job). If you want to determine the available size, then start a background thread/timer at the end of onResume(), when you know how much space you have for your elements, do the size calculations, then runOnUIThread the changes and you should be fine. If you want to guarantee the user does not see the changes, you're going to have to work harder since the background thread/timer is not synchronized with the UI. -Jim On Aug 6, 2:58 am, Zsombor scythe...@gmail.com wrote: Is there a callback that gets a call when everything in the current Activity got rendered? Because I need to know the exact sizes of some of my ViewGroups (their width/height are set using layout_weight in the layout xml), so I know how many elements fit inside them without scrolling. But I can only measure them after onResume. Is there a way to do this without some hack? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Connecting to a Zebra MZ 320 over bluetooth - without PIN
I was able to print by changing the printer to have a PIN. However, doing this in 300 devices will be a headache. :-( guich -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] process large images
Hi, i want to process an image that the phone has not enough memory to load all in memory. BitmapFactory.decode() fails and an out of memory exception is raised. Is it possible to load only some part of an image? If i can how can i make an image output stream so i can write the processed parts into a new file and when the job is finished then i will get a new image with the same size as the initial one. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: onDraw() causing flicker when drawing new images
Perhaps you can try adding a synchronized lock that protects your data array. Lock it before going into onDraw() and unlock it when finished, and do the same when calculating your array data. Do you have a separate thread that calculates positions? On Fri, Aug 5, 2011 at 6:23 PM, niko20 nikolatesl...@yahoo.com wrote: Hm sounds like a refresh rate issue, with Surface view you probably can't sync to vertical refresh, so you get tearing, where you see halfway animations for a second as the video buffer changes over to the next frame. -niko On Aug 5, 1:56 pm, Jeffrey jeffisagen...@gmail.com wrote: I'm having an issue with drawing on my surface view. At one point I was just replacing images with new ones in a grid, but the images didn't all draw at the same time. I think that that may have had something to do with modifying the array that it was using to determine what to draw but I couldn't get it resolved even when pausing the drawing. Now I have images that drop down and new ones fall in (think slot machine reels) but the images will occasionally flicker with what the new image is going to be before the old images fall out. Basically I guess I'm asking what is a good way to either pause the onDraw command while I can edit my arrays and get them all in place or what is a good way to sync my array modifications to not take place during an onDraw cycle? Or is onDraw just bad at drawing images simultaneously and I should be using OpenGL or something? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- ~ Jeremiah:9:23-24 Android 2D MMORPG: http://solrpg.com/, http://www.youtube.com/user/revoltingx -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] I can't show random images in the ImageView
Add some logging so that you can see what n is. Then find out why it's not generating a random number. On Sat, Aug 6, 2011 at 8:33 AM, Zwiebel hunzwie...@gmail.com wrote: Nice day! I tried to show random images in my application in an ImageView. I tried this code: public class r extends Activity{ ImageView secret; @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.r); TextView txt = (TextView) findViewById(R.id.txt); secret = (ImageView) findViewById(R.id.secret); Runnable r1 = new Runnable() { @Override public void run() { // TODO Auto-generated method stub int imageArr[] = new int[3]; imageArr[0] = R.drawable.r1_mirror; imageArr[1] = R.drawable.s1_mirror; imageArr[2] = R.drawable.p2_mirror; int n = (int) Math.random()*3; secret.setImageResource(imageArr[n]); } }; secret.postDelayed(r1, 5000); } } But it only show the r1_mirror image, everytime, when I start my application in the emulator. What I made bad? I thought that it will working, but. Thanks for any helps -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- ~ Jeremiah:9:23-24 Android 2D MMORPG: http://solrpg.com/, http://www.youtube.com/user/revoltingx -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: I need a CamScanner like example
Why I will search for OCR? I don´t want a OCR, it´s a image processing to align the image. On 6 ago, 10:38, rich friedel rich.frie...@gmail.com wrote: You have a lot of needs but what you really need is to do a damn search on google and find the information yourself and then come on back and ask specific questions ;) hint: seach this... android open source ocr -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: I can't show random images in the ImageView
I tried it out and sadly n is 0 everytime, but I don't know why. On aug. 6, 17:23, Miguel Morales therevolti...@gmail.com wrote: Add some logging so that you can see what n is. Then find out why it's not generating a random number. On Sat, Aug 6, 2011 at 8:33 AM, Zwiebel hunzwie...@gmail.com wrote: Nice day! I tried to show random images in my application in an ImageView. I tried this code: public class r extends Activity{ ImageView secret; @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.r); TextView txt = (TextView) findViewById(R.id.txt); secret = (ImageView) findViewById(R.id.secret); Runnable r1 = new Runnable() { @Override public void run() { // TODO Auto-generated method stub int imageArr[] = new int[3]; imageArr[0] = R.drawable.r1_mirror; imageArr[1] = R.drawable.s1_mirror; imageArr[2] = R.drawable.p2_mirror; int n = (int) Math.random()*3; secret.setImageResource(imageArr[n]); } }; secret.postDelayed(r1, 5000); } } But it only show the r1_mirror image, everytime, when I start my application in the emulator. What I made bad? I thought that it will working, but. Thanks for any helps -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- ~ Jeremiah:9:23-24 Android 2D MMORPG:http://solrpg.com/, http://www.youtube.com/user/revoltingx -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: I can't show random images in the ImageView
On Sun, Aug 7, 2011 at 2:38 AM, Zwiebel hunzwie...@gmail.com wrote: I tried it out and sadly n is 0 everytime, but I don't know why. Reading the docs usually helps: public static double random() Returns a double value with a positive sign, greater than or equal to 0.0 and less than 1.0. You are casting to int, so it's always going to be zero. What you need is java.util.Random.nextInt(). -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Is there a callback that gets called right after onResume() ?
Or one could use the tools already provided by the framework ... ... by subclassing a xxxLayout class or a ViewGroup and overriding onMeasure and onLayout ... ... or by subclassing the appropriate view and overriding onSizeChanged ... -- Kostya 06.08.2011 20:42, Jim пишет: There is no callback - you can set flags in onResume() to know when the activity is done with that part of the lifecycle. However, by using layout_weight, you're telling Android to decide the size, which it can't know until the screen is drawn, so a callback to change the size won't work without a Handler to request a redraw or cycling through onPause/onResume. So, you're going to need a Handler, which is effectively a hack (to avoid layout_weight, you can get screen and view dimensions and other data during onCreate/onStart/onResume to calculate the available screen space yourself, determine which elements will show and then calculate/recalculate certain element sizes to get what you want, but that's a lot of work - a hack is probably a better approach for this type of job). If you want to determine the available size, then start a background thread/timer at the end of onResume(), when you know how much space you have for your elements, do the size calculations, then runOnUIThread the changes and you should be fine. If you want to guarantee the user does not see the changes, you're going to have to work harder since the background thread/timer is not synchronized with the UI. -Jim On Aug 6, 2:58 am, Zsomborscythe...@gmail.com wrote: Is there a callback that gets a call when everything in the current Activity got rendered? Because I need to know the exact sizes of some of my ViewGroups (their width/height are set using layout_weight in the layout xml), so I know how many elements fit inside them without scrolling. But I can only measure them after onResume. Is there a way to do this without some hack? -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Is there a callback that gets called right after onResume() ?
Sure. I'd start here: http://developer.android.com/guide/topics/ui/custom-components.html The layout process involves these three onXXX overrides, as listed in the table halfway down the page: ||onMeasure(int, int) ||onLayout(boolean, int, int, int, int) onSizeChanged(int, int, int, int) There is documentation for each of these three methods, as well, such as: http://developer.android.com/reference/android/view/View.html#onSizeChanged(int, int, int, int) -- Kostya 06.08.2011 22:54, Matt Tatro пишет: Kostya, Any example I could follow? Kind Regards, Matt Tatro T: +1 (281) 905-1008 E: mattta...@gmail.com -Original Message- From: android-developers@googlegroups.com [mailto:android-developers@googlegroups.com] On Behalf Of Kostya Vasilyev Sent: Saturday, August 06, 2011 11:51 AM To: android-developers@googlegroups.com Subject: Re: [android-developers] Re: Is there a callback that gets called right after onResume() ? Or one could use the tools already provided by the framework ... ... by subclassing a xxxLayout class or a ViewGroup and overriding onMeasure and onLayout ... ... or by subclassing the appropriate view and overriding onSizeChanged ... -- Kostya 06.08.2011 20:42, Jim пишет: There is no callback - you can set flags in onResume() to know when the activity is done with that part of the lifecycle. However, by using layout_weight, you're telling Android to decide the size, which it can't know until the screen is drawn, so a callback to change the size won't work without a Handler to request a redraw or cycling through onPause/onResume. So, you're going to need a Handler, which is effectively a hack (to avoid layout_weight, you can get screen and view dimensions and other data during onCreate/onStart/onResume to calculate the available screen space yourself, determine which elements will show and then calculate/recalculate certain element sizes to get what you want, but that's a lot of work - a hack is probably a better approach for this type of job). If you want to determine the available size, then start a background thread/timer at the end of onResume(), when you know how much space you have for your elements, do the size calculations, then runOnUIThread the changes and you should be fine. If you want to guarantee the user does not see the changes, you're going to have to work harder since the background thread/timer is not synchronized with the UI. -Jim On Aug 6, 2:58 am, Zsomborscythe...@gmail.com wrote: Is there a callback that gets a call when everything in the current Activity got rendered? Because I need to know the exact sizes of some of my ViewGroups (their width/height are set using layout_weight in the layout xml), so I know how many elements fit inside them without scrolling. But I can only measure them after onResume. Is there a way to do this without some hack? -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] At what point does android know the exact key that was pressed?
I built the android source and running it in the Eclipse debugger, am trying to understand where is the point in the calling sequence when it has all the information about the event. So I run the calculator and press key '1'. There is a breakpoint at EventListener.onClick() In the call stack I see the event being dispatched; ViewRoot calling PhoneWindow calling Panel, Layout, Button etc. until the handler is reached. questions: 1) At what earliest point in the call hierarchy can I insert a println saying, Key was pressed, value is 1? 2) At what point does it know whether it was a soft key or a physical key? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] At what point does android know the exact key that was pressed?
Hi, There are different listeners and you capture the keys by a KeyEvent class. On Sat, Aug 6, 2011 at 3:07 PM, Anil anil.r...@gmail.com wrote: I built the android source and running it in the Eclipse debugger, am trying to understand where is the point in the calling sequence when it has all the information about the event. So I run the calculator and press key '1'. There is a breakpoint at EventListener.onClick() In the call stack I see the event being dispatched; ViewRoot calling PhoneWindow calling Panel, Layout, Button etc. until the handler is reached. questions: 1) At what earliest point in the call hierarchy can I insert a println saying, Key was pressed, value is 1? 2) At what point does it know whether it was a soft key or a physical key? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- *Feign Narula* * * *Team Lead* *Phone : +16478634318* *Linkedln profile : http://ca.linkedin.com/pub/feign-narula/29/54/b82* *SCJP 5.0 Certified Programmer* *Curam V6 Certified Developer* *TOGAF V9 Certified Practitioner* -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: I can't show random images in the ImageView
Thanks, I could make it with your helps. But now I'm found a new problem. I try to modify my textview with .setText method, but I got this error: ERROR/AndroidRuntime(3745): android.content.res.Resources $NotFoundException: String resource ID #0x1 ERROR/AndroidRuntime(3745): at android.content.res.Resources.getText(Resources.java:222) ERROR/AndroidRuntime(3745): at android.widget.TextView.setText(TextView.java:3011) My source: public class sc extends Activity{ ImageView secret; public int counter; public int counter_foe; public TextView txt; public TextView counter_txt; @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.sc); counter = 0; counter_foe = 0; txt = (TextView) findViewById(R.id.txt); secret = (ImageView) findViewById(R.id.secret); counter_txt = (TextView) findViewById(R.id.counter_me); final TextView counter_txt_foe = (TextView) findViewById(R.id.counter_me_foe); Random rand = new Random(); int rndInt = rand.nextInt(3) + 1; Runnable r1 = new Runnable() { @Override public void run() { // TODO Auto-generated method stub int imageArr[] = new int[3]; imageArr[0] = R.drawable.r1_mirror; imageArr[1] = R.drawable.s1_mirror; imageArr[2] = R.drawable.p2_mirror; Random rand = new Random(); int rndInt = rand.nextInt(3); secret.setImageResource(imageArr[rndInt]); if (rndInt == 0) { counter_foe += 1; Log.d(improve, counter_foe improved); counter_txt_foe.setText(counter_foe); } } }; secret.postDelayed(r1, 5000); } } Thanks for any helps. On aug. 6, 19:46, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Sun, Aug 7, 2011 at 2:38 AM, Zwiebel hunzwie...@gmail.com wrote: I tried it out and sadly n is 0 everytime, but I don't know why. Reading the docs usually helps: public static double random() Returns a double value with a positive sign, greater than or equal to 0.0 and less than 1.0. You are casting to int, so it's always going to be zero. What you need is java.util.Random.nextInt(). -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: I can't show random images in the ImageView
You are calling TextView.setText(int) counter_txt_foe.setText(counter_foe); which expects an R.string resource ID for the text. Do this instead: counter_txt_foe.setText(String.valueOf(counter_foe)); to call TextView.setText(CharSequence) -- Kostya 07.08.2011 0:01, Zwiebel пишет: Thanks, I could make it with your helps. But now I'm found a new problem. I try to modify my textview with .setText method, but I got this error: ERROR/AndroidRuntime(3745): android.content.res.Resources $NotFoundException: String resource ID #0x1 ERROR/AndroidRuntime(3745): at android.content.res.Resources.getText(Resources.java:222) ERROR/AndroidRuntime(3745): at android.widget.TextView.setText(TextView.java:3011) My source: public class sc extends Activity{ ImageView secret; public int counter; public int counter_foe; public TextView txt; public TextView counter_txt; @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.sc); counter = 0; counter_foe = 0; txt = (TextView) findViewById(R.id.txt); secret = (ImageView) findViewById(R.id.secret); counter_txt = (TextView) findViewById(R.id.counter_me); final TextView counter_txt_foe = (TextView) findViewById(R.id.counter_me_foe); Random rand = new Random(); int rndInt = rand.nextInt(3) + 1; Runnable r1 = new Runnable() { @Override public void run() { // TODO Auto-generated method stub int imageArr[] = new int[3]; imageArr[0] = R.drawable.r1_mirror; imageArr[1] = R.drawable.s1_mirror; imageArr[2] = R.drawable.p2_mirror; Random rand = new Random(); int rndInt = rand.nextInt(3); secret.setImageResource(imageArr[rndInt]); if (rndInt == 0) { counter_foe += 1; Log.d(improve, counter_foe improved); counter_txt_foe.setText(counter_foe); } } }; secret.postDelayed(r1, 5000); } } Thanks for any helps. On aug. 6, 19:46, Nikolay Elenkovnikolay.elen...@gmail.com wrote: On Sun, Aug 7, 2011 at 2:38 AM, Zwiebelhunzwie...@gmail.com wrote: I tried it out and sadly n is 0 everytime, but I don't know why. Reading the docs usually helps: public static double random() Returns a double value with a positive sign, greater than or equal to 0.0 and less than 1.0. You are casting to int, so it's always going to be zero. What you need is java.util.Random.nextInt(). -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: I can't show random images in the ImageView
Oh, and here is another one: nextInt(3) can be one of: 0, 1, 2. nextInt(3) +1 then becomes one of: 1, 2, 3. This: imageArr[rndInt] expects values 0, 1, 2 So, take out the +1, to avoid getting an index-out-of-bounds exception. -- Kostya 07.08.2011 0:01, Zwiebel пишет: Random rand = new Random(); int rndInt = rand.nextInt(3) + 1; -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: At what point does android know the exact key that was pressed?
I think you misunderstood my question. I do understand about registering listeners for callbacks to my application. My question is about the android system - for all applications. On Aug 6, 2:44 pm, Feign Narula feign.nar...@gmail.com wrote: Hi, There are different listeners and you capture the keys by a KeyEvent class. On Sat, Aug 6, 2011 at 3:07 PM, Anil anil.r...@gmail.com wrote: I built the android source and running it in the Eclipse debugger, am trying to understand where is the point in the calling sequence when it has all the information about the event. So I run the calculator and press key '1'. There is a breakpoint at EventListener.onClick() In the call stack I see the event being dispatched; ViewRoot calling PhoneWindow calling Panel, Layout, Button etc. until the handler is reached. questions: 1) At what earliest point in the call hierarchy can I insert a println saying, Key was pressed, value is 1? 2) At what point does it know whether it was a soft key or a physical key? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- *Feign Narula* * * *Team Lead* *Phone : +16478634318* *Linkedln profile :http://ca.linkedin.com/pub/feign-narula/29/54/b82* *SCJP 5.0 Certified Programmer* *Curam V6 Certified Developer* *TOGAF V9 Certified Practitioner* -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: I can't show random images in the ImageView
Thanks I made it only forget to delete from here. On aug. 6, 20:23, Kostya Vasilyev kmans...@gmail.com wrote: Oh, and here is another one: nextInt(3) can be one of: 0, 1, 2. nextInt(3) +1 then becomes one of: 1, 2, 3. This: imageArr[rndInt] expects values 0, 1, 2 So, take out the +1, to avoid getting an index-out-of-bounds exception. -- Kostya 07.08.2011 0:01, Zwiebel пишет: Random rand = new Random(); int rndInt = rand.nextInt(3) + 1; -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: I can't show random images in the ImageView
Thanks I will try it! On aug. 6, 20:04, Kostya Vasilyev kmans...@gmail.com wrote: You are calling TextView.setText(int) counter_txt_foe.setText(counter_foe); which expects an R.string resource ID for the text. Do this instead: counter_txt_foe.setText(String.valueOf(counter_foe)); to call TextView.setText(CharSequence) -- Kostya 07.08.2011 0:01, Zwiebel пишет: Thanks, I could make it with your helps. But now I'm found a new problem. I try to modify my textview with .setText method, but I got this error: ERROR/AndroidRuntime(3745): android.content.res.Resources $NotFoundException: String resource ID #0x1 ERROR/AndroidRuntime(3745): at android.content.res.Resources.getText(Resources.java:222) ERROR/AndroidRuntime(3745): at android.widget.TextView.setText(TextView.java:3011) My source: public class sc extends Activity{ ImageView secret; public int counter; public int counter_foe; public TextView txt; public TextView counter_txt; @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.sc); counter = 0; counter_foe = 0; txt = (TextView) findViewById(R.id.txt); secret = (ImageView) findViewById(R.id.secret); counter_txt = (TextView) findViewById(R.id.counter_me); final TextView counter_txt_foe = (TextView) findViewById(R.id.counter_me_foe); Random rand = new Random(); int rndInt = rand.nextInt(3) + 1; Runnable r1 = new Runnable() { @Override public void run() { // TODO Auto-generated method stub int imageArr[] = new int[3]; imageArr[0] = R.drawable.r1_mirror; imageArr[1] = R.drawable.s1_mirror; imageArr[2] = R.drawable.p2_mirror; Random rand = new Random(); int rndInt = rand.nextInt(3); secret.setImageResource(imageArr[rndInt]); if (rndInt == 0) { counter_foe += 1; Log.d(improve, counter_foe improved); counter_txt_foe.setText(counter_foe); } } }; secret.postDelayed(r1, 5000); } } Thanks for any helps. On aug. 6, 19:46, Nikolay Elenkovnikolay.elen...@gmail.com wrote: On Sun, Aug 7, 2011 at 2:38 AM, Zwiebelhunzwie...@gmail.com wrote: I tried it out and sadly n is 0 everytime, but I don't know why. Reading the docs usually helps: public static double random() Returns a double value with a positive sign, greater than or equal to 0.0 and less than 1.0. You are casting to int, so it's always going to be zero. What you need is java.util.Random.nextInt(). -- Kostya Vasilyev -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: open nfc installation
Mohamed Ramadan writes: HI, I had two problems when I try to connect the simulator with the connection Center in open nfc 1-ccrouter.dll file not found in the connection center folder You can get connection center and its required DLLs by downloading the OpenNFC core edition. The NFCC simulator is also included in the package. Note that these two apps are Windows apps. So you should set up you test environment on a Windows host. If you are running on a Linux host (as the error message below implies), it won't work. 2-an error message Warning:No provider for client source:***.***.***.***(ip);LINUX;NFC controller (I2C);--rejected Error:Error while reading the socket:Socket greacefully shutdown' Warning: Client source:***...***(ip) ;linux;NFC Controller(I2C);NFC Controller(I2C);disconnected appear when I try to enter the ip and press and start the nfc service in the emulator did any one know how to get that file or what the message explanation is Did you start the NFCC simulator? Also there is currently a bug in the Android port for the NFC stack so you need to run a TCP echo server along side the connection center. I have posted a step by step procedure on how to set up the OpenNFC stack on StackOverflow. Here's the link. http://stackoverflow.com/questions/6770774/getting-started-with-open-nfc-emulator/6944968#6944968 I have managed to get the NFC stack installed and started. But beyond that I have encountered problems when I tried to read a virtual tag using the NFCC simulator. Other people have heard from the developers that this release is buggy and they are trying to resolve it in the next release. Winston Thanks, -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: onDraw() causing flicker when drawing new images
The problem isn't tearing, as the images shouldn't be drawn there yet anyway. I don't have my position calculations in a separate thread, should I? I have tried locking the array (though because of my limited knowledge I've gone about it probably the wrong way, by basically having a boolean that tells the draw cycle whether to read the data or not) but that didn't work, probably because of the poor quality of my attempt. I don't know too much about syncing threads and all that so I've been unable to figure this out on my own. On Aug 6, 12:19 pm, Miguel Morales therevolti...@gmail.com wrote: Perhaps you can try adding a synchronized lock that protects your data array. Lock it before going into onDraw() and unlock it when finished, and do the same when calculating your array data. Do you have a separate thread that calculates positions? On Fri, Aug 5, 2011 at 6:23 PM, niko20 nikolatesl...@yahoo.com wrote: Hm sounds like a refresh rate issue, with Surface view you probably can't sync to vertical refresh, so you get tearing, where you see halfway animations for a second as the video buffer changes over to the next frame. -niko On Aug 5, 1:56 pm, Jeffrey jeffisagen...@gmail.com wrote: I'm having an issue with drawing on my surface view. At one point I was just replacing images with new ones in a grid, but the images didn't all draw at the same time. I think that that may have had something to do with modifying the array that it was using to determine what to draw but I couldn't get it resolved even when pausing the drawing. Now I have images that drop down and new ones fall in (think slot machine reels) but the images will occasionally flicker with what the new image is going to be before the old images fall out. Basically I guess I'm asking what is a good way to either pause the onDraw command while I can edit my arrays and get them all in place or what is a good way to sync my array modifications to not take place during an onDraw cycle? Or is onDraw just bad at drawing images simultaneously and I should be using OpenGL or something? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- ~ Jeremiah:9:23-24 Android 2D MMORPG:http://solrpg.com/, http://www.youtube.com/user/revoltingx -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Is there a best (or worst) time to release apps?
Specifically, is it, for example, better to release an app on a weekday, as opposed to over a weekend, or on a holiday, etc.? I'm just wondering if there are typically drops in sales over weekends, on holidays, when major sporting events are on, and so on, or, is it more or less even across the board? This is something I've wondered since releasing[1] my first app Later, --jim [1] I hope that's spelled right---my brain is jumbling the letters around and I have no idea if I made the typo I think I felt in my fingers, or not -- 73 DE N5IAL (/4)MiSTie #49997 Running FreeBSD 7.0 spooky1...@gmail.comICBM/Hurr.: 30.44406N 86.59909W Saw something on TV about Psych-os. H, Psych OS. Perhaps the next freeware OS --me -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: I need a CamScanner like example
You did not ask for image aligning anything... you asked for something like GeniusScan... or as you called it scam papper which I can only assume was supposed to mean scan paper. Therefore I suggested searching for android open source ocr... OCR stands for Optical Character Recognition. So which one is it? Do you want image aligning knowledge or scan paper knowledge? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Google contact name fetch
I want to fetch name of a contact by its id.My code as below: public void Get_Contact_Name(String id) { String[] projection = new String[] {ContactsContract.CommonDataKinds.StructuredName.DISPLAY_NAME, ContactsContract.CommonDataKinds.StructuredName.FAMILY_NAME, ContactsContract.CommonDataKinds.StructuredName.GIVEN_NAME, ContactsContract.CommonDataKinds.StructuredName.SUFFIX, ContactsContract.CommonDataKinds.StructuredName.PREFIX, ContactsContract.CommonDataKinds.StructuredName.MIDDLE_NAME}; String where = ContactsContract.Data.CONTACT_ID + = ? AND + ContactsContract.Data.MIMETYPE + = ?; String[] whereParameters = new String[]{id, ContactsContract.CommonDataKinds.StructuredName.CONTENT_ITEM_TYPE}; Cursor contacts = contentresolver.query(ContactsContract.Data.CONTENT_URI, projection, where, whereParameters, null); if (contacts.moveToFirst()) { display_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.DISPLAY_NAME; given_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.GIVEN_NAME; suffix_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.SUFFIX; prefix_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.PREFIX; middle_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.MIDDLE_NAME; family_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.FAMILY_NAME; } contacts.close(); } it gives error.Can anyone tell me whats the wrong? Thanks in advance. Regards riskycoder -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Is there a best (or worst) time to release apps?
That would be more a market question... -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Google contact name fetch
Sorry for fonts.Here is the code to modify: public void Get_Contact_Name(String id) { String[] projection = new String[] {ContactsContract.CommonDataKinds.StructuredName.DISPLAY_NAME, ContactsContract.CommonDataKinds.StructuredName.FAMILY_NAME, ContactsContract.CommonDataKinds.StructuredName.GIVEN_NAME, ContactsContract.CommonDataKinds.StructuredName.SUFFIX, ContactsContract.CommonDataKinds.StructuredName.PREFIX, ContactsContract.CommonDataKinds.StructuredName.MIDDLE_NAME}; String where = ContactsContract.Data.CONTACT_ID + = ? AND + ContactsContract.Data.MIMETYPE + = ?; String[] whereParameters = new String[]{id, ContactsContract.CommonDataKinds.StructuredName.CONTENT_ITEM_TYPE}; Cursor contacts = contentresolver.query(ContactsContract.Data.CONTENT_URI, projection, where, whereParameters, null); if (contacts.moveToFirst()) { contactcontent.contact_display_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.DISPLAY_NAME; contactcontent.contact_given_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.GIVEN_NAME; contactcontent.contact_suffix_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.SUFFIX; contactcontent.contact_prefix_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.PREFIX; contactcontent.contact_middle_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.MIDDLE_NAME; contactcontent.contact_family_name = Null_check((contacts.getString(contacts.getColumnIndex(ContactsContract.CommonDataKinds.StructuredName.FAMILY_NAME; } contacts.close(); } -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: 3rdParty application icon
Thanks Mark, much appreciated, that works. Just to let you com.google.android.gallery3d is the package name, but for some reason simply calling setPackage() on the intent works for some packages but not others. Now, that I know the issue, I suppose Application is not installed makes sense, although it would be nice if it could resolve to a more meaningful message. John On Aug 6, 4:32 am, Mark Murphy mmur...@commonsware.com wrote: On Sat, Aug 6, 2011 at 1:46 AM, John android...@gmail.com wrote: In the case of the Gallery application i.e. com.google.android.gallery3d, which throws the Application is not installed error in the shortcut, it shows up both in getInstalledPackages and also in queryIntentActivities with the given Intent, also it only has one entry in the queryIntentActivities which confuses me even more. If it had more than one entry, that would make sense to me, I would need to specify which className to invoke. com.google.android.gallery3d doesn't exist in the Android open source project (at least Google Code Search doesn't turn it up), and the Gallery3D project doesn't use that package. Have you tried creating a shortcut based on the actual ResolveInfo object? Here's the code snippet for creating such an Intent: Intent buildLauncherIntent(ResolveInfo launchable) { ActivityInfo activity=launchable.activityInfo; ComponentName name=new ComponentName(activity.applicationInfo.packageName, activity.name); Intent i=new Intent(Intent.ACTION_MAIN); i.addCategory(Intent.CATEGORY_LAUNCHER); i.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED); i.setComponent(name); return(i); } -- Mark Murphy (a Commons Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy _Android Programming Tutorials_ Version 3.5 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
Re: [android-developers] Re: Google contact name fetch
If you attach a logcat with the error maybe we can help 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
Re: [android-developers] Re: Google contact name fetch
Hi Nick Thanks for reply.It dont stop my app.But skips this step.I think my problems in these two lines: String where = ContactsContract.Data.CONTACT_ ID + = ? AND + ContactsContract.Data.MIMETYPE + = ?; String[] whereParameters = new String[]{id, ContactsContract.CommonDataKinds.StructuredName.CONTENT_ITEM_TYPE}; Cursor contacts = contentresolver.query(ContactsContract.Data.CONTENT_URI, projection, where, whereParameters, null); can u check this please? On Sat, Aug 6, 2011 at 5:40 PM, Nick Risaro nris...@gmail.com wrote: If you attach a logcat with the error maybe we can help 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Is there a best (or worst) time to release apps?
On Sat, Aug 06, 2011 at 05:32:09PM -0700, rich friedel wrote: That would be more a market question... Of which there are rather a lot in this group. Do you respond to them in the same way? I've never noticed, if you have. So basically, your answer is that there is no best timethat there is always someone around somewhere, and weekends vs weekends vs holidays become irrelevant? Or did I read your response incorrectly? Later, --jim -- 73 DE N5IAL (/4)| Peter da Silva: No, try rm -rf / spooky1...@gmail.com| Dave Aronson:As your life flashes before Running FreeBSD 7.0 | your eyes, in the unit of time known as an ICBM / Hurricane: | ohnosecond (alt.sysadmin.recovery) 30.44406N 86.59909W | -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Google contact name fetch
On Sat, Aug 6, 2011 at 9:49 PM, Goutom goutom.sust@gmail.com wrote: Hi Nick Thanks for reply.It dont stop my app. Check the log anyway, maybe there is a hint of whats happening there. But skips this step. What step? I think my problems in these two lines: String where = ContactsContract.Data.CONTACT_ ID + = ? AND + ContactsContract.Data.MIMETYPE + = ?; String[] whereParameters = new String[]{id, ContactsContract.CommonDataKinds.StructuredName.CONTENT_ITEM_TYPE}; Cursor contacts = contentresolver.query(ContactsContract.Data.CONTENT_URI, projection, where, whereParameters, null); Try whit less parameters in the query, use the debugger to check step by step whats happening and/or put some log in your code. can u check this please? On Sat, Aug 6, 2011 at 5:40 PM, Nick Risaro nris...@gmail.com wrote: If you attach a logcat with the error maybe we can help 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Comms with Intent
Well - the issue I am running into now is this: Calling startActivity() from outside of an Activity context requires the FLAG_ACTIVITY_NEW_TASK flag. Is this really what you want? I start the activity with the NEW_TASK flag and it works fine. If I use the SINGLE_TOP then the exception above occurs. Is there a way to combine intent flags in Android? intent.setClass(androidContext, org.mortbay.ijetty.snapPic2.mysnapPic2ServiceImpl.class); // intent.setFlags(intent.FLAG_ACTIVITY_NEW_TASK); intent.setFlags(intent.FLAG_ACTIVITY_SINGLE_TOP); On Aug 2, 10:35 am, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Tue, Aug 2, 2011 at 11:29 PM, kypriakos demet...@ece.neu.edu wrote: Actually one more question - since I want the Activity to keep alive with the camera preview on, would the subsequent Intent launching (and calls to OnNewIntent) allow me to control the open preview. I think yes since the Activity (unless I call finish()) should still be active right? As long as you don't start another activity, your preview activity should stay in the foreground. How well that will work with controlling the actual preview, I don't know. Try it out. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Comms with Intent
Actually never mind that - I should have been using addFlags the second time and not setFlags on both flags. Still the issue seems to be that the preview freezes after the first pic is snapped and every additional call to the service takes pictures the same size as before regardless of where the phone points. Interesting ... And I don't see the OnNewIntent get called each subsequent time ... On Aug 7, 12:33 am, kypriakos demet...@ece.neu.edu wrote: Well - the issue I am running into now is this: Calling startActivity() from outside of an Activity context requires the FLAG_ACTIVITY_NEW_TASK flag. Is this really what you want? I start the activity with the NEW_TASK flag and it works fine. If I use the SINGLE_TOP then the exception above occurs. Is there a way to combine intent flags in Android? intent.setClass(androidContext, org.mortbay.ijetty.snapPic2.mysnapPic2ServiceImpl.class); // intent.setFlags(intent.FLAG_ACTIVITY_NEW_TASK); intent.setFlags(intent.FLAG_ACTIVITY_SINGLE_TOP); On Aug 2, 10:35 am, Nikolay Elenkov nikolay.elen...@gmail.com wrote: On Tue, Aug 2, 2011 at 11:29 PM, kypriakos demet...@ece.neu.edu wrote: Actually one more question - since I want the Activity to keep alive with the camera preview on, would the subsequent Intent launching (and calls to OnNewIntent) allow me to control the open preview. I think yes since the Activity (unless I call finish()) should still be active right? As long as you don't start another activity, your preview activity should stay in the foreground. How well that will work with controlling the actual preview, I don't know. Try it out. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en