[android-developers] Upgraded JSON Signature Scheme
https://openkeystore.googlecode.com/svn/resources/trunk/docs/jcs.html http://webpki.org/downloads/secure-json-4-android-v1.00.zip New and complete spec. in HTML5. Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
[android-developers] Secure JSON - Light-weight replacement for the missing XML DSig support
Docs + Demo:https://mobilepki.org/jcs Source:http://webpki.org/downloads/secure-json-4-android-v1.00.zip Usage in an application:https://play.google.com/store/apps/details?id=org.webpki.mobile.android Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 unsubscribe from this group and stop receiving emails from it, send an email to android-developers+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
[android-developers] Blocked by Moderator?
I have sent several messages to this list and none of them show up. What's the reason for this? Anders Rundgren -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 Browser plug in
I wanted the same but have given up on the idea since plugins doesn't exist in Android and have been removed in Windows 8. The currently only useful method seems to use a custom protocol like Google does with market://. If you search stackoverflow you will find example of how you do that. It is cool :-) BTW! Anders On Monday, October 29, 2012 8:03:13 AM UTC+1, Mr cool wrote: i am new android , i need to build a plug for android native browser ,i don't where i start it, i surfing internet i don't get correct source for my development any one have sample code for Android browser plug 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] XML Schema Validation in Android
Since Google has declined to support XML Schema validation http://code.google.com/p/android/issues/detail?id=7395 and the method for adding an XML schema-compliant parser is not actually implemented (!) I took a somewhat dated Xerces port of mine and made it available for general use. The source code + Ant build script: http://code.google.com/p/openkeystore/source/browse/#svn%2Ftrunk%2Fandroid.mod The binary (jar) including an Android test program: http://code.google.com/p/openkeystore/source/browse/#svn%2Ftrunk%2Fxsd-4-android The code has been tested in GB (2.3.6) and JB (4.1). -- Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Creating keys for usage with KeyChain
Google can create keys accessible through KeyChain using the browser and keygen. How can mere mortals do the same thing? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Validating XML Parser - Available
Since Google claims that they don't intend to support XML Schema validation some people have done various ports. On https://code.google.com/p/openkeystore/ There is a project android.mod that contains the source of a Xerces port. Using ant you can create a jar for putting in libs. There is also a test-app xsd-4android allowing you to test the parser. Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Check support for wifi personal hotspot
Does anyone know how an app may check whether a device supports wifi mobile hotspot/wifi tethering? For example, my Android phone has this functionality and you can tether the 3G connection, while my newer android tablet does not support it. To complicate things further, I actually have another tablet, with only wifi and no 3G that do support the portable hotspot mode. Please observe that I am not asking how to enable the hotspot, just whether the device has support for it. 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] Inserting batch of contact entries is slow
Hi, I'm developing an application where I need to insert a lot of contacts which potentially can have thousands of numbers. At the moment there is a total of 600 contacts with a total of 6000 numbers, where the biggest contact has 1300 phone numbers. I have created a custom account for these contacts so I don't mess up the users contact list. At the moment I am inserting the contacts using ContentResolver.applyBatch against the Contacts database. I've tried to gather up a list of ContentProviderOperations with insertion of RawContacts and Phone-entries of different sizes (50, 100, 200, 400), but the insertion is painfully slow. The whole import takes approx. 30 minutes, so each of theese batch insertions takes several minutes.. I've done some Googleing, and most issues with slow insertion into SQLlite is resolved using transactions, but I suppose the ContentResolver and the applyBatch method is taking care of this for me? Any other suggestions on how to improve the performance? Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Package file was not signed correctly error
Oh brother, that was easy :) Uninstall, then reinstall fixed the problem (and none of my 600 users ever had a problem). Thanks! Anders On Mar 22, 12:47 am, Justin Anderson magouyaw...@gmail.com wrote: Or vice-versa... It happens either way. Thanks, Justin Anderson MagouyaWare Developerhttp://sites.google.com/site/magouyaware On Mon, Mar 21, 2011 at 10:47 PM, Justin Anderson magouyaw...@gmail.comwrote: I usually run into this when I have a debug version on my phone already installed from doing development and then forgetting to uninstall it before trying to install the release version. Thanks, Justin Anderson MagouyaWare Developer http://sites.google.com/site/magouyaware On Mon, Mar 21, 2011 at 5:59 AM, Anders byl...@gmail.com wrote: My application refuses to install from the Market since I uploaded a new version. First, I had trouble finding the right keystore again after a few months of not touching the app. Market finally stopped halting the uploads with messages about the wrong signature, so everything seemed okay. But the new version refuses to install. Logcat dump in debug mode from trying it on my own phone: 03-21 07:15:59.740: DEBUG/vending(1401): [14] LocalAssetDatabase.notifyListener(): -5180615462709890363 / DOWNLOAD_PENDING 03-21 07:15:59.890: INFO/vending(1401): [14] RequestDispatcher $RequestContext.init(): Some requests use secure token but dont require SSL. Forcing SSL. 03-21 07:16:01.010: DEBUG/RC_WifiBroadcastReceiver(20453): action android.net.wifi.SCAN_RESULTS 03-21 07:16:01.010: DEBUG/RC_WifiService(20453): notifyScanResults() 760811490 03-21 07:16:01.330: DEBUG/MobileDataStateTracker(158): hipri Received state= CONNECTED, old= CONNECTED, reason= (unspecified), apnTypeList= default,supl,mms 03-21 07:16:01.360: DEBUG/MobileDataStateTracker(158): replacing old mInterfaceName (rmnet0) with rmnet0 for supl 03-21 07:16:01.380: DEBUG/MobileDataStateTracker(158): replacing old mInterfaceName (rmnet0) with rmnet0 for mms 03-21 07:16:01.380: DEBUG/MobileDataStateTracker(158): default Received state= CONNECTED, old= CONNECTED, reason= (unspecified), apnTypeList= default,supl,mms 03-21 07:16:01.550: DEBUG/NetworkLocationProvider(158): onDataConnectionStateChanged 3 03-21 07:16:02.810: DEBUG/vending(1401): [87] AssetDownloader.downloadAndInstall(): Initiating Download for 1 applications. 03-21 07:16:02.810: INFO/vending(1401): [87] DownloadManagerUtil.enqueueDownload(): Enqueue for download com.android.vending.util.DownloadManagerUtil$Request@43de9668 03-21 07:16:03.020: DEBUG/vending(1401): [87] LocalAssetDatabase.notifyListener(): -5180615462709890363 / null 03-21 07:16:03.460: DEBUG/vending(1401): [87] LocalAssetDatabase.notifyListener(): -5180615462709890363 / DOWNLOADING 03-21 07:16:06.820: DEBUG/dalvikvm(2573): GC_FOR_MALLOC freed 7137 objects / 439928 bytes in 116ms 03-21 07:16:08.750: DEBUG/dalvikvm(2557): GC_EXPLICIT freed 328 objects / 16528 bytes in 96ms 03-21 07:16:09.670: DEBUG/dalvikvm(158): GC_EXPLICIT freed 22964 objects / 1049192 bytes in 284ms 03-21 07:16:10.100: INFO/vending(1401): [96] AssetDownloader $DownloadManagerBroadcastReceiver.startNextDownload(): Found Paused URI null 03-21 07:16:10.110: INFO/vending(1401): [96] AssetDownloader $DownloadManagerBroadcastReceiver.startNextDownload(): No more paused downloads. 03-21 07:16:10.110: DEBUG/vending(1401): [96] AssetDownloader $DownloadManagerBroadcastReceiver.handleDownloadCompletedAction(): Got a download completed intent. 03-21 07:16:10.260: DEBUG/vending(1401): [96] LocalAssetDatabase.notifyListener(): -5180615462709890363 / null 03-21 07:16:10.340: DEBUG/vending(1401): [97] AssetDownloader $DownloadManagerBroadcastReceiver.installFromUri(): Calling install uri=content://downloads/download/812 src=null asset=-5180615462709890363 (RobotMoose.TennisScore:8) [DOWNLOADING] name=Tennis Score last=TRUE 03-21 07:16:10.730: DEBUG/vending(1401): [97] LocalAssetDatabase.notifyListener(): -5180615462709890363 / INSTALLING 03-21 07:16:10.880: DEBUG/vending(1401): [97] VendingNotificationManager.showNotification(): Showing notification: [AssetID=-5180615462709890363, NotificationID=-1700280694, Title=Tennis Score, Message=Installing…] 03-21 07:16:11.260: DEBUG/MobileDataStateTracker(158): hipri Received state= CONNECTED, old= CONNECTED, reason= (unspecified), apnTypeList= default,supl,mms 03-21 07:16:11.280: DEBUG/MobileDataStateTracker(158): replacing old mInterfaceName (rmnet0) with rmnet0 for supl 03-21 07:16:11.280: DEBUG/MobileDataStateTracker(158): replacing old mInterfaceName (rmnet0) with rmnet0 for mms 03-21 07:16:11.290: DEBUG/MobileDataStateTracker(158): default Received state= CONNECTED, old= CONNECTED, reason= (unspecified), apnTypeList= default,supl,mms 03-21 07:16:11.650: DEBUG/dalvikvm(248): GC_FOR_MALLOC freed 10547
[android-developers] Package file was not signed correctly error
My application refuses to install from the Market since I uploaded a new version. First, I had trouble finding the right keystore again after a few months of not touching the app. Market finally stopped halting the uploads with messages about the wrong signature, so everything seemed okay. But the new version refuses to install. Logcat dump in debug mode from trying it on my own phone: 03-21 07:15:59.740: DEBUG/vending(1401): [14] LocalAssetDatabase.notifyListener(): -5180615462709890363 / DOWNLOAD_PENDING 03-21 07:15:59.890: INFO/vending(1401): [14] RequestDispatcher $RequestContext.init(): Some requests use secure token but dont require SSL. Forcing SSL. 03-21 07:16:01.010: DEBUG/RC_WifiBroadcastReceiver(20453): action android.net.wifi.SCAN_RESULTS 03-21 07:16:01.010: DEBUG/RC_WifiService(20453): notifyScanResults() 760811490 03-21 07:16:01.330: DEBUG/MobileDataStateTracker(158): hipri Received state= CONNECTED, old= CONNECTED, reason= (unspecified), apnTypeList= default,supl,mms 03-21 07:16:01.360: DEBUG/MobileDataStateTracker(158): replacing old mInterfaceName (rmnet0) with rmnet0 for supl 03-21 07:16:01.380: DEBUG/MobileDataStateTracker(158): replacing old mInterfaceName (rmnet0) with rmnet0 for mms 03-21 07:16:01.380: DEBUG/MobileDataStateTracker(158): default Received state= CONNECTED, old= CONNECTED, reason= (unspecified), apnTypeList= default,supl,mms 03-21 07:16:01.550: DEBUG/NetworkLocationProvider(158): onDataConnectionStateChanged 3 03-21 07:16:02.810: DEBUG/vending(1401): [87] AssetDownloader.downloadAndInstall(): Initiating Download for 1 applications. 03-21 07:16:02.810: INFO/vending(1401): [87] DownloadManagerUtil.enqueueDownload(): Enqueue for download com.android.vending.util.DownloadManagerUtil$Request@43de9668 03-21 07:16:03.020: DEBUG/vending(1401): [87] LocalAssetDatabase.notifyListener(): -5180615462709890363 / null 03-21 07:16:03.460: DEBUG/vending(1401): [87] LocalAssetDatabase.notifyListener(): -5180615462709890363 / DOWNLOADING 03-21 07:16:06.820: DEBUG/dalvikvm(2573): GC_FOR_MALLOC freed 7137 objects / 439928 bytes in 116ms 03-21 07:16:08.750: DEBUG/dalvikvm(2557): GC_EXPLICIT freed 328 objects / 16528 bytes in 96ms 03-21 07:16:09.670: DEBUG/dalvikvm(158): GC_EXPLICIT freed 22964 objects / 1049192 bytes in 284ms 03-21 07:16:10.100: INFO/vending(1401): [96] AssetDownloader $DownloadManagerBroadcastReceiver.startNextDownload(): Found Paused URI null 03-21 07:16:10.110: INFO/vending(1401): [96] AssetDownloader $DownloadManagerBroadcastReceiver.startNextDownload(): No more paused downloads. 03-21 07:16:10.110: DEBUG/vending(1401): [96] AssetDownloader $DownloadManagerBroadcastReceiver.handleDownloadCompletedAction(): Got a download completed intent. 03-21 07:16:10.260: DEBUG/vending(1401): [96] LocalAssetDatabase.notifyListener(): -5180615462709890363 / null 03-21 07:16:10.340: DEBUG/vending(1401): [97] AssetDownloader $DownloadManagerBroadcastReceiver.installFromUri(): Calling install uri=content://downloads/download/812 src=null asset=-5180615462709890363 (RobotMoose.TennisScore:8) [DOWNLOADING] name=Tennis Score last=TRUE 03-21 07:16:10.730: DEBUG/vending(1401): [97] LocalAssetDatabase.notifyListener(): -5180615462709890363 / INSTALLING 03-21 07:16:10.880: DEBUG/vending(1401): [97] VendingNotificationManager.showNotification(): Showing notification: [AssetID=-5180615462709890363, NotificationID=-1700280694, Title=Tennis Score, Message=Installing…] 03-21 07:16:11.260: DEBUG/MobileDataStateTracker(158): hipri Received state= CONNECTED, old= CONNECTED, reason= (unspecified), apnTypeList= default,supl,mms 03-21 07:16:11.280: DEBUG/MobileDataStateTracker(158): replacing old mInterfaceName (rmnet0) with rmnet0 for supl 03-21 07:16:11.280: DEBUG/MobileDataStateTracker(158): replacing old mInterfaceName (rmnet0) with rmnet0 for mms 03-21 07:16:11.290: DEBUG/MobileDataStateTracker(158): default Received state= CONNECTED, old= CONNECTED, reason= (unspecified), apnTypeList= default,supl,mms 03-21 07:16:11.650: DEBUG/dalvikvm(248): GC_FOR_MALLOC freed 10547 objects / 534800 bytes in 334ms 03-21 07:16:11.760: DEBUG/dalvikvm(2708): GC_EXPLICIT freed 79 objects / 4104 bytes in 321ms 03-21 07:16:11.820: DEBUG/NetworkLocationProvider(158): onDataConnectionStateChanged 3 03-21 07:16:11.860: DEBUG/VoldCmdListener(117): asec list 03-21 07:16:12.130: INFO/PackageHelper(2708): Size of container 2 MB 476117 bytes 03-21 07:16:12.130: DEBUG/VoldCmdListener(117): asec create smdl2tmp1 2 fat {} 10014 03-21 07:16:12.210: DEBUG/MediaScannerService(2573): IMediaScannerService.scanFile: /mnt/sdcard/download/downloadfile-9.apk mimeType: application/vnd.android.package-archive 03-21 07:16:12.270: INFO//system/bin/newfs_msdos(117): /system/bin/ newfs_msdos: warning, /dev/block/dm-22 is not a character device 03-21 07:16:12.270: INFO//system/bin/newfs_msdos(117): /system/bin/ newfs_msdos: Skipping mount checks 03-21 07:16:12.280: INFO//system/bin/newfs_msdos(117): Bogus heads from kernel - setting sane
Re: [android-developers] Re: google analytics and active installs on market way off
It's a free app, so they are free to copy to wherever they want. But a jump from 30k downloads in market to 120k users seem extreme to me. To the level where something's gotta be wrong somewhere. Or is this normal? Best regards Anders On Sun, Jan 30, 2011 at 3:33 PM, Hari Edo hari@gmail.com wrote: Congrats on having such a popular app. Sounds like your child has grown up and left home, moved off to other markets without asking your permission. Some people would say it's stealing, piracy, and must be stopped at all costs. Some people would say that the more people see it, the more people will buy it, so those underground copies are just a form of advertising. I just wish the market and the analytics would update more often than 24 hours. On Jan 30, 9:05 am, neuron aagaa...@gmail.com wrote: Hi I got an application that onhttp://market.android.com/publish/showsaround 20k active installs / 30k total installs. However, google analytics for the app (that's not really doing anything weird. It's just using the normal api, collecting fairly standard data). Is showing 100k+ unique visitors since launch (around 37k so far this month). What should I trust? -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- Weeks of coding can save you hours of planning. - http://code.google.com/p/aagaande/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: performance when passing background data to ui thread
I'm actually seeing the handler code show up in my profiler. And I'm passing a lot of small data many times. As the code was initially built for parsing while loading from the network with xml. And not the download then parse json code. In terms of synchronization issues, I use an interface between those pieces of code anyway. So that shouldn't be a problem. On Wed, Jan 26, 2011 at 10:24 PM, Pepijn Van Eeckhoudt pep...@vaneeckhoudt.net wrote: I tend to prefer the handler approach over synchronized methods just because it's less easy to shoot yourself in the foot if only a single thread touches your data structures. Performance wise there shouldn't be any fundamental difference between the handler approach and the synchronized method approach since it's all within the same process. No data copies are occuring in either case. The one thing you might notice is a little bit of additional latency when using the handler as this posts a runnable to the end of an event queue. Pepijn Op 26 Jan 2011 om 21:28 heeft Anders Aagaard aagaa...@gmail.com het volgende geschreven: Thank you! I wasn't sure what was the cleanest way of doing it. And I'm very familiar with threading, just not how java does it (and the synchronized isn't something I'm familiar with from other platforms). I'll try to push some of the sorting/filtering into the threads as well, to reduce amount of time I spend in the main thread. On Wed, Jan 26, 2011 at 8:09 PM, Hari Edo hari@gmail.com hari@gmail.com wrote: If you're sure that all users of the data are within the same process (the same app), then using Java synchronized is the best way to go. However, you will need to be very careful to understand your semaphore dependencies, or deadlock will occur. Not responding is almost as bad as Data corrupted due to bad inter-thread communication. The use of Bundles and/or ContentProviders are to enable inter-process data passing, and to avoid some of the danger of errant deadlock situations. On Jan 26, 10:37 am, neuron aagaa...@gmail.com wrote: Hi I've got an app that spawns of a seperate thread. Parses JSON data into a structure. And passes it back to the main thread through a handler. Each part of data is sent through the handler individually. That worked fairly well with my previous XML parser, as XML parses data while it downloads. But JSON doesn't (atleast I haven't found a way to get that working). In either way the JSON data is much smaller and much faster to parse. I've recently added a feature that requires me to load several sources of json in parallel, parse in the background, and pass all the data back again using a Handler. This is a bit slower than I was hoping. Would it be faster (and possible) for me to do this: BackgroundThread extends Thread { onCreate (Parent) { this.parent = parent; } onData { parent.addParsedData(x); } } Parent extends ListActivity { ListAdapter list; onCreate { setListAdapter(list); new BackgroundThread(this); } public synchronized addParsedData(data) { list.add(data) } } I'm thinking this won't be thread safe, as ListAdapter is in the parent thread. Am I right? Should I instead inside the listadapter (which puts data in an array) have synchronized access to it's items? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.comandroid-developers@googlegroups.com To unsubscribe from this group, send email to android-developers%2bunsubscr...@googlegroups.com android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en http://groups.google.com/group/android-developers?hl=en -- Weeks of coding can save you hours of planning. - http://code.google.com/p/aagaande/http://code.google.com/p/aagaande/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en 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.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group
Re: [android-developers] Re: performance when passing background data to ui thread
Thank you! I wasn't sure what was the cleanest way of doing it. And I'm very familiar with threading, just not how java does it (and the synchronized isn't something I'm familiar with from other platforms). I'll try to push some of the sorting/filtering into the threads as well, to reduce amount of time I spend in the main thread. On Wed, Jan 26, 2011 at 8:09 PM, Hari Edo hari@gmail.com wrote: If you're sure that all users of the data are within the same process (the same app), then using Java synchronized is the best way to go. However, you will need to be very careful to understand your semaphore dependencies, or deadlock will occur. Not responding is almost as bad as Data corrupted due to bad inter-thread communication. The use of Bundles and/or ContentProviders are to enable inter-process data passing, and to avoid some of the danger of errant deadlock situations. On Jan 26, 10:37 am, neuron aagaa...@gmail.com wrote: Hi I've got an app that spawns of a seperate thread. Parses JSON data into a structure. And passes it back to the main thread through a handler. Each part of data is sent through the handler individually. That worked fairly well with my previous XML parser, as XML parses data while it downloads. But JSON doesn't (atleast I haven't found a way to get that working). In either way the JSON data is much smaller and much faster to parse. I've recently added a feature that requires me to load several sources of json in parallel, parse in the background, and pass all the data back again using a Handler. This is a bit slower than I was hoping. Would it be faster (and possible) for me to do this: BackgroundThread extends Thread { onCreate (Parent) { this.parent = parent; } onData { parent.addParsedData(x); } } Parent extends ListActivity { ListAdapter list; onCreate { setListAdapter(list); new BackgroundThread(this); } public synchronized addParsedData(data) { list.add(data) } } I'm thinking this won't be thread safe, as ListAdapter is in the parent thread. Am I right? Should I instead inside the listadapter (which puts data in an array) have synchronized access to it's items? -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- Weeks of coding can save you hours of planning. - http://code.google.com/p/aagaande/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: adb works, ddms shows nothing
Hm No I don't run adb as root, nor should I need to. But I'll try that the next time it happens, not too happy about running it as root though. And it does work after while, which it shouldn't if it was a permission issue. Best regards Anders On Tue, Jan 18, 2011 at 4:57 AM, Indicator Veritatis mej1...@yahoo.comwrote: H-m-m-m. That is a little weird. I too am running on Linux, but Fedora 12 instead of Ubuntu. And the only time I have not been able to solve similar problems with adb kill-server;adb start-server, it was because the wrong device was selected in the Device Window in Eclipse. So check that. Also, it never made sense to me that it should make a difference, but I have noticed that adb kill-server;adb start-server works better when executed from a shell that is in superuser. So did you use sudo w/ it? On Jan 16, 10:01 am, Anders Aagaard aagaa...@gmail.com wrote: I just left this running, and after about 2 minutes it works! However, it'd be awsome to not have to wait for minutes every time I start ddms. On Sun, Jan 16, 2011 at 6:58 PM, neuron aagaa...@gmail.com wrote: adb works, I use it a lot. adb devices shows the device (a nexus one), shell/pull/push everything seems to work. eclipse screws up, often. ddms shows no devices connected, and in console I only get a few gtk window warnings. Half the time when I start eclipse it keeps a neverending process running so i can't build anything. ddms shows no devices connected (and when I shut it down it doesn't quit properly, i have to ctrl+c it). How can I debug this? (adb kill-server; adb start-server does not help) This is on linux, ubuntu 10.10, kernel 2.6.37. -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- Weeks of coding can save you hours of planning. -http://code.google.com/p/aagaande/ -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- Weeks of coding can save you hours of planning. - http://code.google.com/p/aagaande/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: ClassNotFoundException on Market developer console
I just got this error recently, and my app also prefers external installation. I haven't been able to reproduce the error either. On 2 Jan, 16:09, Matteo Vega vegao...@gmail.com wrote: Hi, I have an application that's on Android Market with 10,000 users. Every once in while (once or twice a week), I am getting a ClassNotFoundException on the Market Developer Console for my main activity: java.lang.RuntimeException: Unable to instantiate activity ComponentInfo{com.mycompany.myapp/com.mycompany.myapp.MainActivity}: java.lang.ClassNotFoundException: com.mycompany.myapp.MainActivity in loader dalvik.system.PathClassLoader[/mnt/asec/com.mycompany.myapp-1/pkg.apk] at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2757) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2866) at android.app.ActivityThread.access$2300(ActivityThread.java:140) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2181) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:143) at android.app.ActivityThread.main(ActivityThread.java:5097) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:521) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626) at dalvik.system.NativeStart.main(Native Method) Caused by: java.lang.ClassNotFoundException: com.mycompany.myapp.MainActivity in loader dalvik.system.PathClassLoader[/mnt/asec/com.mycompany.myapp-1/pkg.apk] at dalvik.system.PathClassLoader.findClass(PathClassLoader.java:243) at java.lang.ClassLoader.loadClass(ClassLoader.java:573) at java.lang.ClassLoader.loadClass(ClassLoader.java:532) at android.app.Instrumentation.newActivity(Instrumentation.java:1034) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2749) ... 11 more Note that this application is in production and used by 10,000 people and MainActivity is the very first activity during startup. This error happens very rarely, but yet it happens. I couldn't reproduce it on my developer phone nor the emulator, so I ended up adding a default application that's extended from Application and called before my main activity, but this time I got the same exception for my Application class: java.lang.RuntimeException: Unable to instantiate application com.mycompany.myapp.App: java.lang.ClassNotFoundException: com.mycompany.myapp.App in loader dalvik.system.PathClassLoader[/mnt/asec/com.mycompany.myapp-1/pkg.apk] at android.app.ActivityThread$PackageInfo.makeApplication(ActivityThread.java:649) at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4232) at android.app.ActivityThread.access$3000(ActivityThread.java:125) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2071) at android.os.Handler.dispatchMessage(Handler.java:99) at android.os.Looper.loop(Looper.java:123) at android.app.ActivityThread.main(ActivityThread.java:4627) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:521) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:876) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:634) at dalvik.system.NativeStart.main(Native Method) Caused by: java.lang.ClassNotFoundException: com.mycompany.myapp.App in loader dalvik.system.PathClassLoader[/mnt/asec/com.mycompany.myapp-1/pkg.apk] at dalvik.system.PathClassLoader.findClass(PathClassLoader.java:243) at java.lang.ClassLoader.loadClass(ClassLoader.java:573) at java.lang.ClassLoader.loadClass(ClassLoader.java:532) at android.app.Instrumentation.newApplication(Instrumentation.java:942) at android.app.ActivityThread$PackageInfo.makeApplication(ActivityThread.java:644) ... 11 more This application is installed to SD Card by default and my guess is that it might be SD Card related, so I tried to mount/unmount my SD Card to reproduce it and still no luck. I am really puzzled at this point and trying to find out if anyone has suggestions. ClassNotFoundException is thrown when the app package does not contain a required class, but that's not the case for my app. Please help :) Thank you, -Vega -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] adb works, ddms shows nothing
I just left this running, and after about 2 minutes it works! However, it'd be awsome to not have to wait for minutes every time I start ddms. On Sun, Jan 16, 2011 at 6:58 PM, neuron aagaa...@gmail.com wrote: adb works, I use it a lot. adb devices shows the device (a nexus one), shell/pull/push everything seems to work. eclipse screws up, often. ddms shows no devices connected, and in console I only get a few gtk window warnings. Half the time when I start eclipse it keeps a neverending process running so i can't build anything. ddms shows no devices connected (and when I shut it down it doesn't quit properly, i have to ctrl+c it). How can I debug this? (adb kill-server; adb start-server does not help) This is on linux, ubuntu 10.10, kernel 2.6.37. -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- Weeks of coding can save you hours of planning. - http://code.google.com/p/aagaande/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Gradient, Shadow and MaskFilter on a TextView
Hello. Im trying to customize a textview to add a gradientoverlay, a dropshadow and a maskfilter. There seems like i cant combine the different methods as i thought i would. For example when i use both gradient and shadow my shadow gets the same color as the gradient. Combinding dropshadow and a maskfilters renders no text at all. While a combination of gradient overlay seems to work fine. I have extended TextView and overriden onDraw: protected void onDraw(Canvas canvas) { TextPaint paint = getPaint(); // paint.setShader(new LinearGradient(8f, 80f, 30f, 20f, Color.RED,Color.WHITE,Shader.TileMode.MIRROR)); float height = paint.getFontSpacing(); Toast.makeText(getContext(), h: +height, Toast.LENGTH_SHORT).show(); paint.setMaskFilter(new EmbossMaskFilter(new float[] { 0, 0.3f, 0 },0.95f, 10, 0.1f)); // paint.setShadowLayer(0.1f, 30f, 5f, Color.parseColor(#ff)); paint.setShader(new LinearGradient(0, 0, 0, height, new int[] { GRADIENT_START,GRADIENT_MID,GRADIENT_MID,GRADIENT_END }, new float[] {0,0.4f,0.6f,1f}, Shader.TileMode.CLAMP)); super.onDraw(canvas); } Does these filters not work together? Is it the wrong aproach to try to extend a textview, should i create my own View for drawing thext with gradients, shadows and masks? // Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Activity display over incoming call screen
I solved that issue using an delay before starting the activity thus getting it displayed ontop of the call screen. But then I had problems with my activity taking focus from the call screen. I ended up displaying a custom toast notification instead. On Nov 14, 4:35 am, Dianne Hackborn hack...@android.com wrote: What you are trying to do is simply not going to work reliably. The incoming call broadcast is a broadcast, and at the same time you are handling it and doing something the system is in the process of showing the in-call screen. There is a race going on between you starting your activity and the in-call screen activity being started, and which gets there *second* (which is the the user will see barring some flicker) is effectively random. On Sat, Nov 13, 2010 at 7:46 AM, mohammad Rukab mohammad.ru...@gmail.comwrote: Hello , i have problem when i start activity from incoming call broadcastReciever, the problem is : when call is coming i start activity X with FLAG_ACTIVITY_NEW_TASK flag, and it is work fine when my application is not on the screen. but if my application on the screen (activity Y) and call come, when activity X called from braodcastReciver Activity Y cover screen over incoming call screen then Actvity X display, so 2 activity become over incoming call, although i just want activity X just display. Please an body have 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.comandroid-developers%2Bunsubs cr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Updating the Call Log.
Hello. I'm trying to update the CalLog to change the name/cached name of an entry. I have successfully updated a row but once i go into the call log on my phone the displayed name is removed after a short moment. I figured this is because the number of the incoming called is not found in any of the contacts. But why would it then clear the cached name that is in the Log? If the number is not in contacts the call log should display the cached name without trying to refresh it? Atleast that's the behaviour I expect. So, my question is: Is it possible to add a name to an incoming number to display in the call log without adding the number and name to the contact list? I've figured it should be possible to add the contact first, then mark it as removed and thus get it displayed in the call log but that seems like a stupid work-around. // Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 take an image using ACTION_IMAGE_CAPTURE, and not having it appear in the gallery
Hi all I am writing an application that uses the built-in camera activity for taking pictures and sending them to a server along with some other data. Since our users will use this application in their jobs, I would like the images taken, not to be available in the general gallery on the phone. I have tried some different approaches, with my currently implemented solution is this: Start the camera application using MediaStore.ACTION_IMAGE_CAPTURE intent, and EXTRA_OUTPUT pointing to a an Uri on the SD card. The following code is used: imageUri = Uri.fromFile(new File(FotoDok.EXTERNALIMAGEDIR, UUID.randomUUID() + .jpg)); Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); intent.putExtra(MediaStore.EXTRA_OUTPUT, imageUri); intent.putExtra(MediaStore.EXTRA_VIDEO_QUALITY, 1); startActivityForResult(intent, CAPTURE_IMAGE_ACTIVITY_REQUEST_CODE); In the folder the FotoDok.EXTERNALIMAGEDIR is pointing at, I have placed a .nomedia file to disable media indexing. The folder is placed at the sd card under Android/data/myPackage/images. But the problem is that when using DDMS I can see that the camera application leaves an identical image under e.g. sdcard/DCIM/100MEDIA/IAMGE0283.jpg And this image shows up in the gallery. Are there any way to avoid images taken with the built-in camera application showing up in the gallery. And here I would prefer a general solution that works both on SE, HTC, Google, etc, devices. I hope somebody out there have a solution for this. Best regards /Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Service start intent problem
I've done some more investigations, and it seems like the random FCs never happens when the activity starts the service. It's rather the system that sometime feels like starting the serviceand when this happens, the intent is null. My solution for this problem right now is just to swallow that NPEand that feels like a really good solution.. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Service start intent problem
Hi, I got the same issue, here's my code snapshot: (code from the Activity that starts the Service...) Bundle bundle = new Bundle(); bundle.putString(key1, val1); bundle.putString(key2, val2); Intent intent = new Intent(TheActivity.this, TheService.class); intent.putExtras(bundle); startService(intent); (code that throws random NPE in Service class) @Override public void onStart(Intent intent, int startId) { super.onStart(intent, startId); bundle = intent.getExtras(); // throws random NPE } I've never received the NPE on my HTC Hero with Android 2.1 update1, but I've got 16 crash reports in the Developer Console, 10 from OTHERS, 3 from Nexus One and 3 from Droid. What is happening here? Anders On Aug 12, 3:35 am, Alex Xin xinxi...@gmail.com wrote: Hi, Frank I can give it a try. Above code snapshot works perfect and on my Android 1.6 based phone, but random FC on Nexus One. Alex On Thu, Aug 12, 2010 at 9:26 AM, Frank Weiss fewe...@gmail.com wrote: Does it FC when you use getIntent() instead of the parameter to onStart? -- You received this message because you are subscribed to the Google Groups Android Developers group. 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
[android-developers] Re: Service start intent problem
Hi, I've got the same issue, here's my code snapshot: (code from the Activity that starts the service) Bundle bundle = new Bundle(); bundle.putString(key1, val1); bundle.putString(key2, val2); Intent intent = new Intent(TheActivity.this, TheService.class); intent.putExtras(bundle); startService(intent); (code from the service that throws the random NPE) @Override public void onStart(Intent intent, int startId) { super.onStart(intent, startId); bundle = intent.getExtras(); // throws random NPE } I've never gotten the NPE on my HTC Hero with Android 2.1 update1, but I've received 13 crash reports in Market Developer Console, 10 from OTHERS, 3 from Nexus One and 3 from Droid. What is going on here? //Anders On Aug 12, 3:35 am, Alex Xin xinxi...@gmail.com wrote: Hi, Frank I can give it a try. Above code snapshot works perfect and on my Android 1.6 based phone, but random FC on Nexus One. Alex On Thu, Aug 12, 2010 at 9:26 AM, Frank Weiss fewe...@gmail.com wrote: Does it FC when you use getIntent() instead of the parameter to onStart? -- You received this message because you are subscribed to the Google Groups Android Developers group. 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
RE: [android-developers] Re: Bounce animation
Bouncing as you describe it is not supported in ListView. It is possible to lift the ListView class from the platform and modify it to support it (most of the necessary changes are in AbsListView btw), but I don't recommend that approach. Instead, I would recommend that you implement your own list view. I've made a tutorial for how to make a custom list view (which has support for bounce) which is available here: http://blogs.sonyericsson.com/developerworld/category/tutorials/3d-list/ If you're not interested in changing appearance, you can probably skip part 2. Good luck /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Sandy Sent: den 13 juli 2010 17:38 To: Android Developers Subject: [android-developers] Re: Bounce animation Can someone please comment on this? Also, when height of one vertical list item is increased, it should result in the slide animation of the rest of the items in the list view (basically other items should slide down). I have noticed that list view does not support this, but any other suggestions on what is the best approach to achieve this? Thanks, Sandy On Jul 12, 5:38 pm, Sandy snarr...@gmail.com wrote: I've noticed that in froyo on nexus 1, app menu thumbnail list can be scrolled up and down and, as it's scrolled, the applications roll up into a 3D cube instead of disappearing from the screen. Once the bottom of the application thumbnail list is hit, the screen bounces off similar to the iPhone functionality. Is the bounce effect at the boundaries of the list available on a vertical ListView? If not, is it easy to customize this in on vertical lists? Thanks, Sandy -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Scrolling ListView manually by pixels
Hi, You can inject motion events to your ListView that corresponds to a 10 pixel drag. Create an ACTION_DOWN event and then an ACTION_UP event 10 pixels apart and then send them to the ListView using onTouchEvent(). You might need to have a ACTION_MOVE event as well. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of yuku Sent: den 14 juli 2010 08:12 To: Android Developers Subject: [android-developers] Scrolling ListView manually by pixels Hi, I want to make use of the trackball or d-pad to scroll my ListView smoothly. Without implementing anything, by default the list scrolls by one item, which is not appropriate for my app, since list items have different heights and I just want to scroll it by a fixed amount. Is there anything to call to let's say, emulate a 10 pixel drag down? Thanks. Yuku -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] AndroidGroup: Nested Actvities
Hi! I'm trying to create an application with an persistent menu at the bottom for displaying different Activites. Think of it like a custom tabbed layout. I need the applications to be stand alone so using views won't work (unless I've missed something). I've created a main window using a FrameLayout and a Linearlayout to hold menu items. But whenever I start an Activity inside the FrameLayout it takes all the focus and no interaction can be done with the items inside the LinearLayout. Any suggestions on how to accomplish this type of behavior? CODE: http://pastebin.com/nySA8k4A -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Any chance to deactivate the lock pattern in Froyo from code?
This is insane.. for Android not to support a security delay is just beyond words. As a private user I do not want to enter my security code any time I unlock my phone. I do on the other hand want security. Every smartphone I've used had an option to delay security for 5min to a couple of hours. On my last phone (iPhone) this was covered in the OS. Moving to Android the app provided by lars in this thread took care of that for me up until FroYo was released. Due to the annoyance of entering password on every unlock, I now run unsecured. This does not make me feel too god about neither froyo or Android in general, but at least it makes it easy to pick up my phone for a little play. Google need to address this issue ASAP! I'm sure there are loads of people running unsecured atm due to this particular issue of not being able to delay security for at least a few min.. Hopefully this will be solved either through Google or through some dev utilizing root privilege and some hacks. Shame if we have to sort to the last option to get a functioning security on our phone. -Anders On Jun 30, 6:29 pm, Dianne Hackborn hack...@android.com wrote: No we already have a feature request for this in our internal tracker. I currently don't have a schedule for when it might be done. On Wed, Jun 30, 2010 at 5:20 AM, LeveloKment levelokm...@googlemail.comwrote: I know ;) But this does not mean that the next Android version(s) will have to lack this balance as well ;) Should I open a feature request for this? Or will you :P Thanks for your attention Dianne Bye Lars On 30 Jun., 10:16, Dianne Hackborn hack...@android.com wrote: Sorry we currently don't support this. On Tue, Jun 29, 2010 at 11:37 PM, LeveloKment levelokm...@googlemail.comwrote: Hi again Dianne. ;) Ok, lets keep the DeviceAdmin out off the topic for now. From what you have described it seems to be for corporate use mainly. The problem I've tried to fix with my app PatternControl was the following: People (private Android users) are aware that they have stored a lot of sensible data on the smartphones, because of this some of them would like to protect this information a little bit better... this is where the Lock Pattern of Android (or with Froyo also the Pin or Password) comes into the game. All the basic lock features that Android provides to the users have one disadvantage... Ones enabled, they always on. Each time you want to use your phone you have to deal with the lock (pattern, pin or password). For private users this is often a bit to much and in the end they deactivate the security pattern again. What is missing from my point of view (and most likely the point of view from thousands of users of apps like PatternControl, AutoLock etc.), is an option like Enable the lock only if I didn't used the phone for xxx minutes. Best regards Lars On 29 Jun., 19:15, Dianne Hackborn hack...@android.com wrote: On Tue, Jun 29, 2010 at 4:53 AM, LeveloKment levelokm...@googlemail.com wrote: If I understand you right, than the only option to provide more flexibility to the users is still an option in Android itself. The DeviceManager can then disallow such temporary lowering of the lock level. Sorry I am not understanding that paragraph. From my point of view an always on security feature will often be disabled (at least by private users). This lowers the security even if the origin intention was the other way around. Not sure I see the connection here... the API to disable the lock screen is not supported when a device admin is requiring a lock screen, in which case there is no way for the user to go around this except to disable that device admin, and thus lose all access to whatever corp server the admin is associated with. And if their preference is to be able to not have a lock screen at the expense of not having their corp server access... well, that is fine for all. -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.comandroid-developers%2Bunsubs cr...@googlegroups.com android-developers%2bunsubscr...@googlegroups.comandroid-developers%252Bu nsubscr...@googlegroups.com For more options, visit
[android-developers] VideoView black after activity switch
Hi all, I've got a problem with VideoView that I would love some input on. The setup is basically an activity that starts by launching the gallery with the intent of opening a video. Once that returns, the activity displays a contentview consisting of some views. Acting upon one of the views will set the currently visible controls to gone and make a VideoView visible, which plays the video, and once that is done it returns to the previous state by setting the VideoView to gone and vice versa. This all works fine, and I can switch between the control mode and play mode ad infinitum, however going back one more step, thus switching activities to the gallery and selecting a new (or the same) video file and then repeating the steps mentioned above results in the video playing back only sound, without picture (the VideoView area of the screen remains black). The instances of both the container and VideoView are the same before and after the activity switch, I have tried playing around with Z order, bringing the video view to front, unfreezing the underlying surface and a lot of other things I can't remember off the top of my head, but without success... Any ideas? Best Regards Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Carousel like Gallery.
I don't think that is possible. You probably need to write your own gallery like view to do that. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of RANJAN BANIK Sent: den 23 juni 2010 17:05 To: Android Developers Subject: [android-developers] Re: Carousel like Gallery. Please, answer please Ranjan On May 7, 1:57 am, Abdul Mateen abmat...@gmail.com wrote: Hi, Any body knows how to make a gallery circular and behave like carousel in Android ? -- -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] How to launch browser from wallpaper?
Hi, Doing Activity activity = new Activity() is probably not a good idea. instead, get the application context from the wallpaper: getApplicationContext().startActivity(i); That will probably work better. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Stu.Axon Sent: den 17 juni 2010 11:30 To: Android Developers Subject: [android-developers] How to launch browser from wallpaper? I'm trying to launch the browser from a wallpaper, but I get a NullpointerException... code looks like this: Intent i = new Intent(); i.setAction(Intent.ACTION_VIEW); i.addCategory(Intent.CATEGORY_BROWSABLE); i.setData(Uri.parse(http://google.com;)); Activity activity = new Activity(); activity.startActivity(i); -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Dynamically obtaining several instance of a view item defined in layout/xml file
Hi, Just inflate from the xml each time you want a new instance of that particular view. Like this: View innerRL = LayoutInflater.from(context).inflate(R.layout.inner_view, null); /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of krishna Sent: den 8 juni 2010 02:37 To: Android Developers Subject: [android-developers] Dynamically obtaining several instance of a view item defined in layout/xml file I have a relative layout (let's say innerRL place in layout inner_view.xml) which I wanna add to another layout (main_layout), I wanna dynamically add multiple instances of innerRL. Specifying innerRL in xml gives me ease of maintenance (as against doing totally in the code), however I want to be able to add several instances dynamically. Using findViewById(resource_id) gives me that particular instance, should I have to use clone()? One other approach I see is ArrayAdapter, but it seems overkill. -Krishna -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Placing a bitmap image in ImageView
Sounds like you want to change the scale type on the image view. http://developer.android.com/reference/android/widget/ImageView.ScaleType.html /Anders -- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of pawan nimje Sent: den 9 juni 2010 19:39 To: Android Developers Subject: [android-developers] Placing a bitmap image in ImageView Hi All, I have a Bitmap image (bm) and a an ImageView (iv) of 50 by 50 when i do iv.setImageBitmap(bm) ... only a portion of the entire image is seen ..How can i see the whole image in the 50 dip by 50 dip ImageView .. any suggestion will do .. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 Android's onTouchEvent() dispatching accurate??
I would say that this is normal behavior. The up-event can definitely have (and often has) another coordinate than the last move-event. But I don't think it has anything to do with inaccuracy in the touch event handling, it's simply the way it works... /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Peterdk Sent: den 6 juni 2010 17:30 To: Android Developers Subject: [android-developers] Is Android's onTouchEvent() dispatching accurate?? I have a weird bug in my piano app. Sometimes keys (and thus notes) hang. I did a lot of debugging and narrowed it down to what looks like androids inaccuracy of motion event handling: DEBUG/(2091): ACTION_DOWN A4 DEBUG/(2091): KeyDown: A4 DEBUG/(2091): ACTION_MOVE A4 = A4 DEBUG/(2091): ACTION_MOVE ignoring since equal note DEBUG/(2091): ACTION_MOVE A4 = A4 DEBUG/(2091): ACTION_MOVE ignoring since equal note DEBUG/(2091): ACTION_MOVE A4 = A4 DEBUG/(2091): ACTION_MOVE ignoring since equal note DEBUG/(2091): ACTION_UP B4 //HOW CAN THIS BE DEBUG/(2091): KeyUp: B4 DEBUG/(2091): Stream is null, can't stop DEBUG/(2091): Hanging Note: A4 X=240-287 EventX=292 Y=117-200 EventY=164 DEBUG/(2091): KeyUp Note: B4 X=288-335 EventX=292 Y=117-200 EventY=164 Clearly it can be seen here that out of nowhere I suddenly have an ACTION_UP for another note. Shouldn't I definitely get a ACTION_MOVE first? As shown in the end of the log, it's definitely not an error in region detection, since the ACTION_UP event is clearly in the B4 region. Every onTouchEvent() call is logged, so the log is accurate. The relevant pseudo-code for the ACTION_MOVE logging is: Key oldKey = Key.get(event.getHistoricalX(), event.getHistoricalY()); Key newKey = Key.get(event.getX(), event.getY()); Is this normal behaviour for Android (the jumping in coordinates)?? Can ACTION_UP events just arise without any previous ACTION_MOVE towards it coordinates?? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Re: Android graphical capabilities
Yeah, it's the dynamics that really give it a nice feel. And a touch-list without fling support is not useful at all... Though the third part of the tutorial is not quite ready yet. It will probably be posted in about a week on the blog. Untill then I suggest playing around with the graphics :) BTW, if you (or anyone else) have any ideas or requests for other tutorials, let me know! We are planning to continue with tutorials and it would be great if you had any input. No promises though :) /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Neilz Sent: den 3 juni 2010 20:16 To: Android Developers Subject: [android-developers] Re: Android graphical capabilities Hi Anders. Do you have the code for part 3 available? The first two are great, but really it's not so great without the finishing touches from part 3! On Jun 3, 2:18 pm, Ericson, Anders anders.eric...@sonyericsson.com wrote: The reference app on market has minSdkVersion set to 4 (=1.6) and the main reason is to enable the support for different screen sizes (mdpi, ldpi, hdpi). The code itself has very little (if any) dependencies to 1.6 specific APIs. You can always download the code and just rename the directories for the drawables, that should be enough to get it to work on a 1.5 device. We'll look into supporting 1.5 for the reference app as well. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Neilz Sent: den 3 juni 2010 14:21 To: Android Developers Subject: [android-developers] Re: Android graphical capabilities Hi Anders. Thanks for these, they look great, just the sort of thing I'm after. I notice that it isn't available for my older Hero with 1.5. Is this not compatible with 1.5? How would you resolve that if you wanted your app to reach all devices? On Jun 3, 11:37 am, Ericson, Anders anders.eric...@sonyericsson.com wrote: Hi, I recently wrote a tutorial on how to do a cool 3D list. You can find the latest part on: http://blogs.sonyericsson.com/developerworld/category/tutorials/ There you can also find a tutorial on how to do a cool zoom written by a colleague of mine. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Neilz Sent: den 3 juni 2010 10:38 To: Android Developers Subject: [android-developers] Android graphical capabilities My apps are functionally good, and in my time learning android I have covered most features. But one thing my apps lack is graphical coolness... you know the type of thing the top branded apps have, and particularly those from the iPhone which are always very impressive. I want to improve my graphical skills for layouts, menus, galleries, interactive buttons - the kind of stuff that makes your apps look great, as well as performing well. What should I look at? Where should I start? Any links, tips, welcome! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Set wallpaper as background
Hi, In your AndroidManifest.xml you can add this to your activity: android:theme=@android:style/Theme.Wallpaper /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of AndroidNewbie Sent: den 3 juni 2010 05:49 To: Android Developers Subject: [android-developers] Set wallpaper as background Hi , I want to set current wallpaper as my application background . Any ideas to do it through XML or Java 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Android graphical capabilities
Hi, I recently wrote a tutorial on how to do a cool 3D list. You can find the latest part on: http://blogs.sonyericsson.com/developerworld/category/tutorials/ There you can also find a tutorial on how to do a cool zoom written by a colleague of mine. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Neilz Sent: den 3 juni 2010 10:38 To: Android Developers Subject: [android-developers] Android graphical capabilities My apps are functionally good, and in my time learning android I have covered most features. But one thing my apps lack is graphical coolness... you know the type of thing the top branded apps have, and particularly those from the iPhone which are always very impressive. I want to improve my graphical skills for layouts, menus, galleries, interactive buttons - the kind of stuff that makes your apps look great, as well as performing well. What should I look at? Where should I start? Any links, tips, welcome! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Re: Android graphical capabilities
The reference app on market has minSdkVersion set to 4 (=1.6) and the main reason is to enable the support for different screen sizes (mdpi, ldpi, hdpi). The code itself has very little (if any) dependencies to 1.6 specific APIs. You can always download the code and just rename the directories for the drawables, that should be enough to get it to work on a 1.5 device. We'll look into supporting 1.5 for the reference app as well. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Neilz Sent: den 3 juni 2010 14:21 To: Android Developers Subject: [android-developers] Re: Android graphical capabilities Hi Anders. Thanks for these, they look great, just the sort of thing I'm after. I notice that it isn't available for my older Hero with 1.5. Is this not compatible with 1.5? How would you resolve that if you wanted your app to reach all devices? On Jun 3, 11:37 am, Ericson, Anders anders.eric...@sonyericsson.com wrote: Hi, I recently wrote a tutorial on how to do a cool 3D list. You can find the latest part on: http://blogs.sonyericsson.com/developerworld/category/tutorials/ There you can also find a tutorial on how to do a cool zoom written by a colleague of mine. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Neilz Sent: den 3 juni 2010 10:38 To: Android Developers Subject: [android-developers] Android graphical capabilities My apps are functionally good, and in my time learning android I have covered most features. But one thing my apps lack is graphical coolness... you know the type of thing the top branded apps have, and particularly those from the iPhone which are always very impressive. I want to improve my graphical skills for layouts, menus, galleries, interactive buttons - the kind of stuff that makes your apps look great, as well as performing well. What should I look at? Where should I start? Any links, tips, welcome! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email 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 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] how to enable onItemClick for custom list view
Hi, The way it works is that if your list item (or a part of your list item) is clickable (like the button) it will steal the touch event from the ListView, so the ListView will not be able to call onItemClick(). One way to solve it is to set a click listener to the button in each item view. This can be done from the adaptor. Though you need to make sure you don't leak listeners. You can for example set the same listener to all items and figure out exactly what item was pressed by tagging the item-views with the position, and then checking the tag in the onClick() callback. /Anders -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of prachi Sent: den 3 juni 2010 15:58 To: Android Developers Subject: [android-developers] how to enable onItemClick for custom list view Hey hiii all I hav a list view,each list item has a text view and a button. My onItemClick() for list item is not responding.But if i remove the button from list item it is responding.. Pl helppp bcoz i want both to function :(:(:( Any help would be appreciated:):):) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] sendWallpaperCommand() behavior changed in 2.2
Hi, Why should only the Home application send commands to the wallpaper? Shouldn't any application that displays the wallpaper as background be able to send commands? Also, the documentation for WallpaperManager.sendWallpaperCommand() is a bit unclear. The documentation for the parameter windowToken says he window who these offsets should be associated with, as returned by View.getWindowToken().. What offsets are referred to here? I can understand the same documentation in setWallpaperOfffsets() or clearWallpaperOffsets, but not in sendWallpapperCommand(). /Anders Ericson -Original Message- From: android-developers@googlegroups.com [mailto:android-develop...@googlegroups.com] On Behalf Of Romain Guy Sent: den 1 juni 2010 11:49 To: android-developers@googlegroups.com Subject: Re: [android-developers] sendWallpaperCommand() behavior changed in 2.2 Hi, From where are you sending a command? Commands are supposed to be sent by the Home application. In which case you have views and you can get the window token from any of these views. On Tue, Jun 1, 2010 at 2:44 AM, String sterling.ud...@googlemail.com wrote: I'm seeing a bothersome change in behavior of the live wallpaper SDK in Android 2.2. Specifically, it's the windowToken parameter to WallpaperManager.sendWallpaperCommand(); in the docs it's described as The window who these offsets should be associated with, as returned by View.getWindowToken(). Which sounds fine, but if the live wallpaper I'm trying to send a command to is the main one - on the home screen - what view should this be? In 2.1, I could send a null for this parameter, and it worked fine - my live wallpaper got the command. In 2.2, the null produces a crash by the system. Here's a logcat trace, FWIW: E/WindowManager( 85): Window Session Crash E/WindowManager( 85): java.lang.IllegalArgumentException: Requested window null does not exist E/WindowManager( 85): at com.android.server.WindowManagerService.windowForClientLocked(WindowManagerService.java: 9244) E/WindowManager( 85): at com.android.server.WindowManagerService $Session.sendWallpaperCommand(WindowManagerService.java:6827) E/WindowManager( 85): at android.view.IWindowSession $Stub.onTransact(IWindowSession.java:345) E/WindowManager( 85): at com.android.server.WindowManagerService $Session.onTransact(WindowManagerService.java:6694) E/WindowManager( 85): at android.os.Binder.execTransact(Binder.java:288) E/WindowManager( 85): at dalvik.system.NativeStart.run(Native Method) Fortunately, this crash is invisible to the user, but that's small consolation as the command never reaches my wallpaper. Has anyone worked out how to get a window token for the home screen? Or any other way around this? Or any other way to send a message to the currently running live wallpaper? Thanks, 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 -- Romain Guy Android framework engineer romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Can not create service interface
Hi, For some reason I can not create an AIDL service interface, no matter how simple it is. I am using the latest version of eclipse. This is what I get, no matter what service functions I add to the aidl file: The method attachInterface(IInterface, String) in the type Binder is not applicable for the arguments (MyServiceInterface.Stub, String) MyServiceInterface.java The generated file MyServiceInterface.java, contains numerous errors. Among them is testapp.test.net cannot be resolved to a type. Very strange, since eclipse can do this for everything else. I have other projects in my workspace where I use AIDL successfully, but now I can not add this to any project. Very strange. If remove the aidl file, I can compile and run the app without any problem. Anyone that have any idea what is going on here? Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Start another application from another package with an Intent
I know how to update my own programs, and I know how to open programs using the a predefined Uri (for sms or email for example) I need to know how I can create an Intent to open MyTracks or any other application that I don't know what intents they listen to. I got this info from DDMS, but I havn't been succesful in turning this to an Intent I can use. This is taken from when opening MyTracks manually. Thanks for your help 05-06 11:22:24.945: INFO/ActivityManager(76): Starting activity: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x1020 cmp=com.google.android.maps.mytracks/ com.google.android.apps.mytracks.MyTracks bnds=[243,338][317,417] } 05-06 11:22:25.005: INFO/ActivityManager(76): Start proc com.google.android.maps.mytracks for activity com.google.android.maps.mytracks/ com.google.android.apps.mytracks.MyTracks: pid=1176 uid=10063 gids={3003, 1015} 05-06 11:22:26.995: INFO/ActivityManager(76): Displayed activity com.google.android.maps.mytracks/ com.google.android.apps.mytracks.MyTracks: 1996 ms (total 1996 ms) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Getting information from webview
This seams like a security issue, so I don't think it's made easy if it's possible at all. Ideas: There's something called formData that maybe can be used. You could also read the onScreen keyboard, but that requires a special permission. On 6 Maj, 14:37, absn amitbm...@gmail.com wrote: Hi, I am developing a flickr application, in that for sign-in purpose I m creating a login link(url) and loading this url using webView.loadUrl(url); and it redirects us to the flickr sign-in page. this page contains two edittext one for yahoo id and other for password, when user submit this information and click on sign-in button , on this click event i want to fetch those entered value for username and password . is it possible ?? On May 5, 4:45 pm, prachi prachi.tya...@wipro.com wrote: hiii Yeah it can be done..If that edit text is inside your webview--- Inside the layout file give ur edittext and button inside the webview tag and in your program refer to that editText by its id given in xml file. Let me know if this is wat u want??? On May 5, 11:44 am, absn amitbm...@gmail.com wrote: Hi all, I want to get the edittext value from webview(i.e My webview contains the edittext for username), Can anybody help me how to retrive them after clicking on some button of webview. 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 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-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 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
[android-developers] Re: How to upgrade my Android dev Phone 1 to 2.x release?
how? any good links to a how-to that works and is up to date? On Mar 27, 10:24 pm, russ.a.mor...@gmail.com wrote: Yes I believe you can. Sent from my BlackBerry® device from Digicel -Original Message- From: Joe droidvi...@gmail.com Date: Sat, 27 Mar 2010 13:19:01 To: Android Developersandroid-developers@googlegroups.com Subject: [android-developers] How to upgrade my Android dev Phone 1 to 2.x release? Is it possible to upgrade Android dev phone (the first version) to latest release (either 2.0 or 2.1)? I appreciate if you can point me right links. Thanks Joe -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group athttp://groups.google.com/group/android-developers?hl=en To unsubscribe from this group, send email to android-developers+unsubscribegooglegroups.com or reply to this email with the words 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: webview touch problem
I found the same behavior when using an onTouchListener and then sending the events to a gestureDetector detecting single/double tap. Sometimes the javaScript would hang and not execute, I would love a more detailed answer on why this problems occur if we could get some dev. love :) On 27 Apr, 11:02, Kumar Bibek coomar@gmail.com wrote: This is indeed an issue I guess. Well, let me re-frame the problem. Say, you have a long page which you load on theWebView. Now you start scrolling. Before the scrolling stops, tap on the web view, and the scrolling will stop automatically. After this point, try to execute some JS code from outside, ie, without touching theWebViewagain. May be through a normal button, or a manu time. At this point, the JS is not called. But, now when youtouchthe web view again, and may be do a bit of scrolling, and try to execute the same JS, it works. I guess, the web view in this case, is not in a state to execute JS code. Is it a bug? Thanks and Regards, Kumar Bibek On Apr 27, 11:27 am, Maps.Huge.Info (Maps API Guru) cor...@gmail.com wrote: It's hard to tell if and where a mistake may have been made without seeing your html... Are you usingtouchor click events? -John Coryat Radar Now! What Zip 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 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
[android-developers] Re: SPP bluetooth
Not true. HTC phones for example have a different BT implementation than that one of the N1. I havn't pinpointed it yet, but things works differently. They should be the same, cause they're running 2.1 but they're not. Information is hard to come by, but the N1 has the best BT as far as I know. On 5 Apr, 20:31, DonFrench dcfre...@gmail.com wrote: Not sure why you say not Android. Android has supported SPPBluetooth since API level 5 (Android 2.0). Check out the BluetoothChat example. You might need to change the UUID to 1101--1000-8000-00805F9B34FB but otherwise it works fine. On Apr 3, 4:36 am, Holston holsto...@googlemail.com wrote: I have been DYING for a smartphone which officially supportsBluetooth keyboard pairing. To the point of now trolling developer forums to find out which major phone O.S. will officially support this first (not iPhone. not Android. not WebOS. Blackberry Symbian idk). I've been holding off a purchase for over a year because of this. How sad is that? So, um ... Android full and officialBluetoothHID SPP support: 1 more year? 2? 5? ...ever? Please give me some hope here ;-( On Apr 2, 5:01 pm, Bill Michaelson wmmichael...@gmail.com wrote: There is an app called KeyPro which does this, but last I knew, it did not support the ctl key, which is problematic for some apps (like Connectbot). You might contact the developer about latest status. On Apr 2, 1:26 am, brilliant winger stw...@gmail.com wrote: I would like to use SPPbluetoothkeyboard(not HID profile.) on my android. but android 2.1 is not supported SPPbluetooth. Um Someone communicated the SPP device using android RFCOMM. Is this possible?- Hide quoted text - - Show quoted text - -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: 2.1 Bluetooth support still needs work
I can connect to my PC and send and receive messages using SPP and a terminal program. But restarting doesn't work and the connect doesn't always work either: 1. Restarting (connecting) the program doesn't work without restarting BT (Closing BTStack fails somewhere) 2. Sometimes when connecting, phone reads strings of length -1 and loops a lot of output at Logcat about this. 3. When trying to connect to a bonded device the device name shows up as null. (After a restart of the program, guess it's related to 1.) Anyone solved this issues? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] 2.1 Bluetooth support still needs work
Hi! I've been working with bluetooth trying figure things out using the BTChatExample. Without editing BTChat has errors that destroy the functionality. You can only connect the first time, if you connect. Close the program and doesn't restart bluetooth the program crashes. Even if you edit out the AccepThread and only focus on client connect, the program will cast exceptions. JBtlSpp.create failed with status FAILED when trying to connect. I've looked into the code and referenced it with the docs (that are based around the ChatExample) and either bluetooth still needs work or there something missing in the APIs. I would love to hear from other people trying to use Bluetooth on Android 2.0++, or try to get a hold of a framework developer to try to iron out these that I believe are in the framework itself. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: USB drivers for HTC Legend ? (or, how to add your own to android_winusb.inf )
I need the same thing, how do I modify the drivers to work with Legend. I really need the hardware support to do Bluetooth. On 10 Apr, 13:31, ThomasWrobel darkfl...@gmail.com wrote: Just got a HTC Legend and am very keen to get into Android development (having previously been expirenced with eclipse/java/gwt). However, the USB ADB driver on the SDK doesnt support it, so I wondered how I could add it myself. I feebly tried adding; ; HTC Legend %SingleAdbInterface% = USB_Install, USB\VID_0BB4PID_0C01 %CompositeAdbInterface% = USB_Install, USB\VID_0BB4PID_0C97MI_01 %SingleBootLoaderInterface% = USB_Install, USB\VID_0BB4PID_0FFF to the inf file. But it didnt help. (mainly because I have no clue what I was doing) Any help to get my Legend working as a debug device would be most appriciated! :) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Databases and Activity life-cycle
Hi! I've been a long time reader, and I've had problems with handling databases (open, close, create adapter) within an Activity I think I've figured out the best way to do it so I wanted to share, by writing a small blog post to easily handle code. I would love to hear your thoughts and solutions on the subject. http://awiden.wordpress.com/2010/03/26/database-mangement-and-the-activity-lifecycle/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 from this group, send email to android-developers+unsubscribegooglegroups.com or reply to this email with the words REMOVE ME as the subject.
[android-developers] Databases and Activity life-cycle (OnCreate -- onResume)
Hi! How to best handle databases during the Activity life-cyle? My example: 1. When I start the Activity I want to open the database so I create a new dbAdapter and open it. 2. onCreate calls populateFields and data is read from the database I just opened. The database remains opened because other functions in the Activity needs the database. 3. the Activity gets Paused so I want to close my open database to release resources : onPause -- dbAdapter.close() 4. the Activity gets Resumed so I need to open the database again: onResume -- dbAdapter.open() The problem: This will create two open instances of the database. When the Activity starts the first time after onCreate has finished onResume will be called (see: http://developer.android.com/intl/fr/images/activity_lifecycle.png). What's best practise to solve this? This error of handling databases is also present in the Notepad Tutorial. //Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 from this group, send email to android-developers+unsubscribegooglegroups.com or reply to this email with the words REMOVE ME as the subject.
[android-developers] Re: Recommendations for split app (eg free/pro versions using 95% the same code)
Personally I'd use a version control system with branches to do this. And keep it in one project. Doing it with branches you could easily merge changes that go in both versions, and just do a refresh in eclipse when doing development on the other version. On Mar 11, 10:51 pm, Matt (preinvent) m...@preinvent.com wrote: I have a free app out there and am going to write a pro version with some extra functionality that I'll charge for. The plan is to use the same code for both apps, although I need different Eclipse projects to use different manfiest files. The obvious way is to have all my code in a shared library which the free and pro projects reference. Is there a recommended way of doing this? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Race condition using handler + thread.
Hi I have an application that starts a background thread to load data. It uses Handler to pass data back to the main thread. Now this works perfectly most of the time, but not when I switch orientation. What I found was this behavior: - onCreate : Start main view, with background load thread - Switch android direction - onStop : Kill background loading thread, does thread.interrupt + thread.join. - onCreate - Data queue'd in the handler is still being pushed through from the previous data load. This produces a bit of a race condition for me. I can shutdown the thread cleanly, but the data that's in the handler, between the thread and the main view isn't always cleared. This would be solvable with something like: thread.interrupt(); thread.join(); handler.clear(); Before returning to the onStop function, but there's no .clear to just empty a handler out. How can I clear a Handler of all messages? I use this for posting: handler.post(new Runnable() { @Override public void run() { handler.onData(sendData); } }); So doing a .removecallback (which requires me to store runnables) isn't real practical. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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
I tried registering and got a blank page, who do we talk to about that? How do we know that the registration has gone through? Is there a confirmation page or something like that? On Mar 3, 1:46 am, Roman Nurik romannu...@google.com wrote: Folks, the email is NOT a fake. We will look into the email issues. Roman Nurik Android Developer Relations, Google NOTE: please do not send me email directly about this. On Mar 2, 4:43 pm, Mark Anacker closecr...@gmail.com wrote: Well, if nothing else, Google should now be on the lookout for potential fraudulent activity involving developer account and order numbers. Especially originating out of China :-) Although it would be nice to think that they would have someone in a Security role who could jump on this sort of thing, and provide some official information. But their warehouses full of geniuses are probably much too busy for such trivial matters... :-) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Trouble: Windows XP detecting Nexus One by USB
i have the exact same problem, windows xp 64bit latest drivers, device is shown under safely remove hardware as a ADB interface but running adb devices does not show it On Feb 21, 2:12 pm, Joerg Pleumann joerg.pleum...@gmail.com wrote: Same problem here. XP32 SP3. Here's what I did/see: - I took same care to make sure no instances of older driver files were on my computer. - I then manually installed the new R3 driver that was downloaded by the SDK Manager. - I plugged in both my ADP1 and myNexusOne. Both have USB Debugging enabled. - In theWindowsDevice Manager I see 2 x Android Composite ADB interface - adb shell lists the ADP1, but not theNexusOne. - When mounting the SD card, I can see files on the ADP1, but not on theNexusOne. On Feb 11, 7:31 pm, DonFrench dcfre...@gmail.com wrote: Are you by any chance usingXP-64? If there is a way to make the phone visible on that platform I haven't found it but I have no problems onWindows7. On Feb 10, 7:10 pm, Coltin ultran...@gmail.com wrote: 'adb devices' returns 'List of devices attached' followed by nothing, and eclipse doesn't pick up myNexusOne. I've installed the drivers for 'Android Composite ADB Interface'. I've set myNexusOneto 'Development:USBdebugging'. I've connected the device to my computer. It's listed under the 'Safely removed' devices interface, but still nothing. Am I missing something? I used this to set up theUSBdriver:http://d.android.com/sdk/win-usb.html And I followed instructions here:http://d.android.com/guide/developing/device.html I can access the SD Card easily enough, but I'm looking to test my app with eclipse. I've been looking for an answer for a couple of hours, but I haven't had any luck. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: adb doesn't see Nexus on XP-64
I am having the exact same problem on XP 64, cant find any solution On Jan 27, 9:29 am, DonFrench dcfre...@gmail.com wrote: No one has any thoughts on this? Anyone else using XP-64 for Android development? On Jan 25, 10:06 pm, DonFrench dcfre...@gmail.com wrote: I can't get adb to see my Nexus on XP-64. That is, when I run adb devices it lists only the open emulators and not the Nexus. Likewise, Eclipse does not show the Nexus as an available deployment target. Yes, I have the latest USB driver for Nexus. The driver appears to have installed correctly. The device manager shows Android phone Composite Android Interface, as expected. And yes, USB debugging is turned on on the Nexus. My Windows 7 Netbook does not have this problem but I need to use the XP-64 system for development. Please help if you know the solution to this problem. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: OpenGL ES 2.0 on Eclair
Hi, I also would like to bump this topic. - I guess that OpenGL ES 2.0 API will be defined in Java layer as android.opengl.GLES20 class. - We have been able to use OpenGL ES 2.0 API through hardware bindings using JNI. However in my understanding, it is impossible to use OpenGL ES 2.0 API with software rendering on emulator. When does Android plan to support software rendering for OpenGL ES 2.0 API? Regards, /David On 1月6日, 午前10:08, r2d2Proton r2d2pro...@live.com wrote: I would like to bump this. . . I was thinking the same thing - use the NDK to gain access to the 2.0 functions. I imagine that the OpenGL ES 2.0 functions are exposed in Imagination Technologies shared object file. Games should be considered an NDK level application. Wasn't anybody watching Microsoft when they tried this? Remember Direct-Draw? On Dec 28 2009, 11:10 am, rollbak roll...@gmail.com wrote: So, that means that with NDK i can? Can you explain this further please? Thanks, Lucas On Dec 28, 3:09 pm, Romain Guy romain...@android.com wrote: Java apps cannot directly accessOpenGLES2.0 APIs at the moment. On Thu, Dec 24, 2009 at 7:32 PM, Lawrencelee leelawrenc...@gmail.com wrote: Eclair has supportedOpenGLES2.0. But I can not find related JNI wrapper forOpenGLESAPI. How a Java application useOpenGLES2.0 functions? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Romain Guy Android framework engineer romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] OpenGL ES 2.0 support on Android emulator
Hi, I guess that application can use OpenGL ES 2.0 API directly through Java wrapper defined as android.opengl.GLES20 class, however it looks like there is no software rendering support for OpenGL ES 2.0 in Android emulator. Is there any plan to support (2) in Android roadmap? (1) OpenGL ES 1.0 API on Android emulator = Possible (2) OpenGL ES 2.0 API on Android emulator = Not supported. (3) OpenGL ES 1.0 API on hardware = Possible (4) OpenGL ES 2.0 API on hardware = Possible (but via JNI) Regards, /David -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: OpenGL ES 2.0 on Eclair
Hi It is really nice to hear that OpenGL ES 2.0 hearders are coming in NDK and also access from Java is also planned. One more question: What happened if Java application using OpenGL ES 2.0 tries to launch on the emulator that does not support OpenGL ES 2.0 software rendering? Regards, /David 2010/2/10 David Turner di...@android.com OpenGL ES 2.0 headers and libraries are not available in the NDK yet. They are coming. Access from Java is also planned. The Android software renderer doesn't support GL ES 2.0, neither does the emulator. I can't give any ETA for this, sorry. On Tue, Feb 9, 2010 at 12:12 AM, David Anders david.anders0...@gmail.comwrote: Hi, I also would like to bump this topic. - I guess that OpenGL ES 2.0 API will be defined in Java layer as android.opengl.GLES20 class. - We have been able to use OpenGL ES 2.0 API through hardware bindings using JNI. However in my understanding, it is impossible to use OpenGL ES 2.0 API with software rendering on emulator. When does Android plan to support software rendering for OpenGL ES 2.0 API? Regards, /David On 1月6日, 午前10:08, r2d2Proton r2d2pro...@live.com wrote: I would like to bump this. . . I was thinking the same thing - use the NDK to gain access to the 2.0 functions. I imagine that the OpenGL ES 2.0 functions are exposed in Imagination Technologies shared object file. Games should be considered an NDK level application. Wasn't anybody watching Microsoft when they tried this? Remember Direct-Draw? On Dec 28 2009, 11:10 am, rollbak roll...@gmail.com wrote: So, that means that with NDK i can? Can you explain this further please? Thanks, Lucas On Dec 28, 3:09 pm, Romain Guy romain...@android.com wrote: Java apps cannot directly accessOpenGLES2.0 APIs at the moment. On Thu, Dec 24, 2009 at 7:32 PM, Lawrencelee leelawrenc...@gmail.com wrote: Eclair has supportedOpenGLES2.0. But I can not find related JNI wrapper forOpenGLESAPI. How a Java application useOpenGLES2.0 functions? -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- Romain Guy Android framework engineer romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.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.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
[android-developers] Re: ADP2 Ion upgrade to Android 2.0?
Same here. It seems rooting and installing a custom image is the only choice. Bad Google. Didn't you want to the attendees at Google IO that you gave the phone to, to be able to develop modern applications for it? On Jan 6, 10:25 pm, ninu ninum...@gmail.com wrote: I am with you! I am trying to find out if there is any news about this as well. I have my Ion right now and want to install either 2.0 or 2.1 whichever I can get my hands on. -N On Dec 24 2009, 1:23 am, deuce4 lynx...@gmail.com wrote: Is there any official site that discusses any updates to whether or not the Ion will be able to upgraded to Android 2.0? Or is there any concrete news among users here? 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] Roadmap for localisation / new languages and locales
Hey, does anyone know if there are plans for adding Scandinavian languages and locales to future releases of android - and how soon? Or do you know how to find out? I am developing an app for both English-language users and Scandinavian users, but without Scandinavian locales I have to make a separate package for each country to get local UI language. It would be nice to know if this will be a permanent situation, or if we can expect more languages soon! Cheers, Anders -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Need an invitation to google Wave?
Yes I would like one! Thank you! br, Anders S. Løvlie anderslov...@gmail.com On Oct 31, 10:20 pm, Auguste Lunang legraphi...@gmail.com wrote: Hi, i have some google wave. invits to share. tell me if u want .. thx -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Self-restarting service
Hello, I am developing a slightly mission critical Android application, and want a Service component of it to be essentially immortal or at least self-restarting in the event of a crash (of the service). What would be the best way to accomplish this? I use API level 3 (Android 1.5). Thanks in advance, Anders Feder -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Sleep mode
Anyone? If it can't be done in any other way, is there by any chance any way to emulate that the 'end call' button has been pressed? (I've tried with dispatchKeyEvent() to my own activity, but that didn't do anything.) Thanks, Anders Feder 2009/10/24 Anders Feder anders.feder...@gmail.com Hello, Is it possible to programmaticly send the device into sleep mode (i.e. like when pressing the [end call] button once so screen the turns off and locks)? Thanks in advance, Anders Feder -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: IP broadcast on emulator
No info on this? On Oct 17, 8:17 am, Anders lanils...@gmail.com wrote: Bump On Oct 15, 3:12 pm, Anders lanils...@gmail.com wrote: Hi, I have an application that acts as both client and server. I have a scenario that I need to test that involves three devices. One of them needs tobroadcasta message (UDP) to the other two. Running on physical devices, this is not a problem, and it works fine. On the emulator however, this is much harder. I have managed to get it work for two devices using the emulator. Here my client threadbroadcastthe message to 10.0.2.255 port 6002, and server thread listens on port 6006. By using redir addudp:6002:6006 the server receives the message fine. Now, if I add another instance and do the same portforwarding, only one of them receives the message. I also tried to use a different port number on the server, and forward port 6002 to that number, with the same result. It appears as if a port can only be forwarded from one instance. Does anyone of a method tobroadcastusing the emulator, without sending a separate message to each emulator instance? Thanks,Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 wave invitations...?
Of course id like one too. but I guess I have to wait for an official one. On Oct 18, 8:49 am, Getto gige...@gmail.com wrote: me me !!! Thanks! On Oct 16, 4:32 pm, budziq bud...@gmail.com wrote: Well. Who wouldn't want one ;)? I guess I'd like one too ;) On Oct 16, 4:02 pm, Carl Whalley carl.whal...@googlemail.com wrote: I'd love an invite too ... anyone ... thanks! On Oct 16, 2:26 pm, Gavin Aiken gavin.ai...@imperial.ac.uk wrote: Takes at least 24 hours in my experience :) have fun waving! On Fri, Oct 16, 2009 at 2:09 PM, Kenneth Adam Miller kennethadammil...@gmail.com wrote: Have any of you gotten an email yet? I swear I've sent them out... perhaps they're just nominations for a possible invite to google wave and not you know actual concrete invitations I don't know, but I'm guessing that you guys would still want it. Hahah :) I'm in class right now, but I'll review all you guys On Fri, Oct 16, 2009 at 7:40 AM, GSC greg.ch...@gmail.com wrote: If anyone else has an available invitiation, please send me one. Thanks On Oct 16, 7:31 am, ColletJb collet...@gmail.com wrote: I think there are no invitation left from Kenneth Adam Miller. But if anyone invited by him has invitation and can invite me, It would be great ;) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: IP broadcast on emulator
Bump On Oct 15, 3:12 pm, Anders lanils...@gmail.com wrote: Hi, I have an application that acts as both client and server. I have a scenario that I need to test that involves three devices. One of them needs tobroadcasta message (UDP) to the other two. Running on physical devices, this is not a problem, and it works fine. On the emulator however, this is much harder. I have managed to get it work for two devices using the emulator. Here my client threadbroadcastthe message to 10.0.2.255 port 6002, and server thread listens on port 6006. By using redir add udp:6002:6006 the server receives the message fine. Now, if I add another instance and do the same portforwarding, only one of them receives the message. I also tried to use a different port number on the server, and forward port 6002 to that number, with the same result. It appears as if a port can only be forwarded from one instance. Does anyone of a method tobroadcastusing the emulator, without sending a separate message to each emulator instance? Thanks,Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] IP broadcast on emulator
Hi, I have an application that acts as both client and server. I have a scenario that I need to test that involves three devices. One of them needs to broadcast a message (UDP) to the other two. Running on physical devices, this is not a problem, and it works fine. On the emulator however, this is much harder. I have managed to get it work for two devices using the emulator. Here my client thread broadcast the message to 10.0.2.255 port 6002, and server thread listens on port 6006. By using redir add udp:6002:6006 the server receives the message fine. Now, if I add another instance and do the same portforwarding, only one of them receives the message. I also tried to use a different port number on the server, and forward port 6002 to that number, with the same result. It appears as if a port can only be forwarded from one instance. Does anyone of a method to broadcast using the emulator, without sending a separate message to each emulator instance? Thanks, Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Why does getPadding() of NinePatchDrawable throw a NullPointerException?
Ah! That works fine, thank you very much. As to why I was creating a NinePatchDrawable my self... I can only claim inexperience with the NinePatch classes. :) This is how it looks now, after your comments: Bitmap tagBalloonBitmap = BitmapFactory.decodeResource(getResources(), R.drawable.balloon); NinePatchDrawable tagBalloon9pDrawable = new NinePatchDrawable(tagBalloonBitmap, tagBalloonBitmap.getNinePatchChunk(), new Rect(0,0,0,0), null); // Anders On 13 Okt, 00:01, Romain Guy romain...@google.com wrote: BTW, why are you creating the NinePatchDrawable yourself if you are creating it from a resource anyway? On Mon, Oct 12, 2009 at 3:01 PM, Romain Guy romain...@google.com wrote: NinePatchDrawable tagBalloon9pDrawable = new NinePatchDrawable(tagBalloon9p); this creates a NinePatchDrawable with a null padding. That's why you get an NPE. You need to specify the padding. On Mon, Oct 12, 2009 at 10:07 AM,Anderssundman.and...@gmail.com wrote: I'm trying to use NinePatchDrawables in a LayerDrawable, but for some reason I get a NullPointerException. I've isolated the problem to the getPadding() method; the following code reproduces the problem: Bitmap tagBalloonBitmap = BitmapFactory.decodeResource(getResources(), R.drawable.balloon); NinePatch tagBalloon9p = new NinePatch(tagBalloonBitmap, tagBalloonBitmap.getNinePatchChunk(), null); NinePatchDrawable tagBalloon9pDrawable = new NinePatchDrawable (tagBalloon9p); Rect r = new Rect(); tagBalloon9pDrawable.getPadding(r); -- Throws NullPointerException! What am I missing? Do I have to do anything special with the NinePatch? The program seems to work if I use the NinePatch directly (instead of putting it in a LayerDrawable). Any suggestions and help is greatly appreciated. //Anders -- Romain Guy Android framework engineer romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them -- Romain Guy Android framework engineer romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Why does getPadding() of NinePatchDrawable throw a NullPointerException?
I didn't know about that method, but that sounds like the right solution. I was kind of suspecting that there would be a cleaner solution to all of this. Thank you for your advice. // Anders On 13 Okt, 09:36, Dianne Hackborn hack...@android.com wrote: I very very strongly recommend not creating a nine patch yourself; just use Resources.getDrawable() to create it. On Tue, Oct 13, 2009 at 12:02 AM, Anders sundman.and...@gmail.com wrote: Ah! That works fine, thank you very much. As to why I was creating a NinePatchDrawable my self... I can only claim inexperience with the NinePatch classes. :) This is how it looks now, after your comments: Bitmap tagBalloonBitmap = BitmapFactory.decodeResource(getResources(), R.drawable.balloon); NinePatchDrawable tagBalloon9pDrawable = new NinePatchDrawable(tagBalloonBitmap, tagBalloonBitmap.getNinePatchChunk(), new Rect(0,0,0,0), null); // Anders On 13 Okt, 00:01, Romain Guy romain...@google.com wrote: BTW, why are you creating the NinePatchDrawable yourself if you are creating it from a resource anyway? On Mon, Oct 12, 2009 at 3:01 PM, Romain Guy romain...@google.com wrote: NinePatchDrawable tagBalloon9pDrawable = new NinePatchDrawable(tagBalloon9p); this creates a NinePatchDrawable with a null padding. That's why you get an NPE. You need to specify the padding. On Mon, Oct 12, 2009 at 10:07 AM,Anderssundman.and...@gmail.com wrote: I'm trying to use NinePatchDrawables in a LayerDrawable, but for some reason I get a NullPointerException. I've isolated the problem to the getPadding() method; the following code reproduces the problem: Bitmap tagBalloonBitmap = BitmapFactory.decodeResource(getResources(), R.drawable.balloon); NinePatch tagBalloon9p = new NinePatch(tagBalloonBitmap, tagBalloonBitmap.getNinePatchChunk(), null); NinePatchDrawable tagBalloon9pDrawable = new NinePatchDrawable (tagBalloon9p); Rect r = new Rect(); tagBalloon9pDrawable.getPadding(r); -- Throws NullPointerException! What am I missing? Do I have to do anything special with the NinePatch? The program seems to work if I use the NinePatch directly (instead of putting it in a LayerDrawable). Any suggestions and help is greatly appreciated. //Anders -- Romain Guy Android framework engineer romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them -- Romain Guy Android framework engineer romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Bounds of a LayerDrawable?
Hi! What is the semantics of the LayerDrawable bounds? I was kind of hoping it would be the union of all the Drawables i had put into it, but it doesn't seem to be. To give some more context to the problem; I'm working on a map application with overlays. The overlay should be one part a region (like a rect) centered at the overlay point (bounds: -x, -x, x, x) and one part a balloon-like graphics (bounds: -y, -y, y, 0). The drawables should be able to change size independently of each other, so x != y (e.g. if I put text in the balloon, I would like to adjust it's size). Both drawables are currently NinePathes. I thought it would be nifty if I could group the two Drawables together some how and so I started looking at the LayerDrawable. But how should I specify the bounds? If I set any bounds for the LayerDrawable, they are also set for both the containing drawables. If I don't set any bounds, the drawable doesn't get drawn at all. Is the LayerDrawable even supposed to be used like a Drawable collection pattern in this way? Any advice will be much appreciated. Best Regards, Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Scaling OverlayItems with zoom level
Hi! What is the preferred (right?) way to scale the Drawable markers of an ItemizedOverlay in a MapView? Say for instance that you have a rect or a circle with a fixed physical dimension like 500 meters across. The drawable has to change size when the user is zooming in and out in the view. What is the best way of doing this? I'm currently changing the bounds of all OverlayItems drawables in the mapviews onSizeChanged method. This seems a bit crude. Is there a more convenient solution? Best Regards, Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 get the size of a component in onCreate?
Hi all, I'm working on an application where I wan't to show a thumbnail image on an ImageButton. This works when I scale the image to create the thumbnail using a hard coded size, but I would really like to use the button.getWidth() / getHeight() to calculate the size of the thumbnail. However the getWidth/Height returns zero in onCreate() - probably because the layouting is not finished(?). Is there any way to get the size of the component? Is there any onLayoutDone() function that I could override, or how should one go about doing this? Any suggestions will be appreciated. Best Regards, Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Why does getPadding() of NinePatchDrawable throw a NullPointerException?
I'm trying to use NinePatchDrawables in a LayerDrawable, but for some reason I get a NullPointerException. I've isolated the problem to the getPadding() method; the following code reproduces the problem: Bitmap tagBalloonBitmap = BitmapFactory.decodeResource(getResources(), R.drawable.balloon); NinePatch tagBalloon9p = new NinePatch(tagBalloonBitmap, tagBalloonBitmap.getNinePatchChunk(), null); NinePatchDrawable tagBalloon9pDrawable = new NinePatchDrawable (tagBalloon9p); Rect r = new Rect(); tagBalloon9pDrawable.getPadding(r); -- Throws NullPointerException! What am I missing? Do I have to do anything special with the NinePatch? The program seems to work if I use the NinePatch directly (instead of putting it in a LayerDrawable). Any suggestions and help is greatly appreciated. // Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Camera and Surface problems with 1.6
Hi all, My company has so far developed four different camera-based applications that all work by manipulating the viewfinder feed from the camera. The Android camera API expects a Surface to draw the viewfinder feed to, however in our apps we rely on sidestepping the direct drawing and grabbing the YUV_420_SP data for manipulation and rendering to a Surface. On 1.5, we achieved this by changing the Surface type from PUSH_BUFFERS to NORMAL, which would in one stroke disable the direct feed to the surface from the camera as well as giving us a Surface onto which we could render the manipulated feed. The problem arises when upgrading to 1.6, as it appears that this hole has been plugged. The Camera class now refuses to start the preview feed if its associated preview display surface is of the wrong type (such as NORMAL). I realize that this is probably correct as per design, unfortunately it also makes our type of app very difficult to implement... I have tried to work around it by creating a dummy surface view to set as preview display, and although I have managed to hide it, I haven't been able to stop the direct feed, which of course means that performance slows to a crawl as both the direct feed and manipulated feed are active and drawing at the same time. I would be most grateful for any suggestions on how to resolve this issue... best regards Anders Johansson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Camera and Surface problems with 1.6
Hi Tom, It does indeed seem like we're in the same situation. I'm going to play around some more with the position, size and visibility of my PUSH_BUFFERS surface to see what works best. All in all though, I completely agree with your conclusion...this is a hack, and there's no telling how long it will work. I also agree with your point about the mysterious Camera API, here are my main gripes: 1. There's a callback for receiving viewfinder data, but it never occurred to the designer that 3rd parties might want to use that _instead_ of letting the framework draw it directly to a surface. 2. The callback for viewfinder data only let's you receive YUV data. This is good from a performance perspective as it comes directly from the camera, but IMHO causes the following issues: a) The YUV format is dependent on the sensor/vendor hardware. Yes, there is an API to query the format, but considering the not so stellar qualcomm driver implementation for HTC, this may not be trustworthy. b) 3rd parties wishing to use viewfinder data will have to be able to decode all forms of YUV data in order to be safe on future devices, assuming that the API mentioned in the point above is trustworthy. c) The requirement to decode the YUV raises the bar quite a bit for 3rd party developers who might have ideas in this field. Thus, it would seem reasonable to provide an option to receive the data in either YUV or RGB format. Unfortunately, even if the API's are modified in a future release we will be stuck with maintaining different code for different releases and/or OEMs... regards Anders On Oct 1, 1:51 pm, Tom Gibara m...@tomgibara.com wrote: If I understand correctly, you're doing something very similar to what I'm doing in my Moseycode application. In my case I render the camera YUV data via a GLSurfaceView. I can't say whether this will work for certain on all/any 1.6 devices, but my approach since 1.5 has been to make the PUSH_BUFFERS surface very small and to position it off-screen (a nasty hack that works in the emulator at least). I think the smallest supported dimensions that preserve the aspect ratio are 20px x 15px. That said, I'm just waiting for this circuitous implementation to blow-up on me. Why the camera demands a surface in order to provide preview data is a mystery to me (as is so much of the Camera API's operation). Tom 2009/10/1 Anders Johansson svi...@gmail.com Hi all, My company has so far developed four different camera-based applications that all work by manipulating the viewfinder feed from the camera. The Android camera API expects a Surface to draw the viewfinder feed to, however in our apps we rely on sidestepping the direct drawing and grabbing the YUV_420_SP data for manipulation and rendering to a Surface. On 1.5, we achieved this by changing the Surface type from PUSH_BUFFERS to NORMAL, which would in one stroke disable the direct feed to the surface from the camera as well as giving us a Surface onto which we could render the manipulated feed. The problem arises when upgrading to 1.6, as it appears that this hole has been plugged. The Camera class now refuses to start the preview feed if its associated preview display surface is of the wrong type (such as NORMAL). I realize that this is probably correct as per design, unfortunately it also makes our type of app very difficult to implement... I have tried to work around it by creating a dummy surface view to set as preview display, and although I have managed to hide it, I haven't been able to stop the direct feed, which of course means that performance slows to a crawl as both the direct feed and manipulated feed are active and drawing at the same time. I would be most grateful for any suggestions on how to resolve this issue... best regards Anders Johansson -- Tom Gibara email: m...@tomgibara.com web:http://www.tomgibara.com blog:http://blog.tomgibara.com twitter: tomgibara --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: registerForContextMenu failes with Gallery in listview.
Just realised I can't click on stations either if I have the gallery visible :/ On Jul 20, 1:11 pm, Anders Aagaard aagaa...@gmail.com wrote: Hi I have an application using a ListView activity to display realtime station information. The layout is like this: Top line, Station name - Eta Gallery with TextView's, draggable showing busses/trains arriving after the next one Now on simple station data where I do Gallery.setVisibility(View.GONE) registerForContextMenu works as expected, but as soon as the gallery is rendered I can not get the context menu up for that line at all. It'll still work for different routes, just not the route showing extra information. This is the main list: RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=wrap_content android:orientation=vertical TextView android:id=@+id/line android:layout_width=wrap_content android:layout_height=wrap_content android:textAppearance=?android:attr/textAppearanceMedium android:layout_marginLeft=2dip android:layout_alignParentTop=true android:layout_alignParentLeft=true / TextView android:id=@+id/destination android:layout_width=wrap_content android:layout_height=wrap_content android:textAppearance=?android:attr/textAppearanceMedium android:layout_marginLeft=40dip android:layout_alignBaseline=@id/line android:layout_alignParentLeft=true / TextView android:id=@+id/time android:layout_width=wrap_content android:layout_height=wrap_content android:textAppearance=?android:attr/textAppearanceMedium android:layout_marginRight=6dip android:layout_alignParentRight=true / Gallery android:id=@+id/nextDepartures android:layout_width=fill_parent android:layout_height=wrap_content android:spacing=16dp android:layout_below=@+id/line / /RelativeLayout And this is the data I put in Gallery: TextView xmlns:android=http://schemas.android.com/apk/res/android; android:id=@android:id/text1 android:layout_width=wrap_content android:layout_height=wrap_content android:textAppearance=?android:attr/textAppearanceSmall android:textColor=#00 / --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Forcing an activity to reload completely?
Hi I have an application, where I need to change the language through a settings menu. Now this part works perfectly, but it doesn't change the language for activities that have gone through onCreate. I got a TabHost, and 2 tabs in it, from the tabs you can get to settings. Refreshing the TabHost isn't an issue, as it's fairly small, however both the 2 tabs are quite large views, and having a function to manually update all the strings seem unnecessarily difficult. Is there any way to force the activity to recreate itself and trigger a new onCreate? I tried having a static function in the tabhost that clears all tabs and recreates them, this refreshes the tab titles, but not the content in the tabs. Anders Aagaard --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] registerForContextMenu failes with Gallery in listview.
Hi I have an application using a ListView activity to display realtime station information. The layout is like this: Top line, Station name - Eta Gallery with TextView's, draggable showing busses/trains arriving after the next one Now on simple station data where I do Gallery.setVisibility(View.GONE) registerForContextMenu works as expected, but as soon as the gallery is rendered I can not get the context menu up for that line at all. It'll still work for different routes, just not the route showing extra information. This is the main list: RelativeLayout xmlns:android=http://schemas.android.com/apk/res/android; android:layout_width=fill_parent android:layout_height=wrap_content android:orientation=vertical TextView android:id=@+id/line android:layout_width=wrap_content android:layout_height=wrap_content android:textAppearance=?android:attr/textAppearanceMedium android:layout_marginLeft=2dip android:layout_alignParentTop=true android:layout_alignParentLeft=true / TextView android:id=@+id/destination android:layout_width=wrap_content android:layout_height=wrap_content android:textAppearance=?android:attr/textAppearanceMedium android:layout_marginLeft=40dip android:layout_alignBaseline=@id/line android:layout_alignParentLeft=true / TextView android:id=@+id/time android:layout_width=wrap_content android:layout_height=wrap_content android:textAppearance=?android:attr/textAppearanceMedium android:layout_marginRight=6dip android:layout_alignParentRight=true / Gallery android:id=@+id/nextDepartures android:layout_width=fill_parent android:layout_height=wrap_content android:spacing=16dp android:layout_below=@+id/line / /RelativeLayout And this is the data I put in Gallery: TextView xmlns:android=http://schemas.android.com/apk/res/android; android:id=@android:id/text1 android:layout_width=wrap_content android:layout_height=wrap_content android:textAppearance=?android:attr/textAppearanceSmall android:textColor=#00 / --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Handset power/current draw
Hi, I am interested in knowing how much power or current my phone draws at any given instant for, among other things, power optimization purposes. Is there any way (API or otherwise) to inspect how much power or current the Android handset currently draws? Thanks, Anders Feder --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Video with MediaRecorder
Hi, Thanks, I got it to work. I have one problem though. When I rotate the phone, using automatic Orientation the onDestroy() method of my activity is called, which effectively also stops capturing. When the activity is recreated, a new capture starts. This means I will now have two files for the same capture since the user didnt choose to stop the capture. (And I need to merge these files). Does anyone know of a way to keep the capture running when rotating the phone? Thanks, Anders On May 6, 8:11 pm, Jason Proctor ja...@particularplace.com wrote: just a tiny fyi here is that i did manage to get video recording working fine in my app. there is however a problem if the surface view fills its parent and the parent is the entire screen. if that happens, then the camera's view of things gets resized but nobody tells the codec, and hence the movie is messed up. it's encoded for one size but the movie metainfo says something else. making the size something smaller than the screen made it work, but it *is* a bug IMHO. -- jason.software.particle --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Video with MediaRecorder
Hi, Jason, thank you. That really helped a lot. I no longer see onDestroy being called all the time. Before setting the orientation to LANDSCAPE, the preview display was wrong. The display was rotated 90 degrees and the picture a bit distorted After setting the orientation everything looks the way I would I expect it to be; When in portrait, the preview is in portrait as well as the captured video, and when in landscape both preview and capture is in landscape. In my opinion, this setting should be the default setting. For future reference, here is a snippet of my code. recorder.setAudioSource(MediaRecorder.AudioSource.MIC); recorder.setVideoSource(MediaRecorder.VideoSource.CAMERA); recorder.setOutputFormat(MediaRecorder.OutputFormat.MPEG_4); recorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB); recorder.setVideoEncoder(MediaRecorder.VideoEncoder.MPEG_4_SP); recorder.setOutputFile(filePath); CameraView.thisCameraView.setRequestedOrientation (ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE); recorder.setPreviewDisplay(sv); recorder.prepare(); recorder.start(); CameraView is my activity displaying the preview, that includes my SurfaceView class (sv is the surface of the holder) and camera object. Thanks, Anders On May 7, 8:56 pm, Jason Proctor ja...@particularplace.com wrote: yes. the movie file is correctly formed, but the picture is messed up. i've not tried correcting the metadata in the file, but that *should* fix it. either way, AuthorDriver or whoever should be telling QualcommCameraHardware what's going on, IMHO. Wait, when you say corruption, you really mean that there's a mismatch between the metadata and the actual frame size, is that correct? On May 7, 11:17 am, Jason Proctor ja...@particularplace.com wrote: i don't change it, it gets changed by the Author Driver presumably to avoid colliding with the status bar or somesuch. here's some log output which might illustrate what's going on -- 05-07 11:13:51.516: WARN/AuthorDriver(35): Intended width(480) exceeds the max allowed width(352). Max width is used instead. 05-07 11:13:51.516: WARN/AuthorDriver(35): Intended height(295) exceeds the max allowed height(288). Max height is used instead. however, a bit later on it seems that nobody has told the camera this -- 05-07 11:13:51.686: VERBOSE/QualcommCameraHardware(35): requested size 480 x 320 05-07 11:13:51.686: VERBOSE/QualcommCameraHardware(35): actual size 480 x 320 so the codec is encoding for 480x320, but the surface is only delivering 352x288. hence the corruption. hth j This is a limitation of the hardware, the preview size and encoded size must be the same. I'm not sure how you were able to change the preview size though. I'd like to know the code sequence you used, because it's not supposed to be possible. On May 6, 11:11 am, Jason Proctor ja...@particularplace.com wrote: just a tiny fyi here is that i did manage to get video recording working fine in my app. there is however a problem if the surface view fills its parent and the parent is the entire screen. if that happens, then the camera's view of things gets resized but nobody tells the codec, and hence the movie is messed up. it's encoded for one size but the movie metainfo says something else. making the size something smaller than the screen made it work, but it *is* a bug IMHO. -- jason.software.particle -- jason.software.particle -- jason.software.particle --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Video with MediaRecorder
Hi, Does anyone know how to use the MediaRecorder to API to capture video? I am writing an application where I want to be able to capture video. I am trying to use the MediaRecorder API in 1.5, which is supposed to support video capture. However, there are no examples in the documentation on how to use this API for video (only for audio, and that works perfect). Basically what I do is the following: final MediaRecorder recorder = new MediaRecorder(); final String filePath; recorder.setAudioSource(MediaRecorder.AudioSource.MIC); recorder.setOutputFormat(MediaRecorder.OutputFormat.THREE_GPP); recorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB); recorder.setVideoSource(MediaRecorder.VideoSource.CAMERA); recorder.setOutputFormat(MediaRecorder.OutputFormat.MPEG_4); recorder.setVideoEncoder(MediaRecorder.VideoEncoder.MPEG_4_SP); recorder.setOutputFile(filePath); recorder.prepare(); recorder.start(); This gives me the following error: E/CameraInput( 37): No surface is available for display E/MediaRecorder( 7609): prepare failed: -2147483648 OK, so I have to have a surface to preview the video? Could be useful I guess, but not something I really need. Could I use the VideoView widget for this, or is that only for playback? Or am I supposed to use a SurfaceView to preview the video? I saw someone use that to capture images, but they used android.hardware.Camera to open the camera and capture a frame, and did not use MediaRecorder. Does anyone have any idea on how to capture video, or even better have some example code? Thanks, Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Start native application from Java
Hi, I have a native application that I would like to start from a Java interface. Does anyone know of a good way of doing this? I can start the application using adb, with no problems. I can also start the application using Runtime.exec(), but that doesn't work so well for me; I need the application to run outside of a Java Runtime Process. Any ideas? Thanks, Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Does Android support APDUConnection as known from JSR 177?
I don't know but JSR 177 seems to be a J2ME-related JSR. Android has (in theory) a JCE-based API that does what JSR 177 does and more. The problem is really that there is no link between the JCE and the SIM if that's what you are looking for. Personally I think using the SIM with JSR 177 is a bad idea, SIM TK solutions are the only generally available. You may be interested in http://android-keystore-v2.webpki.org BTW, are you the real Neil Young? :-) I'm a true fan! Rgds AR On Feb 21, 2:59 pm, Neil.Young neil.yo...@freenet.de wrote: Simple question. More answers? Regards --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Does Android support APDUConnection as known from JSR 177?
Hi Neil, Sorry about the banning. Now to the SIM issues. I have been working with mobile phone auth solutions since 1998 and it has been said that the SIM is the way to go. For various reasons, and in particular due to a lack of a business model, operators have often used the cheapest SIMs they could find I.e. SIM are often wihout RSA capability. Anyway, since the SIM is owned, reserved, andcontrolled by the operators, the handset makers haven't done very much to make SIMs usable except trough SIM ToolKit. In the EU there are large deployments of SIM TK auth solutions. These solutuions are all horrible and not integrated with the phone apps. I started my project to get rid of SIM dependencies. Anders On Feb 23, 2:12 pm, spongebob.squarepants spongebob.squarepa...@freenet.de wrote: Hi Anders, many thanks for answering. I don't know what happened, but over the weekend I seemed to blow my rather old account Neil.Young, so it is BANNED now (I did never appear such things :() and I don't know, why. What went wrong with my subscription? So I'm forced to use this rediculous account to proceed :) Neil and Spongebob, what a difference ;) OK, back to the problem: JCE based API, hmm. Could you please be a bit more specific? What I wanted to achieve is to gain access to the SIM card, especially to the authentication algorithms. Please don't let our conversation stop, you are my only contact to this group... I was a very active member in the beginning of Android, but shifted my focus in 2008. The only thing, I wanted, was to return... But I was BANNED, thanks... Regards On 23 Feb., 13:10, Anders Rundgren anders.rundg...@telia.com wrote: I don't know but JSR 177 seems to be a J2ME-related JSR. Android has (in theory) a JCE-based API that does what JSR 177 does and more. The problem is really that there is no link between the JCE and the SIM if that's what you are looking for. Personally I think using the SIM with JSR 177 is a bad idea, SIM TK solutions are the only generally available. You may be interested inhttp://android-keystore-v2.webpki.org BTW, are you the real Neil Young? :-) I'm a true fan! Rgds AR On Feb 21, 2:59 pm, Neil.Young neil.yo...@freenet.de wrote: Simple question. More answers? Regards- 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 Keystore V2
http://android-keystore-v2.webpki.org In case there is anybody out there who would like to create a support- application to an activity that is already used by everybody on the Internet, the moment has come! I'm particularly interested in developers with deep knowledge of Linux services and/or the Android GUI. Note: this is not yet another password vault or similar, this is about *eventually getting rid* of passwords! Anders Rundgren --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Newbe question - Application folders, how to?
I had hoped that you could do all this with application XML declarations rather than by code. Thanx anyway for prompt answer! On Dec 5, 3:38 am, Dianne Hackborn [EMAIL PROTECTED] wrote: If you mean you want to put such a thing in the sliding drawer that you pull up from the bottom, that is a flat list of apps. But you can just write an activity that goes in there, and when your activity is launched show a folder of whatever sub-activities you want. On Thu, Dec 4, 2008 at 9:06 AM, Anders Rundgren [EMAIL PROTECTED]wrote: Thanx! But I wanted to create a folder in the application drawer (or what it should be called) that also should not look like a folder but as an app which would if pressed open the folder with the real apps. Isn't that what most mult-app installs need? On Nov 29, 11:59 am, Romain Guy [EMAIL PROTECTED] wrote: Long press an empty space on Home (or click Menu Add) then choose Shortcut Folder. You can drop applications in the newly created folder. On Sat, Nov 29, 2008 at 2:56 AM, Anders Rundgren [EMAIL PROTECTED] wrote: In other operating systems you can typically define a folder and when clicked it opens a view with applications. I may be blind, but I don't see any of this using the emulator and SDK 1.0. Is the ApiDemos the only GUI-way you can create a suite of associated applications? -- Romain Guywww.curious-creature.org -- Dianne Hackborn Android framework engineer [EMAIL PROTECTED] Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them.- Hide quoted text - - Show quoted text - --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Newbe question - Application folders, how to?
Thanx! But I wanted to create a folder in the application drawer (or what it should be called) that also should not look like a folder but as an app which would if pressed open the folder with the real apps. Isn't that what most mult-app installs need? On Nov 29, 11:59 am, Romain Guy [EMAIL PROTECTED] wrote: Long press an empty space on Home (or click Menu Add) then choose Shortcut Folder. You can drop applications in the newly created folder. On Sat, Nov 29, 2008 at 2:56 AM, Anders Rundgren [EMAIL PROTECTED] wrote: In other operating systems you can typically define a folder and when clicked it opens a view with applications. I may be blind, but I don't see any of this using the emulator and SDK 1.0. Is the ApiDemos the only GUI-way you can create a suite of associated applications? -- Romain Guywww.curious-creature.org --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Theme setting for all applications
Thanks for the reply:)I understand that at this point there is no support for theme switch application which enables an end-user to choice theme from multiple themes like Windows OS I am looking forward to this feature to be delivered from Google. On the other hand, even if we cannot switch themes, I would like to try to modify default theme. Is it possible to do this by modifying themes.xml in the Android open source /frameworks/base/core/res/res/values directory and then making a build to create emulator? In addition to this, I found themes.xml and other resources in tools/lib/res/default/values in the Android SDK toolkit directory. I changed this xml file and other png files in drawable folder, but nothing changes in Android emulator... Why? Is there something else to do this? Regards, /Paul 2008/12/1 Dianne Hackborn [EMAIL PROTECTED] There is some architecture work done for this, but a fair amount remaining. At this point finishing the work is not scheduled on the roadmap. On Sun, Nov 30, 2008 at 4:31 PM, E [EMAIL PROTECTED] wrote: I'd like to know about full-OS themes too. It looks like (from the developer's kit) that such a thing is already supported in the backend (why wouldn't it be, right?), but there doesn't appear to be a system- level app that will manage or switch between theme configs. If this truly isn't available yet, when will it be? thanks, -Ethan On Nov 22, 11:58 pm, Paul Anders [EMAIL PROTECTED] wrote: Hello, I would like to ask you about how to change application theme. In case of application-specific theme, it is possible to change theme by asking your Activity to call setTheme(int theme). On the other hand, how can we change theme applicable to all applications which does not have their own theme? As you know, Windows OS has a theme setting which can be changed by an end-user in the display property of control panel. Does android platform support this feature? If Android platform does not support theme setting, I have the following solutions from developer point of view. (1) Modify themes.xml provided by Android framework as default, and then make a build. (/frameworks/base/core/res/res/values/themes.xml) (2) Change Android open source code to add new APIs for changing theme for all applications. Is there any other better solution to change theme for all applications? Regards, /Paul -- Dianne Hackborn Android framework engineer [EMAIL PROTECTED] Note: please don't send private questions to me, as I don't have time to provide private support. All such questions should be posted on public forums, where I and others can see and answer them. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Newbe question - Application folders, how to?
In other operating systems you can typically define a folder and when clicked it opens a view with applications. I may be blind, but I don't see any of this using the emulator and SDK 1.0. Is the ApiDemos the only GUI-way you can create a suite of associated applications? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Theme setting for all applications
Hello, I would like to ask you about how to change application theme. In case of application-specific theme, it is possible to change theme by asking your Activity to call setTheme(int theme). On the other hand, how can we change theme applicable to all applications which does not have their own theme? As you know, Windows OS has a theme setting which can be changed by an end-user in the display property of control panel. Does android platform support this feature? If Android platform does not support theme setting, I have the following solutions from developer point of view. (1) Modify themes.xml provided by Android framework as default, and then make a build. (/frameworks/base/core/res/res/values/themes.xml) (2) Change Android open source code to add new APIs for changing theme for all applications. Is there any other better solution to change theme for all applications? Regards, /Paul --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: javax.net.ssl.SSLException: Not trusted server certificate
Are you using a commercial SSL cert vendor like VeriSign. If not you need to either disable certficate validation or install the trust anchor of the SSL cert. I don't have the G1 som I only know how to do it on the emulator. It wasn't easy BTW since Android does not use the standard SUN format but a BouncyCastle variant. I did a converter since I have so many stores in SUN format: http://groups.google.com/group/android-developers/browse_thread/thread/1afdf215aa539ca9/6e3ec00d92eb5e32#6e3ec00d92eb5e32 Anders On Nov 20, 11:13 am, AnuR [EMAIL PROTECTED] wrote: Hi, While I am trying to post a web page using DefaultHttpClient httpclient = new DefaultHttpClient(); CookieStore cookies = httpclient.getCookieStore(); HttpPost Postmethod = new HttpPost(https://urlto post);// Submiting I agree page ArrayListBasicNameValuePair nvpairs = new ArrayList(); vpairs.add(new BasicNameValuePair(name1, value1)); nvpairs.add(new BasicNameValuePair(name2, value2)); nvpairs.add(new BasicNameValuePair(name3, value3)); httpclient.setCookieStore(cookies); UrlEncodedFormEntity p_entityIAgree = new UrlEncodedFormEntity (nvpairs); Postmethod .setEntity(new UrlEncodedFormEntity(nvpairs, HTTP.UTF_8)); Postmethod .setEntity(p_entityIAgree); ResponseHandlerString IAgreeresponseHandler = new BasicResponseHandler(); String IAgreeSubmitresponseBody = httpclient.execute(Postmethod , IAgreeresponseHandler); I am getting an error 11-20 12:36:22.589: WARN/System.err(366): javax.net.ssl.SSLException: Not trusted server certificate. why is it caused ? how Can i solve it? _ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: About running two different applications with the same code base
I believe the Android demo APIDemos is doing this. I.e. a single APS file can host multiple applications sharing a common codebase. BR AR On Nov 18, 9:02 pm, magicpig [EMAIL PROTECTED] wrote: Any one can help? On Nov 17, 2:15 pm, magicpig [EMAIL PROTECTED] wrote: Hi, I am wonder whether we can runtwoseparated apps with thesamecodebase. Thesetwoapps aredifferentby a flag. Here are some questions: 1) Where to set the flag? Is it possible for an application read the flag if we set it in AndroidManifest.xml? 2) I think I should usedifferentpackage values for thetwo apps, so needtwoseparated AndroidManifest.xml, right? 3) I think the authorities of the provider should bedifferent, so, we should make themdifferentin Androidmanifest.xml, right? Any one has similar experience? Please provide your help. thanks.- Hide quoted text - - Show quoted text - --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: working WebView example?
There is a WebViewDemo app which worked fine for me. http://code.google.com/p/apps-for-android/source/browse/#svn/trunk/Samples/WebViewDemo Anders On Nov 18, 5:36 pm, joshv [EMAIL PROTECTED] wrote: Try putting the WebView in your layout, assigning it an appropriate ID, and then in onCreate get a reference to it using: setContentView(R.layout.webtest); //Or whatever the name of your layout containing the webview is. WebView wv = (WebView)findViewById(R.id.webViewID); This works for me. -josh On Nov 17, 3:36 pm, benadamx [EMAIL PROTECTED] wrote: yey folks, wondering if anyone can provide a quick WebView example that successfully loads a page from the interweb; most of the examples I've found either contain code that isn't valid againt the latest version of the SDK, or that just outright doesn't work. here's what I have so far: public class SuperDoodad extends Activity { public void onCreate(Bundle icicle) { super.onCreate(icicle); WebView webview = new WebView(this); webview.loadUrl(http://www.stumbleupon.com;); setContentView(webview); } } .. this builds and runs fine, but fails to load the page, giving me a 'Web page not available' error. I have granted this app Internet permissions; what am I missing?- Hide quoted text - - Show quoted text - --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Terminal Services Client?
It seems that it might be useful to not always try to replicate the fat-client but rather use terminal services for certain not so often used applications. Is there such a thing available for Android? BR AR --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Error while connecting to ms sql server 2005 database
Have you put the msft jdbc driver in libs? Anyway, I wouldn't go this route at all, it is better to put databases behind web-servers and use http/SOAP for database access. If you goal is an admin utility I would consider terminal-server solutions so that you can use existing admin tools rather than writing low-level replacements fpr phones. BR AR On Nov 11, 6:01 am, Nataraaj [EMAIL PROTECTED] wrote: Hello guys, This is the code i wrote package com.android.DBConnection; import android.app.Activity; import android.app.AlertDialog; import android.content.Intent; import android.os.Bundle; import android.view.View; import android.view.View.OnClickListener; import android.widget.Button; import java.sql.*; public class DBConn extends Activity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); Button button = (Button)findViewById(R.id.btnCheckDBConnection); button.setOnClickListener(mCheckDBConnectionListener); } private OnClickListener mCheckDBConnectionListener = new OnClickListener() { public void onClick(View v) { // To send a result, simply call setResult() before your setResult(RESULT_OK, (new Intent()).setAction(DBConnection!)); AlertDialog.Builder Aldg = new AlertDialog.Builder(DBConn.this); try{ Aldg.setTitle(Check DB Connection); Class.forName(com.microsoft.sqlserver.jdbc.SQLServerDriver); Connection DBConnSQL = DriverManager.getConnection(jdbc:sqlserver://kcp-tech-015\\SQLEXPRESS: 1433;DatabaseName=CafetriaManagement,sa,sa); if (DBConnSQL==null) Aldg.setMessage(Not Connected); else Aldg.setMessage(Connected); //Statement stmt= DBConnSQL.createStatement(ResultSet.TYPE_SCROLL_SENSITIVE, //ResultSet.CONCUR_READ_ONLY) ; //ResultSet rst = stmt.executeQuery(SELECT COUNT(*) FROM SALE); //while (rst.next()) //{ // Aldg.setMessage(rst.getString(1)); //} } catch (Exception ex) { Aldg.setMessage(Error: + ex); } finally { Aldg.show(); } } }; } On Nov 10, 10:25 pm, Michael [EMAIL PROTECTED] wrote: Maybe you could provide some sample code so we can figure out what you're doing?- Hide quoted text - - Show quoted text - --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Browser extensions i Java? YES, NO, Some?
For those who do not feel that traversing tons of C++ code to get the real truth is their cup of tea, I wonder if somebody from the Android core team could elaborate a bit on what is possible to do in Java with respect to browser extensions? In particular: - Support for the HTML Object type - Adding a MIME type decoder and getting the browser environment as well - NS Plugin API - Adding JavaScript objects Anyhing else that could be useful in this context. Anders --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---
[android-developers] Re: Yet another HTTPS problem with HttpClient in Android SDK v1.0r1
Wrong keystore version could mean that you do not use the BKS format but JKS. I had to write a converter: package org.webpki.tools; import java.io.FileInputStream; import java.io.FileOutputStream; import java.util.Enumeration; import java.security.KeyStore; import java.security.Key; import java.security.Security; import java.security.cert.Certificate; import org.bouncycastle.jce.provider.BouncyCastleProvider; public class JKS2BKSConverter { public static void main (String argv[]) throws Exception { if (argv.length != 4) { System.out.println (JKS2BKSConverter.class.getName () + jksfile bksfile/-same storepass keypass); System.exit (3); } Security.addProvider (new BouncyCastleProvider ()); KeyStore jks = KeyStore.getInstance (JKS); jks.load (new FileInputStream (argv[0]), argv[2].toCharArray ()); KeyStore bks = KeyStore.getInstance (BKS); bks.load (null, null); EnumerationString aliases = jks.aliases (); while (aliases.hasMoreElements ()) { String alias = aliases.nextElement (); if (jks.isKeyEntry (alias)) { Certificate[] chain = jks.getCertificateChain (alias); Key key = jks.getKey (alias, argv[3].toCharArray ()); bks.setKeyEntry (alias, key, argv[3].toCharArray (), chain); } else if (jks.isCertificateEntry (alias)) { Certificate certificate = jks.getCertificate (alias); bks.setCertificateEntry (alias, certificate); } else { throw new Exception (Bad KS); } } bks.store (new FileOutputStream (argv[1].equals (-same) ? argv[0] : argv[1]), argv[2].toCharArray ()); } } On Nov 5, 9:02 am, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Yes that's what I see everywhere. but, i can't change my API or cartificate... So I'm destine to search search solution... I try to put a certificate in keystore, and to load it from my app. but i have an IOexception : Wrong verion of Key Store. I really don't understand. Source : KeyStore trustStore = KeyStore.getInstance(KeyStore.getDefaultType());// KeyStore.getDefaultType() FileInputStream in = new FileInputStream(new File(data/data/ com.alu.myic.android/my.trustore3)); try { trustStore.load(in, coucou.toCharArray());} finally { in.close(); } SSLSocketFactory socketFactory = new SSLSocketFactory(trustStore); SchemeRegistry registry = new SchemeRegistry(); registry.register(new Scheme(https, socketFactory, 443)); regards, SC On 4 nov, 10:09, Guillaume Perrot [EMAIL PROTECTED] wrote: We have a trusted one at our software company which is working but I wanted to add an option to trust self signed certificate in the application. I still don't have a solution for that, except using URLConnection API which works well with the AllowAllHostnameVerifier. Theproblemis with the HTTPClientAPI. 2008/11/4 [EMAIL PROTECTED] [EMAIL PROTECTED] have you success yourhttpsconnection? I don't know how to do with the not trusted certificate. thx On 23 oct, 09:23, Guillaume Perrot [EMAIL PROTECTED] wrote: Caused by: java.security.cert.CertPathValidatorException: TrustAnchor for CertPath not found. On 23 oct, 10:20, Guillaume Perrot [EMAIL PROTECTED] wrote: Yes I had, though it's not in my sample code. The verification that fails is not the hostname, but later when checking the certificate. And I didn't find a class such as AllowAllSelfSignedCertificates. 2008/10/23 Sean Sullivan [EMAIL PROTECTED] Have you tried using org.apache.http.conn.ssl.AllowAllHostnameVerifier ? http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/module-c... Sean On Oct 17, 7:07 am, Guillaume Perrot [EMAIL PROTECTED] wrote: On android 1.0 I tried to connect to myhttpsserver which uses a self- signed certificate: Here is my code, which uses a custom hostname verifier: /* Create and initialize HTTP parameters */ HttpParams params = new BasicHttpParams(); ConnManagerParams.setMaxTotalConnections(params, 2); HttpProtocolParams.setVersion(params, HttpVersion.HTTP_1_1); /* Create and initialize scheme registry */ SchemeRegistry schemeRegistry = new SchemeRegistry(); schemeRegistry.register(new Scheme(http, PlainSocketFactory .getSocketFactory(), 80)); SSLSocketFactory sslSocketFactory = SSLSocketFactory.getSocketFactory(); sslSocketFactory.setHostnameVerifier(new X509HostnameVerifier() { @Override public boolean verify(String host, SSLSession session) { return true;
[android-developers] Re: Android Database connectivity program
Hello Ram, You could try to import the MSFT JDBC driver. It is probably very big. But I would not. The best is to create a web-service that talks to SQL server and returns the stuff you asked for. Few if anybody connects to SQL server over the Internet even if it is possible. Over VPN you can do that securely but direct SQL server access is not recommendable anyway. I hope that is of some utility even if it wasn't the answer you asked for :-) Anders On Nov 5, 6:51 am, Nataraaj [EMAIL PROTECTED] wrote: Hello guys, I want to connect android application with MS - SQL Server, where can i get sample code for this? Plz provide me with an web link for the source. Regards, Ram Nataraaj --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~--~~~~--~~--~--~---