[android-developers] Something wrong here error message
I have had a few reports coming in from Droid-users using my apps and getting this error message: 11-25 16:17:44.589 W/UsageStats( 1015): Something wrong here, didn't expect (package name) to be resumed Everytime I have got an error description for this, I have never been able to reproduce the error on the emulators. Are there any good information on what exactly this error is? I have a hard time imagining what such an error message can really mean. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: ImageView with zoom, or just use WebView somehow?
I would also be really interested to know how to do this. Or how to show more then 1 image where its like the gallery view On Nov 16, 12:32 am, Mark Wyszomierski mar...@gmail.com wrote: Hi, I'd like to display a single image from the web. It'd be nice if it could be zoomable and pan-able. I was thinking of just using a WebView to do this: webView = new WebView(); webView.loadUrl(mysite.com/mypicture.jpg); but I can't force the webview to center the picture etc. Is there any other built in image viewer widget in android? I looked at Gallery and ImageSwitcher but these don't let youzoomeither. 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
Re: [android-developers] Re: Automatic permissions in my T-Mobile G1
Thanks for the answer, it make sense now ^^ 2009/11/27 Dianne Hackborn hack...@android.com http://developer.android.com/reference/android/os/Build.VERSION_CODES.html#DONUT On Thu, Nov 26, 2009 at 4:53 PM, Guillaume Perrot guillaume.p...@gmail.com wrote: READ_PHONE_STATE is not a new permission, is it ? 2009/11/26 Dianne Hackborn hack...@android.com I just replied to this. It's because a of 1.6 these are new permissions that old applications must be automatically given for compatibility. On Thu, Nov 26, 2009 at 8:34 AM, Guillaume Perrot guillaume.p...@gmail.com wrote: Same thing happens with the HTC Magic. Both phones are on Donut. I have also have this on Donut emulator but not on cupcake emulator. On 26 nov, 17:26, Guillaume Perrot guillaume.p...@gmail.com wrote: When I run any application from Eclipse on my real G1 device (a retail one, this is not a dev phone), I am granted the READ_PHONE_STATE and WRITE_EXTERNAL_STORAGE even if i don't declare them in the AndroidManisfest.xml. I actually can call TelephonyManager.getDeviceID () to retrieve the IMEI and I see these permissions in Settings - Applications. I don't have this behavior in the emulator. Does anyone have the same 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.comandroid-developers%2bunsubscr...@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.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 -- 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%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: no title bar
thanks. actually i am in a typical situation where i need to hide title bar for a screen, and show for another screen [i mean xml layout] in the same activity. Is it possible programmatically doing it ? another thing is, when titlebar is sown, can i show the title text at the center ? regards On Nov 26, 12:31 pm, Jags jag...@gmail.com wrote: Theme.NoTitleBar is predefined ? which tag it should be embedded with ? android:windownoTitle=true which tag it should be associated with ? Activity and Application refuse to take it ! On Nov 25, 11:42 pm, Dianne Hackborn hack...@android.com wrote: Or, best, set your activity to one of the no title themes, like Theme.NoTitleBar. On Wed, Nov 25, 2009 at 8:20 AM, Matthias m.kaepp...@googlemail.com wrote: call requestWindowFeature(Window.FEATURE_NO_TITLE) before calling setContentView() OR set it as part of a style definition (android:windowNoTitle=true). On Nov 25, 5:16 pm, Jags jag...@gmail.com wrote: I dont want title bar in my application, how to remove that ? in my activity ? Jagat -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- 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] How to set layout_width=wrap_content in code?
Hello, how can the xml attribute layout_width=wrap_content be set in code? Don't know where this is buried in the docs... -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 set layout_width=wrap_content in code?
http://developer.android.com/intl/fr/reference/android/view/ViewGroup.LayoutParams.html LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams ( LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT); On Nov 27, 11:06 am, Mike internet...@hotmail.com wrote: Hello, how can the xml attribute layout_width=wrap_content be set in code? Don't know where this is buried in the docs... -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 start up the native gallery app?
Maybe I'm asking the totally wrong question here: On any android phone I can press the up arrow and get a list of all the built in and install application. What is the recommended way to get a list of all these items, their icons, and their start intents. Current'y I'm using the PackageManager class. If that is a no go, then on any android phone I can long press, select shortcut, select application and a list comes up. What is the recommended way to get this list along with their icons and their start intents? 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] Cant react to home button...
How can I get my app to react when the Home button is pushed in the emulator? The back button works fine. I tried logging something every time onPause or onStop is called, but the button isn't triggering anything. How can I react to this action? I did research and know that onKeyDown won't work either. -Brandon -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: High performance access on static data: What is your approach?
Hi there, I have an additional cache where images are stored on the SD card. These are loaded pretty fast. But my data right now consists of many objects with many fields. This is a totally different use case. Of course I would not use serialization for images. ;-) Regards Marc Reichelt || http://www.marcreichelt.de/ On 25 Nov., 20:21, Streets Of Boston flyingdutc...@gmail.com wrote: I use a RandomAccessFile for a thumbnail database. Works pretty fast (i haven't done any exact benchmarking). On Nov 24, 3:09 am, Marc Reichelt mcreich...@googlemail.com wrote: Hi! I am writing a program where I have to access some static data, and now I am looking for the best method of how to include them into the project. This is what I found out by now: 1. Reading in the data by parsing an XML is *slow* (even using the SAX parser). 2. Reading the data by parsing a CSV file is faster than loading an XML, but again is too slow. 3. Putting the data into a Java file directly (e.g. by defining an array) fails because Dalvik says it is too large. 4. Reading in the data using serialization is slow. The funny thing here is: It takes a bit longer than loading the XML file. 5. Reading in the data from a SQLite database is the fastest method until now. But a bad workaround is needed: A SQLite DB can not yet be read directly from the resources, but instead has to be copied to the cache or to the SD card - even for read-only access. Right now I am using method 5, but I would really like to use a more simplified and faster solution. What I found out: Unserialization in Java is *fast* (reading a HashMap with 5000 integers and strings in 79ms on my PC), while the same action on my G1 takes over 13500ms. I know that I can not compare a PC to a mobile device. But still, there seems to be a big difference here. I think that the JRE directly copies the serialized data to RAM, while Dalvik seems to read every object step by step. Is this going to change in the future? And, most interestingly: what do you do to access lots of static information? Thanks in advance happy hacking Marc Reichelt || http://www.marcreichelt.de/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Cant react to home button...
dapaintballer331 wrote: How can I get my app to react when the Home button is pushed in the emulator? You can't. Activities do not receive this key event. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Consulting/App Development: http://commonsware.com/consulting -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: How to start up the native gallery app?
pcm2a wrote: Maybe I'm asking the totally wrong question here: On any android phone I can press the up arrow and get a list of all the built in and install application. What is the recommended way to get a list of all these items, their icons, and their start intents. Current'y I'm using the PackageManager class. If that is a no go, then on any android phone I can long press, select shortcut, select application and a list comes up. What is the recommended way to get this list along with their icons and their start intents? http://github.com/commonsguy/cw-advandroid/tree/master/Introspection/Launchalot/ The Gallery application shows up in the Launchalot list for the Google Ion and the Motorola DROID. HTC Sense devices (Hero, Tattoo) do not have a Gallery, hence it will not show up. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Consulting/App Development: http://commonsware.com/consulting -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Walking by dates using Calendar
Next day, Previous day using Calendar There are two method to increase/decrease date. add() and roll() methods. But use: calendar.add(Calendar.DAY_OF_MONTH, -1); // go to previous day calendar.add(Calendar.DAY_OF_MONTH, 1); // go to next day not calendar.roll(Calendar.DAY_OF_MONTH, -1); // set previous day without month changes for example: calendar.add(): before : 31.12.2009 after 01.01.2010 calendar.roll() before : 31.12.2009 after 01.12.2009 founded: http://developer.android.com/reference/java/util/Calendar.html -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Detect/intercept screen turning off
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Is there any way where I can detect that the screen is about to turn off, so I can do some work *before* it happens? I need this to work around bug 3755: OpenGL apps sometimes crash when the screen gets turned off because they don't get surfaceDestroyed()/surfaceCreated() events. http://code.google.com/p/android/issues/detail?id=3755 Simply put, I need to shut down OpenGL before the phone has a chance to detach the GPU. The only events I seems to be getting when the screen turns off are onPause() and onWindowFocusChanged()... both of which turn up *after* the GPU detaches, by which time it's too late. Can anyone suggest any way of doing this? (In desperation, I have tried to intercept the power key, but the power/hangup key is treated specially and doesn't generate keyboard events...) - -- ┌─── dg@cowlark.com ─ http://www.cowlark.com ─ │ │ Sufficiently advanced incompetence is indistinguishable from │ malice. -- Vernon Schryver -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAksPvFIACgkQf9E0noFvlzioGACfW5r72xNXqykHvSu4SocKo0bw rlkAoLNa6NZiWgczIBHtLmgJmzFZLiaR =HOwY -END PGP SIGNATURE- -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: wvga854 avd screen size problem?
You app probably runs in compatibility mode, presenting a lower virtual resolution and then scaling all graphics up to the actual device resolution. For more information, see the supports-screens manifest element: http://developer.android.com/sdk/android-1.6.html and: http://developer.android.com/guide/topics/manifest/supports-screens-element.html The abundance of Android phones is something we (as Android developers) have to live with. I think of it as a mixed blessing: because of the many Android phones the target audience is much bigger than would be the case with a single phone. Because of this the Android platform has a fighting chance to become one of the dominant mobile platforms. Only then Android can become a viable platform for profitable software development. On Nov 27, 7:21 am, feeling3_4 lanwen.ban...@gmail.com wrote: Hi, all I have a problem with the wvga854 avd screen size. When my application running on this avd, it does not use the layout-hdpi-v6, but uses the layout-mdpi-v6. To make it clearer, I add the below code. it prints that the screen size of the wvga854 avd is 320x569 ! Why? Display display = ((WindowManager) getSystemService (Context.WINDOW_SERVICE)).getDefaultDisplay(); int device_width = display.getWidth(); int device_height = display.getHeight(); Log.i(screen, device width is + device_width); Log.i(screen, device height is + device_height); My develop environment is Mac ox + android 2.0 sdk. I begin to suffer more and more pain of these problems... does it have to have so many different kinds of android phones on the world? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 fill paricular portion of text content with chosen color
On Nov 27, 8:54 am, Dexter#39;s Brain coomar@gmail.com wrote: Well, for a textview, you cannot fetch the characters on which the mouse is residing. yes, you can see docs about text layouts pskink -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Re: no title bar
another thing is, when titlebar is sown, can i show the title text at the center ? Extending the default theme and overriding WindowTitle's android:gravity doesn't work -- there's an issue about that: http://code.google.com/p/android/issues/detail?id=4395 One workaround is to replace the title using setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.custom_title). The custom_title with gravity=center works. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Need Help with the android:weightSum and layout_weight attributes
Thanks to all, it worked. You can only guess how much time you saved me. Good Luck On Nov 26, 8:38 pm, Romain Guy romain...@google.com wrote: Using 0px is mostly an optimization. It is not required. On Nov 26, 2009 5:16 PM, steelbytes lo...@steelbytes.com wrote: I think you have to set the width of each item to 0px. then the weighting will override this? seems to work for me. It's a shame that the docs are so spartan. On Nov 27, 4:41 am, Romain Guy romain...@google.com wrote: Hi, What doesn't work exactly? W... roman.businesst...@gmail.com wrote: I have a simple horizontal linear_layout with bunch of ... romain...@android.com Note: please don't send private questions to me, as I don't have time to provide private suppo... 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... -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 test if app is shown on Market for all screensizes
Now that the new Motorola Milestone Phones came out in Germany (aka Droid in the US) we, too, are facing the problem of users not seeing our application in the market. Our settings: uses-sdk android:minSdkVersion=3 / supports-screens android:smallScreens=true android:normalScreens=true android:largeScreens=true android:anyDensity=false / No CAMERA-permission. Copy-Protection active. The customer is using the standard Milestone ROM. He doesn't see our application (GeOrg) in the market, while his partner does with an older phone. We already have some Droid-users, who succesfully installed our application, so I really cannot see that it's caused by our manifest... I mean, aren't Milestone and Droid kind of twins? Any help would be very much appreciated. Ralf On 18 Nov., 10:58, blindfold seeingwithso...@gmail.com wrote: Same thing with me, I have copy protection turned off in Android Market. It would be good now to get some feedback from Google or HTC on whether it is a bug. On Nov 18, 9:54 am, Klaus Kartou kar...@gmail.com wrote: We haven't turned copy protection on for our app, and it is still not visible on HTCTattoo/HTC Dragon. Please, Google is this a known issue? On Tue, Nov 17, 2009 at 11:02 AM, Aspidoff aspid...@gmail.com wrote: I noticed this problem when the new Droid Eris came out. At first, i started messing with minsdk and even lowered it to 2 but that didnt fix it, the apps didnt show up in the market. I ran through Verizon and Sprint stores for days to try to get this to work. I dont think Google people even know the problem exist. I am surprised that this problem hasnt been fixed for such a long time now. Anyway, the reason why you can 't see your app on HTC Hero/Eris or any other 1.5 phones is because you have copy protection set to On. You can turn this off in your developer console when logged in to your Android Market account and editing your application description/title cheers! On Nov 17, 1:19 am, Klaus Kartou kar...@gmail.com wrote: Is there any Google people that can shed some light on this issue? On Mon, Nov 16, 2009 at 4:42 PM, blindfold seeingwithso...@gmail.com wrote: Thanks Phil! Indeed this is very strange. As I understand it, all Android 1.6 apps should by default be visible to HTCTattooon the Android Market, and use of the camera should not matter. I had even tested my app to show OK on a 240x320 screen using the emulator, and cannot think of anything else to correct. I was thinking of trying an empty supports- screens element in case documentation is ambiguous, but even so it would not seem to make sense to have the CAMERA dependency. Hopefully HTC or Android developers (Romain?) will figure it out soon, because this kind of market fragmentation seems unnecessary. On Nov 16, 9:55 am, phil philipp.bre...@gmail.com wrote: Hi Blindfold, We were not able to find The vOICE for Android in the Market on the Tattoo. But we found it on the HTC Magic in the Market. Hope there will be a solution for this issue soon. On Nov 15, 8:21 am, blindfold seeingwithso...@gmail.com wrote: OK, I didn't know that. My curiosity was triggered by Phil with the suggested role of the CAMERA permission in having apps be visible on the Market, which AFAIK should not have made any difference. Also, android:minSdkVersion=4 (Android 1.6) according to documentation implies that all screensizes are assumed supported: http://d.android.com/guide/practices/screens_support.htmlIf android:minSdkVersion or android:targetSdkVersion is 4 (Android 1.6) or higher, the default value for everything is true. So I expected that basically only visibility of (unadapted for screensize) Android 1.5 apps on the Market would be affected, without any role for android.permission.CAMERA, and I would otherwise be surprised. BTW, lots of HTCTattoobuyers seem annoyed, judging fromhttp:// androinica.com/2009/10/11/htc-tattoos-android-market-will-not-... where it is stated that even Google's own Listen, My Tracks and Sky Map are (were?) not visible on Android Market for users of the HTCTattoo. On Nov 14, 11:39 pm, Klaus Kartou kar...@gmail.com wrote: Hi Blindfold, Sorry I dont have a HTCTattooto test :( Thats our problem...some users reported that they couldnt find our app on Market with their Tattoo. But we have no idea why? To Edward: HTCTattoohas a camera, so that cannot be the reason our apps are not showing. What to do? :D Cheers On Sat, Nov 14, 2009 at 10:46 PM, Edward Falk ed.f...@gmail.com wrote: Oh, and more importantly, the Android market should have a tool that allows
Re: [android-developers] Re: How to test if app is shown on Market for all screensizes
rflexor wrote: Now that the new Motorola Milestone Phones came out in Germany (aka Droid in the US) we, too, are facing the problem of users not seeing our application in the market. snip Copy-Protection active. Turning off Android Market copy protection has worked for others, though I'm not sure specifically with the Milestone. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Training in Germany, 18-22 January 2010: http://bignerdranch.com -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] What is the use of task switcher ?
Hi all, Why is task switcher(Which appears when we press home button for long time) provided. We have application launcher ,from where we can launch any applications. Then what is the need of the task switcher. Even though some task are not running , still appearing in task switcher. How does Task switcher really work? What is the switching mechanism used in task switcher, whether stack or linked list or any other? Any help would be appreciated highly. Regards, -Siva. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 test if app is shown on Market for all screensizes
Same with me. App uses Camera, but is not copy protected. supports-screens entries in manifest are there and true. minSDK=3 targetSDK=4 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: What is the use of task switcher ?
I've heard it called the recent activities window as well. That naming makes more sense to me than task switcher because it shows recent activities even if they have been force stopped and runs them fine when selected. On Nov 27, 8:34 am, pink 444 pnk...@gmail.com wrote: Hi all, Why is task switcher(Which appears when we press home button for long time) provided. We have application launcher ,from where we can launch any applications. Then what is the need of the task switcher. Even though some task are not running , still appearing in task switcher. How does Task switcher really work? What is the switching mechanism used in task switcher, whether stack or linked list or any other? Any help would be appreciated highly. Regards, -Siva. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 activity without mention in androidmanifestfile
Hi, I want to start an activity without mention it in AndroidManifest.xml file.Is it possible,If so how it is Give me me a sample code, I have tried the following but it throws exception activity not found Intent i=new Intent(); ComponentName cn=new ComponentName(com.android.Layout,com.android.Layout.spinnners);//packagename,activityname i.setComponent(cn); i.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); 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
Re: [android-developers] start activity without mention in androidmanifestfile
saikiran n wrote: I want to start an activity without mention it in AndroidManifest.xml file. All activities have to be declared in the manifest. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android 1.6 Programming Books: http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] What is the use of task switcher ?
On Fri, Nov 27, 2009 at 14:34, pink 444 pnk...@gmail.com wrote: Why is task switcher(Which appears when we press home button for long time) provided. We have application launcher ,from where we can launch any applications. What is interesting is you do not have to go back to Home. (which would have to come back in memory which can be really resource consuming -ie. if it had been killed due to low memory-) -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: wvga854 avd screen size problem?
Pieter, thank you for your reply. I am a little confused here. please see the two images below http://www.screencast.com/t/ZGZlZjVhO (this one is wvga854 avd under Mac os + android skd 2.0) http://www.screencast.com/t/NTYzYmJh (this is wvga854 avd under Windows + android sdk 2.0) Why the density between the two avds are so different? and under the windows, the screen size is 480*854 On Nov 27, 8:06 pm, Pieter pie...@gamesquare.nl wrote: You app probably runs in compatibility mode, presenting a lower virtual resolution and then scaling all graphics up to the actual device resolution. For more information, see the supports-screens manifest element:http://developer.android.com/sdk/android-1.6.html and:http://developer.android.com/guide/topics/manifest/supports-screens-e... The abundance of Android phones is something we (as Android developers) have to live with. I think of it as a mixed blessing: because of the many Android phones the target audience is much bigger than would be the case with a single phone. Because of this the Android platform has a fighting chance to become one of the dominant mobile platforms. Only then Android can become a viable platform for profitable software development. On Nov 27, 7:21 am, feeling3_4 lanwen.ban...@gmail.com wrote: Hi, all I have a problem with the wvga854 avd screen size. When my application running on this avd, it does not use the layout-hdpi-v6, but uses the layout-mdpi-v6. To make it clearer, I add the below code. it prints that the screen size of the wvga854 avd is 320x569 ! Why? Display display = ((WindowManager) getSystemService (Context.WINDOW_SERVICE)).getDefaultDisplay(); int device_width = display.getWidth(); int device_height = display.getHeight(); Log.i(screen, device width is + device_width); Log.i(screen, device height is + device_height); My develop environment is Mac ox + android 2.0 sdk. I begin to suffer more and more pain of these problems... does it have to have so many different kinds of android phones on the world? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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?
hi .. guys .. iam too excited kindly send me one inviteee... thanks .. email id : sheik...@gmail.com regards Sheik On Nov 10, 12:12 am, shobhit kasliwal shobhit.kasli...@gmail.com wrote: Hi I also want one google wave invite if you have one My Email id is shobhit.kasli...@gmail.com Thanks Shobhit On Sat, Nov 7, 2009 at 1:46 AM, fairfriend shaheryar.a...@gmail.com wrote: please gimme one as well, i damn like google wave... shaheryar.a...@gmail.com Thanks, Google Rocks On Nov 7, 5:11 am, Braders dataextr...@hotmail.com wrote: Hi, I would love a Google Wave invite, my email is seobrad...@googlemail.com I would be so gratefull if you could dominate me. Hope you dont mind the post, thanks for your time. Simon Bradley On Nov 7, 12:50 am, Lorys Pognon pognonlo...@gmail.com wrote: Hi I would like to have one On Sun, Nov 1, 2009 at 7:20 AM, 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.comandroid-developers%2bunsubscr...@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.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Shobhit Kasliwal Application Developer Liventus Designs 3400 Dundee Rd Northbrook IL 60062 skasli...@liventus.com office: 847-291-1395 ext. 192 Cell: (309) 826 4709 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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?
i like to have one googlewave account . kindly send me one , please .. thanks .. email id : sheik...@gmail.com regards Sheik On Nov 10, 12:12 am, shobhit kasliwal shobhit.kasli...@gmail.com wrote: Hi I also want one google wave invite if you have one My Email id is shobhit.kasli...@gmail.com Thanks Shobhit On Sat, Nov 7, 2009 at 1:46 AM, fairfriend shaheryar.a...@gmail.com wrote: please gimme one as well, i damn like google wave... shaheryar.a...@gmail.com Thanks, Google Rocks On Nov 7, 5:11 am, Braders dataextr...@hotmail.com wrote: Hi, I would love a Google Wave invite, my email is seobrad...@googlemail.com I would be so gratefull if you could dominate me. Hope you dont mind the post, thanks for your time. Simon Bradley On Nov 7, 12:50 am, Lorys Pognon pognonlo...@gmail.com wrote: Hi I would like to have one On Sun, Nov 1, 2009 at 7:20 AM, 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.comandroid-developers%2bunsubscr...@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.comandroid-developers%2bunsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -- Shobhit Kasliwal Application Developer Liventus Designs 3400 Dundee Rd Northbrook IL 60062 skasli...@liventus.com office: 847-291-1395 ext. 192 Cell: (309) 826 4709 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Use Camera API for normal quality pictures
I'm using the default camera API of Android 1.6 like this: Intent photoIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); photoIntent.putExtra(MediaStore.EXTRA_OUTPUT, Uri.fromFile(new File (Environment.getExternalStorageDirectory(), test.jpg))); startActivityForResult(photoPickerIntent, 1); But the image is saved on very low resolution 512 x 348. I added the QUALITY property but it doesn't make sence: photoPickerIntent.putExtra(MediaStore.EXTRA_VIDEO_QUALITY, 1); There are many more posts on the internet talking about this issue but there's no solution (jet). Is it solved on 2.0??? I realy need the high resolution image (3MP). Thanks in advance, Ben -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Rotate TextView 90 degrees text out of view.
Sorry, my fault. Still it doesn't work. When rotated, the canvas hight still seems to be the TextView width. Does anyone has a solution? Thanks, Ben On 17 nov, 12:07, benbenbenben bengr...@hotmail.com wrote: I just changed the textsize to 14 and now it works great! Also with size 10, only not with size 12. Bug? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 test if app is shown on Market for all screensizes
Are you talking about Droid, Milestone or HTC Tattoo here? Thus far there seem to be 2 separate patterns: apps can be invisible on the Market for Droid and Milestone when copy protection is on, OR apps can be invisible on the Market for HTC Tattoo when the CAMERA permission is used. On Nov 27, 3:48 pm, Marcus marcus.ter...@gmail.com wrote: Same with me. App uses Camera, but is not copy protected. supports-screens entries in manifest are there and true. minSDK=3 targetSDK=4 -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Pixel Format Conversion in SF
Thanks Dianne so much for your reply. So let's say in my example I am working with SurfaceView for my CameraSurfaceView. I have a few questions, hope you can help me. 1. When this SurfaceView gets created (I assume via final CameraSurfaceView cameraView = new CameraSurfaceView (getApplicationContext()), this will result in a call createSurface() in SurfaceFlinger with format, width and height. How does the application pass these information like format, width and height to SurfaceFlinger for the allocation? Is it by using .setFormat, .setFixedSize? 2. How do they methods .setFormat, .setFixedSize related to the surfaceHolder.surfaceChanged() callback? On Nov 26, 5:41 pm, Dianne Hackborn hack...@android.com wrote: It totally depends. It may be surface flinger, it may be an overlay that is YUV, etc. On Thu, Nov 26, 2009 at 2:39 PM, android-newbie k...@itsaver.com wrote: I am looking at the source code of a Camera Preview application and learning that the preview buffers coming from the sensor is in YUV422 format. However, this preview frame is showed on the display in RGB. Can someone please let me know where the pixel format conversion happens? Is it inside Surface Flinger? If yes, can you please point me to the code? Thank you very much for your help, an -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them.- Hide quoted text - - Show quoted text - -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] UI window in Camera Preview application
Let's say in my example I am working with SurfaceView for my CameraSurfaceView. I have a few questions, hope you can help me. 1. When this SurfaceView gets created (I assume via final CameraSurfaceView cameraView = new CameraSurfaceView (getApplicationContext()), this will result in a call createSurface() in SurfaceFlinger with format, width and height. Am I correct? Is this SurfaceView also my UI window if I want to draw anything? I thought if I call setType(PUSH_BUFFER) on this surface, I won't be able to do any drawing on this surface. Can someone please help me to understand this? 2. How does the application pass these information like format, width and height to SurfaceFlinger for the allocation? Is it by using .setFormat, .setFixedSize? 3. How do they methods .setFormat, .setFixedSize related to the surfaceHolder.surfaceChanged() callback? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 Calculate Temperature
Hi I want to determine temperature of my phone based SensorManager? In Sensor we have a SENOR_TEMPERATURE! How i can use it? Regards SIDIBE Ali-Broma -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Reference external lib resources?
Hey Guys, I hope you can help. I'm trying to reference a resource of an external JAR file in my android manifest to be used as an icon for the application. Does anyone know the correct syntax? I am using something like shown below but it doesn't work as it assumes this to be a string. Is there a way to point at these resources? application android:icon=com.sample.android.config/@drawable/icon Thanks for the help! Tom -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Selector with the ImageView?
Is there any way to use the selector drawable with the ImageView instead of the ImageButton ( http://developer.android.com/reference/android/widget/ImageButton.html )? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] How to Calculate Temperature
SIDIBE Ali-Broma wrote: I want to determine temperature of my phone based SensorManager? In Sensor we have a SENOR_TEMPERATURE! How i can use it? There are no devices that support that sensor, AFAIK. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android App Developer Books: http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Reference external lib resources?
Loki117 wrote: I hope you can help. I'm trying to reference a resource of an external JAR file in my android manifest to be used as an icon for the application. That is not possible, insofar as Android resources cannot be contained in JAR files. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android App Developer Books: http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] toast
How can I keep Toast from building up a queue of messages? I'm working on a board game and I'm sending status messages back to the user with this wrapper function I created for Toast: private void toast( String s ) { if( t != null ) t.cancel(); t = Toast.makeText( getApplicationContext(), s, Toast.LENGTH_SHORT ); t.show(); } The problem is I've made the flow of game play so simple I can now play it so fast Toast messages queue up, even to the point where they continue to show on the desktop after I quit out of the game. t.cancel() doesn't seem to cancel out the previous message, anyone know what I might be doing wrong? Thanks, -- Greg Donald http://destiney.com/ -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Reference external lib resources?
Yeah just read some other posts you had placed on the subject thanks for that Mark. Seems like such a horrible restriction though back the drawing board I guess. On Nov 27, 12:02 pm, Mark Murphy mmur...@commonsware.com wrote: Loki117 wrote: I hope you can help. I'm trying to reference a resource of an external JAR file in my android manifest to be used as an icon for the application. That is not possible, insofar as Android resources cannot be contained in JAR files. -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android App Developer Books:http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Crashed Service not restarting - TasKiller or Android issue ?
Hi Diane, We've have exactly the same problem. We have TasKiller v2.2 installed but we DO NOT use it to kill our app. However, our service (running every one minute thanks to AlarmManager) never restarts after process has died. Here are the log extracted today on my HTC device under 1.6: [...] 11-27 18:14:00.463: INFO/abc.RefreshService(1482): Alarm planned in 6 milliseconds at 125934210 (abc.refreshserv...@431e8178 - PendingIntent{431f71f8: android.os.binderpr...@431f71b0}) 11-27 18:14:00.463: INFO/abc.RefreshService(1482): RefreshService stopping (abc.refreshserv...@431e8178) 11-27 18:14:00.463: INFO/ActivityManager(74): Stopping service: abc/.xyz.RefreshService [...] 11-27 18:15:07.629: INFO/ActivityManager(74): Process abc (pid 1482) has died. 11-27 18:15:07.679: WARN/ActivityManager(74): Scheduling restart of crashed service abc/.xyz.RefreshService in 5000ms [...] 11-27 18:19:26.131: INFO/ActivityManager(74): Start proc abc for service abc/.xyz.RefreshService: pid=1536 uid=10033 gids={3003, 1015} 11-27 18:19:26.241: INFO/dalvikvm(1536): Debugger thread not active, ignoring DDM send (t=0x41504e4d l=38) [...] Do you mean that the problem could come from TaskKiller application ? Once problem has occurred I still can see our app in TasKiller as Italic/grayed (which means that a service is running in background) or yellow. Thanks. On Nov 22, 8:53 pm, Dianne Hackborn hack...@android.com wrote: That's what the task killers do. Don't use them if you don't want this to happen. You can't get around this. The API they are using is intended for the user to explicitly stop everything about an app. On Sat, Nov 21, 2009 at 6:53 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: Hi, I'm just investing how crashed services are restarted. I've developed a simple service and use a taskkiller from market place to kill the application. Following are the logs after application is killed Uninstalling the process test.sys Force removing process ProcessRecord{432d6ad0 252:test.sys/10041} (test.sys/10041) Scheduling restart of crashed service test.sys/.testservice in 5000ms Sending signal. PID: 252 SIG: 9 But the service is never started. Can anybody tell why service is not starting? Do i need to put any flag in manifest file for service restart to work? Regards, shaz -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- 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
Re: [android-developers] Re: Android in China - What is going on?
I will not go into details as why Chinese gov't blocking this and that, there are many reasons, and you certainly cannot hold Google accountable for the problems you have. Anyway, edit /system/etc/hosts, add 74.125.93.113 android.clients.google.com to your Android phone, and you are good to go. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Crashed Service not restarting - TasKiller or Android issue ?
Hi, Taskiller use ActivityManager to kill process (there is no kill but uninstall process). If I kill taskiller itselfs, the log are: 11-27 19:16:58.952 I/ActivityManager( 75): Displayed activity com.tni.TasKiller/.TasKiller: 2023 ms (total 2023 ms) 11-27 19:16:59.032 I/ActivityManager( 75): Process com.android.settings (pid 4361) has died. 11-27 19:17:05.212 D/dalvikvm( 2816): GC freed 2448 objects / 115688 bytes in 175ms 11-27 19:17:12.842 D/ActivityManager( 75): Uninstalling process com.tni.TasKiller 11-27 19:17:12.842 D/ActivityManager( 75): Force removing process ProcessRecord{43678608 4341:com.tni.TasKiller/10030} (com.tni.TasKiller/10030) If your service die without this log, Taskiller is not guilty ! And if your service is killed by taskiller : the user HOPE it will NEVER restart. On Nov 27, 7:01 pm, Derek cram.de...@gmail.com wrote: Hi Diane, We've have exactly the same problem. We have TasKiller v2.2 installed but we DO NOT use it to kill our app. However, our service (running every one minute thanks to AlarmManager) never restarts after process has died. Here are the log extracted today on my HTC device under 1.6: [...] 11-27 18:14:00.463: INFO/abc.RefreshService(1482): Alarm planned in 6 milliseconds at 125934210 (abc.refreshserv...@431e8178 - PendingIntent{431f71f8: android.os.binderpr...@431f71b0}) 11-27 18:14:00.463: INFO/abc.RefreshService(1482): RefreshService stopping (abc.refreshserv...@431e8178) 11-27 18:14:00.463: INFO/ActivityManager(74): Stopping service: abc/.xyz.RefreshService [...] 11-27 18:15:07.629: INFO/ActivityManager(74): Process abc (pid 1482) has died. 11-27 18:15:07.679: WARN/ActivityManager(74): Scheduling restart of crashed service abc/.xyz.RefreshService in 5000ms [...] 11-27 18:19:26.131: INFO/ActivityManager(74): Start proc abc for service abc/.xyz.RefreshService: pid=1536 uid=10033 gids={3003, 1015} 11-27 18:19:26.241: INFO/dalvikvm(1536): Debugger thread not active, ignoring DDM send (t=0x41504e4d l=38) [...] Do you mean that the problem could come from TaskKiller application ? Once problem has occurred I still can see our app in TasKiller as Italic/grayed (which means that a service is running in background) or yellow. Thanks. On Nov 22, 8:53 pm, Dianne Hackborn hack...@android.com wrote: That's what the task killers do. Don't use them if you don't want this to happen. You can't get around this. The API they are using is intended for the user to explicitly stop everything about an app. On Sat, Nov 21, 2009 at 6:53 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: Hi, I'm just investing how crashed services are restarted. I've developed a simple service and use a taskkiller from market place to kill the application. Following are the logs after application is killed Uninstalling the process test.sys Force removing process ProcessRecord{432d6ad0 252:test.sys/10041} (test.sys/10041) Scheduling restart of crashed service test.sys/.testservice in 5000ms Sending signal. PID: 252 SIG: 9 But the service is never started. Can anybody tell why service is not starting? Do i need to put any flag in manifest file for service restart to work? Regards, shaz -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Crashed Service not restarting - TasKiller or Android issue ?
Hi Nicolas, Thanks for the feedback. I've double checked the logs and I don't see anything about TasKiller when the process has died. In the meantime I've read the following thread about developers complaining about Task killers applications (not yours especially). http://groups.google.com/group/android-developers/browse_thread/thread/3f87972d1f99ee81/e28b5180bb404a79 (Our users complain that widget updates stop too) So, I've uninstalled TaskKiller, run GoogleMaps to generate a process kill from Android. Here are the logs just after GoogleMaps starting: [...] 11-27 19:25:47.494: INFO/ActivityManager(74): Process abc (pid 3509) has died. [...] 11-27 19:26:00.044: INFO/ActivityManager(74): Start proc abc for service abc/.xyz.RefreshService: pid=3603 uid=10033 gids={3003, 1015} [...] 11-27 19:26:00.424: INFO/abc.xyz.RefreshService(3603): RefreshService started (abc.xyz.refreshserv...@431f1d38) [...] It seems to work now. The only difference is that the following trace does not appear: Scheduling restart of crashed service abc/.xyz.RefreshService in 5000ms. Could it be a bug in your application ? or in the Android API you're using to monitor running processes ? It may prevent a service from restart. Is there any test I can do to make sure ? Thanks again. On Nov 27, 7:25 pm, Nicolas Thibaut nthibau...@gmail.com wrote: Hi, Taskiller use ActivityManager to kill process (there is no kill but uninstall process). If I kill taskiller itselfs, the log are: 11-27 19:16:58.952 I/ActivityManager( 75): Displayed activity com.tni.TasKiller/.TasKiller: 2023 ms (total 2023 ms) 11-27 19:16:59.032 I/ActivityManager( 75): Process com.android.settings (pid 4361) has died. 11-27 19:17:05.212 D/dalvikvm( 2816): GC freed 2448 objects / 115688 bytes in 175ms 11-27 19:17:12.842 D/ActivityManager( 75): Uninstalling process com.tni.TasKiller 11-27 19:17:12.842 D/ActivityManager( 75): Force removing process ProcessRecord{43678608 4341:com.tni.TasKiller/10030} (com.tni.TasKiller/10030) If your service die without this log, Taskiller is not guilty ! And if your service is killed by taskiller : the user HOPE it will NEVER restart. On Nov 27, 7:01 pm, Derek cram.de...@gmail.com wrote: Hi Diane, We've have exactly the same problem. We have TasKiller v2.2 installed but we DO NOT use it to kill our app. However, our service (running every one minute thanks to AlarmManager) never restarts after process has died. Here are the log extracted today on my HTC device under 1.6: [...] 11-27 18:14:00.463: INFO/abc.RefreshService(1482): Alarm planned in 6 milliseconds at 125934210 (abc.refreshserv...@431e8178 - PendingIntent{431f71f8: android.os.binderpr...@431f71b0}) 11-27 18:14:00.463: INFO/abc.RefreshService(1482): RefreshService stopping (abc.refreshserv...@431e8178) 11-27 18:14:00.463: INFO/ActivityManager(74): Stopping service: abc/.xyz.RefreshService [...] 11-27 18:15:07.629: INFO/ActivityManager(74): Process abc (pid 1482) has died. 11-27 18:15:07.679: WARN/ActivityManager(74): Scheduling restart of crashed service abc/.xyz.RefreshService in 5000ms [...] 11-27 18:19:26.131: INFO/ActivityManager(74): Start proc abc for service abc/.xyz.RefreshService: pid=1536 uid=10033 gids={3003, 1015} 11-27 18:19:26.241: INFO/dalvikvm(1536): Debugger thread not active, ignoring DDM send (t=0x41504e4d l=38) [...] Do you mean that the problem could come from TaskKiller application ? Once problem has occurred I still can see our app in TasKiller as Italic/grayed (which means that a service is running in background) or yellow. Thanks. On Nov 22, 8:53 pm, Dianne Hackborn hack...@android.com wrote: That's what the task killers do. Don't use them if you don't want this to happen. You can't get around this. The API they are using is intended for the user to explicitly stop everything about an app. On Sat, Nov 21, 2009 at 6:53 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: Hi, I'm just investing how crashed services are restarted. I've developed a simple service and use a taskkiller from market place to kill the application. Following are the logs after application is killed Uninstalling the process test.sys Force removing process ProcessRecord{432d6ad0 252:test.sys/10041} (test.sys/10041) Scheduling restart of crashed service test.sys/.testservice in 5000ms Sending signal. PID: 252 SIG: 9 But the service is never started. Can anybody tell why service is not starting? Do i need to put any flag in manifest file for service restart to work? Regards, shaz -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to
Re: [android-developers] Re: Crashed Service not restarting - TasKiller or Android issue ?
Fyi, you can use adb shell dumpsys activity.services to see the state of all active services, including those that are started but not currently running and waiting for a restart. On Fri, Nov 27, 2009 at 10:44 AM, Derek cram.de...@gmail.com wrote: Hi Nicolas, Thanks for the feedback. I've double checked the logs and I don't see anything about TasKiller when the process has died. In the meantime I've read the following thread about developers complaining about Task killers applications (not yours especially). http://groups.google.com/group/android-developers/browse_thread/thread/3f87972d1f99ee81/e28b5180bb404a79 (Our users complain that widget updates stop too) So, I've uninstalled TaskKiller, run GoogleMaps to generate a process kill from Android. Here are the logs just after GoogleMaps starting: [...] 11-27 19:25:47.494: INFO/ActivityManager(74): Process abc (pid 3509) has died. [...] 11-27 19:26:00.044: INFO/ActivityManager(74): Start proc abc for service abc/.xyz.RefreshService: pid=3603 uid=10033 gids={3003, 1015} [...] 11-27 19:26:00.424: INFO/abc.xyz.RefreshService(3603): RefreshService started (abc.xyz.refreshserv...@431f1d38) [...] It seems to work now. The only difference is that the following trace does not appear: Scheduling restart of crashed service abc/.xyz.RefreshService in 5000ms. Could it be a bug in your application ? or in the Android API you're using to monitor running processes ? It may prevent a service from restart. Is there any test I can do to make sure ? Thanks again. On Nov 27, 7:25 pm, Nicolas Thibaut nthibau...@gmail.com wrote: Hi, Taskiller use ActivityManager to kill process (there is no kill but uninstall process). If I kill taskiller itselfs, the log are: 11-27 19:16:58.952 I/ActivityManager( 75): Displayed activity com.tni.TasKiller/.TasKiller: 2023 ms (total 2023 ms) 11-27 19:16:59.032 I/ActivityManager( 75): Process com.android.settings (pid 4361) has died. 11-27 19:17:05.212 D/dalvikvm( 2816): GC freed 2448 objects / 115688 bytes in 175ms 11-27 19:17:12.842 D/ActivityManager( 75): Uninstalling process com.tni.TasKiller 11-27 19:17:12.842 D/ActivityManager( 75): Force removing process ProcessRecord{43678608 4341:com.tni.TasKiller/10030} (com.tni.TasKiller/10030) If your service die without this log, Taskiller is not guilty ! And if your service is killed by taskiller : the user HOPE it will NEVER restart. On Nov 27, 7:01 pm, Derek cram.de...@gmail.com wrote: Hi Diane, We've have exactly the same problem. We have TasKiller v2.2 installed but we DO NOT use it to kill our app. However, our service (running every one minute thanks to AlarmManager) never restarts after process has died. Here are the log extracted today on my HTC device under 1.6: [...] 11-27 18:14:00.463: INFO/abc.RefreshService(1482): Alarm planned in 6 milliseconds at 125934210 (abc.refreshserv...@431e8178 - PendingIntent{431f71f8: android.os.binderpr...@431f71b0}) 11-27 18:14:00.463: INFO/abc.RefreshService(1482): RefreshService stopping (abc.refreshserv...@431e8178) 11-27 18:14:00.463: INFO/ActivityManager(74): Stopping service: abc/.xyz.RefreshService [...] 11-27 18:15:07.629: INFO/ActivityManager(74): Process abc (pid 1482) has died. 11-27 18:15:07.679: WARN/ActivityManager(74): Scheduling restart of crashed service abc/.xyz.RefreshService in 5000ms [...] 11-27 18:19:26.131: INFO/ActivityManager(74): Start proc abc for service abc/.xyz.RefreshService: pid=1536 uid=10033 gids={3003, 1015} 11-27 18:19:26.241: INFO/dalvikvm(1536): Debugger thread not active, ignoring DDM send (t=0x41504e4d l=38) [...] Do you mean that the problem could come from TaskKiller application ? Once problem has occurred I still can see our app in TasKiller as Italic/grayed (which means that a service is running in background) or yellow. Thanks. On Nov 22, 8:53 pm, Dianne Hackborn hack...@android.com wrote: That's what the task killers do. Don't use them if you don't want this to happen. You can't get around this. The API they are using is intended for the user to explicitly stop everything about an app. On Sat, Nov 21, 2009 at 6:53 PM, shahzad ahmad shahzad.s.ah...@gmail.comwrote: Hi, I'm just investing how crashed services are restarted. I've developed a simple service and use a taskkiller from market place to kill the application. Following are the logs after application is killed Uninstalling the process test.sys Force removing process ProcessRecord{432d6ad0 252:test.sys/10041} (test.sys/10041) Scheduling restart of crashed service test.sys/.testservice in 5000ms Sending signal. PID: 252 SIG: 9 But the service is never started. Can anybody tell why service is not starting? Do i need to put any flag in manifest file for service restart
Re: [android-developers] Re: Pixel Format Conversion in SF
Yes, you set the format and such by the setters you mentioned. The relation with surfaceChanged() is that this gets called after any such parameters have changed to provide a surface with the new configuration. On Fri, Nov 27, 2009 at 8:20 AM, android-newbie k...@itsaver.com wrote: Thanks Dianne so much for your reply. So let's say in my example I am working with SurfaceView for my CameraSurfaceView. I have a few questions, hope you can help me. 1. When this SurfaceView gets created (I assume via final CameraSurfaceView cameraView = new CameraSurfaceView (getApplicationContext()), this will result in a call createSurface() in SurfaceFlinger with format, width and height. How does the application pass these information like format, width and height to SurfaceFlinger for the allocation? Is it by using .setFormat, .setFixedSize? 2. How do they methods .setFormat, .setFixedSize related to the surfaceHolder.surfaceChanged() callback? On Nov 26, 5:41 pm, Dianne Hackborn hack...@android.com wrote: It totally depends. It may be surface flinger, it may be an overlay that is YUV, etc. On Thu, Nov 26, 2009 at 2:39 PM, android-newbie k...@itsaver.com wrote: I am looking at the source code of a Camera Preview application and learning that the preview buffers coming from the sensor is in YUV422 format. However, this preview frame is showed on the display in RGB. Can someone please let me know where the pixel format conversion happens? Is it inside Surface Flinger? If yes, can you please point me to the code? Thank you very much for your help, an -- You received this message because you are subscribed to the Google Groups Android Developers group. 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.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.- 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.comandroid-developers%2bunsubscr...@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
Re: [android-developers] Re: What is the use of task switcher ?
Correct, this is not showing running tasks, but the most recent tasks you have launched or switched to. On Fri, Nov 27, 2009 at 6:52 AM, Lance Nanek lna...@gmail.com wrote: I've heard it called the recent activities window as well. That naming makes more sense to me than task switcher because it shows recent activities even if they have been force stopped and runs them fine when selected. On Nov 27, 8:34 am, pink 444 pnk...@gmail.com wrote: Hi all, Why is task switcher(Which appears when we press home button for long time) provided. We have application launcher ,from where we can launch any applications. Then what is the need of the task switcher. Even though some task are not running , still appearing in task switcher. How does Task switcher really work? What is the switching mechanism used in task switcher, whether stack or linked list or any other? Any help would be appreciated highly. Regards, -Siva. -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- 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
Re: [android-developers] Something wrong here error message
Don't worry about it, it's not an issue. 2009/11/27 Per Sandström pg.sandst...@gmail.com I have had a few reports coming in from Droid-users using my apps and getting this error message: 11-25 16:17:44.589 W/UsageStats( 1015): Something wrong here, didn't expect (package name) to be resumed Everytime I have got an error description for this, I have never been able to reproduce the error on the emulators. Are there any good information on what exactly this error is? I have a hard time imagining what such an error message can really mean. -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- Dianne Hackborn Android framework engineer hack...@android.com Note: please don't send private questions to me, as I don't have time to provide private support, and so won't reply to such e-mails. All such questions should be posted on public forums, where I and others can see and answer them. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Copy protection bug statuses
It looks like I spoke too soon, we've had a few users on the Hero (OS 1.5) that are having the copy protection problem (i.e. crashing on startup). An uninstall/reinstall fixes the problem as before, but they lose their saved data. I've had no reports from other phones of problems yet. Could it be that the Hero build of the OS doesn't include the bug fix? I'm not sure, I'll update here if I figure anything out. On Nov 25, 1:09 pm, Matt Hall matt.h...@gmail.com wrote: A further update: We've removed the copy protection on an existing game, and done a new release and no one has reported any problems. So this bug does indeed appear to be fixed. A related note: Once we removed the copy protection our game was suddenly visible to Droid Eris users, whereas the final remaining game we have with copy protection is still invisible to them. On Nov 20, 6:57 pm, Matt Hall matt.h...@gmail.com wrote: Just a note to say that the two bugs mentioned in this thread were marked by an Android engineer as fixed in 1.5, so we've turned off copy protection and so far so good. We'll be issuing an update to the game and so we'll see how things go through that update process. I'll update here when we find out. On Nov 17, 4:17 pm, Matt Hall matt.h...@gmail.com wrote: I would also love to hear anyone's experience on 1.5+ handsets. What I would really love though is a definitive answer from Google on this issue. I don't know why this can't be addressed officially, we're not asking for secret information to be revealed here - we have to know these kinds of things to make basic decisions about what to do in the market. If I've overlooked information about this issue then I apologize, please point me in that direction as soon as possible. :) Matt On Nov 16, 5:35 pm, Dave supp...@bumptechnologies.com wrote: These two Issues seem to be identical to me. We submitted our app with copy-protection turned on (not aware of these issues, nor of the fact that some people wouldn't be able to download our app as a result). We'd now like to turn copy-protection off so everyone can use our app. But before hosing all our users running Android 1.5, it would be nice to know which release (1.5 or 1.6) actually fixed this issue. Am I misreading the two Issue reports? Has anyone switched their app from copy-protection to no copy- protection and had issues with force closes for users running Android 1.5? Thanks, -dave On Nov 12, 11:32 pm, tauntz tau...@gmail.com wrote: When a bug is marked as FutureRelease it usually means it will be fixed in the next release at the time the bug is closed. http://code.google.com/p/android/issues/detail?id=2263wasmarkedas FutureRelease @ Mar 21, 2009 so it should be fixed in Android 1.5 - that was the next version after this date (first SDK released on 13 April 2009). http://code.google.com/p/android/issues/detail?id=2047wasmarkedas FutureRelease @ Apr 20, 2009 so it should be fixed in Android 1.6 - that was the next version after this date (released on 15 September 2009). Tauno On Thu, Nov 12, 2009 at 10:28 PM, Matt Hall matt.h...@gmail.com wrote: So can I take that to mean that that the bug exists in all current releases including 2.0? I could really use some concrete info on this particular issue as it affects most of our apps and the enlarged bundle size is becoming a real problem on Droid. Thanks very much, Matt On Nov 12, 3:22 pm, Romain Guy romain...@google.com wrote: When a bug is marked as FutureRelease it usually means it will be fixed in the next release at the time the bug is closed. Anyhow, it means the bug has been fixed and will eventually reach users phones :) On Thu, Nov 12, 2009 at 9:07 AM, Neiman Buffard neimanbuff...@gmail.com wrote: ok for starters im pretty sure im not doin this right but i wanted to throw an idea at anyone who would take the time to read/listen for upgrades to come if it cant make the cut for the next one. I would like to see this done in an upgrade instead of an app only because i feel that this is somthin everyone would enjoy. BIG PICTURES i feel that When ur favorite contacts/friends call and u have a customized ring tone and possibly an assigned contact photo would it be askin to much to utilize the 3.2-inch TFT-LCD flat touch-sensitive screen with 320 x 480 (HVGA) resolution for that photo. Very simple yes i know however we are limited to that small picture with out even being givin the option as to weather you' like it that small or not. just a thought i've had for some time now that i wanted to share thanks for listening follow
Re: [android-developers] Re: how can I target api 1.6, but use packages from 2.0 (and safely)
(But there really should be little difference between GSM and CDMA, from an application's perspective.) On Fri, Nov 27, 2009 at 10:56 AM, Dianne Hackborn hack...@android.comwrote: Sorry I'm not sure what telephony stuff the emulator does. On Thu, Nov 26, 2009 at 9:55 PM, Bryan piusve...@gmail.com wrote: Thank you everyone for the helpful replies. I've used a class wrapper as detailed by the android backwards compatibility blog to add support for Droid. It runs in the 2.0 emulator as expected, though is there anyway to emulate the cdma modem? Thanks! On Nov 26, 1:42 am, Dianne Hackborn hack...@android.com wrote: You absolutely can. In fact Java gives you a lot of neat things you can do. For example, if you want to write a Service that uses the new onStartCommand() on 2.0 but still works on older versions with the old onStart(), just write it like this: @Override void onStart(Intent intent, int startId) { handleCommand(intent); } @Override void onStartCommand(Intent intent, int flags, int startId) { // Consume command, so old onStart() is not called. handleCommand(intent); } // Handle start from either old or new method. void handleCommand(Intent intent) { // ... } This article covers a lot more of what you can do: http://android-developers.blogspot.com/2009/04/backward-compatibility. .. Note that reflection is useful for simple things, but for more extensive use of APIs you can follow the wrapper class approach which works very well. You can basically have large sections of you app using newer APIs, and as long as you don't try to run those classes you will be fine. (So in fact another approach you could take is to just look at the API version and use one class code vs. another based on it.) On Wed, Nov 25, 2009 at 8:16 PM, Ravi textlo...@gmail.com wrote: My understanding is that You can't. I cloned my app for 2.0 (ofcourse you will loose your feedback and popularity) and set minSDK to 5 Catch 22: If you set min sdk to 5 aka 2.0, 1.5 1.6 can not see the app. If you set to 1.5 or 1.6 then you can not see your cdma package. On Nov 25, 9:31 pm, Bryan piusve...@gmail.com wrote: Sorry for the simple question, but I'm having trouble finding an answer. My app targets 1.5, and runs fine on my phone (1.6), but to support droid, I need the package android.telephony.cdma from 2.0. Targeting 2.0 excludes the current devices running my app (including my own G1), but as it is now, I can't support the Droid. 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.comandroid-developers%2bunsubscr...@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.comandroid-developers%2bunsubscr...@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. -- 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] Advice on keeping app running/available
I have spent a lot of time playing and researching (including subscribing to the Mark Murphy¹s CommonsGuy stuff...excellent by the way) and I think I have enough info to be dangerous. I am just having issues coming up with best practices for doing what I need to do. My app is collecting specially formatted incoming SMS messages (currently default port but will later be processing port-directed using Verizon proprietary header info). I also need a UI application that will view the current messages that have been received and allow the user to read/delete/reply. All this stuff is working at this point but I just need to make sure it keeps itself running at all times (or will always be available when needed at least). My initial thoughts were to have a service which starts at boot handle the sms messaging (in and out) and incorporate a content provider in it to provide access to the collection of messages (Sqlite) to other applications requiring it. I tried launching the service from an activity but if someone uses a task killer to kill the activity it seems to take the service down with it. I tried having a service that runs at boot but had trouble getting it to launch an activity when a new message arrives (probably my issue). So, after floundering back and forth with my indecisions of how best to architect it, I figured I would ask around to get some suggestions and then attack it from there. So, any ideas from anyone? Thanks, Carl -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: how can I target api 1.6, but use packages from 2.0 (and safely)
Sorry I'm not sure what telephony stuff the emulator does. On Thu, Nov 26, 2009 at 9:55 PM, Bryan piusve...@gmail.com wrote: Thank you everyone for the helpful replies. I've used a class wrapper as detailed by the android backwards compatibility blog to add support for Droid. It runs in the 2.0 emulator as expected, though is there anyway to emulate the cdma modem? Thanks! On Nov 26, 1:42 am, Dianne Hackborn hack...@android.com wrote: You absolutely can. In fact Java gives you a lot of neat things you can do. For example, if you want to write a Service that uses the new onStartCommand() on 2.0 but still works on older versions with the old onStart(), just write it like this: @Override void onStart(Intent intent, int startId) { handleCommand(intent); } @Override void onStartCommand(Intent intent, int flags, int startId) { // Consume command, so old onStart() is not called. handleCommand(intent); } // Handle start from either old or new method. void handleCommand(Intent intent) { // ... } This article covers a lot more of what you can do: http://android-developers.blogspot.com/2009/04/backward-compatibility... Note that reflection is useful for simple things, but for more extensive use of APIs you can follow the wrapper class approach which works very well. You can basically have large sections of you app using newer APIs, and as long as you don't try to run those classes you will be fine. (So in fact another approach you could take is to just look at the API version and use one class code vs. another based on it.) On Wed, Nov 25, 2009 at 8:16 PM, Ravi textlo...@gmail.com wrote: My understanding is that You can't. I cloned my app for 2.0 (ofcourse you will loose your feedback and popularity) and set minSDK to 5 Catch 22: If you set min sdk to 5 aka 2.0, 1.5 1.6 can not see the app. If you set to 1.5 or 1.6 then you can not see your cdma package. On Nov 25, 9:31 pm, Bryan piusve...@gmail.com wrote: Sorry for the simple question, but I'm having trouble finding an answer. My app targets 1.5, and runs fine on my phone (1.6), but to support droid, I need the package android.telephony.cdma from 2.0. Targeting 2.0 excludes the current devices running my app (including my own G1), but as it is now, I can't support the Droid. 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.comandroid-developers%2bunsubscr...@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.comandroid-developers%2bunsubscr...@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] changing the content of the .apk archive at runtime
Hello, it is allowed to change the content of a file in the .apk archive at runtime? because the signature of the application will change. Thanks in advance -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] Advice on keeping app running/available
Carl Barton wrote: I have spent a lot of time playing and researching (including subscribing to the Mark Murphy’s CommonsGuy stuff...excellent by the way) and I think I have enough info to be dangerous. I am just having issues coming up with best practices for doing what I need to do. Who-hoo! I make people dangerous! All this stuff is working at this point but I just need to make sure it keeps itself running at all times (or will always be available when needed at least). I'd link to my Diamonds Are Forever, Services Are Not post on AndroidGuys, but they're still undergoing yet another host migration... My initial thoughts were to have a service which starts at boot handle the sms messaging (in and out) and incorporate a content provider in it to provide access to the collection of messages (Sqlite) to other applications requiring it. I tried launching the service from an activity but if someone uses a task killer to kill the activity it seems to take the service down with it. I tried having a service that runs at boot but had trouble getting it to launch an activity when a new message arrives (probably my issue). So, after floundering back and forth with my indecisions of how best to architect it, I figured I would ask around to get some suggestions and then attack it from there. So, any ideas from anyone? First, services really aren't supposed to keep running. In fact, it is the fact that developers keep creating these always-running services that we're in our current war with the task killer applications. That being said, there are five main ways a service can stop running when you're expecting it to stay running: 1. You had a garden-variety crash due to a coding bug. With sufficient exception handlers, this should not be a problem. 2. You are being kicked out of memory to free up memory for something else. In principle, your service should be automatically scheduled to restart when memory space becomes available. Hence, there's nothing specifically you need to do here, other than be prepared to pick up where you left off at any time. 3. The user terminates your service via the new Services panel in the Settings application in Android 2.0. This will stop your running service, but relatively gracefully AFAIK. If your application is designed to not be in memory all of the time, but rather react to incoming events (SMS, alarms), this should not pose much of a problem. 4. The user attacks you with a task killer application. There is no defense against this, short of threatening legal action, until and unless there are changes made to Android itself. 5. The user powers down the device, removes the battery, sees if the phone can float, or otherwise causes the device to stop running altogether. There is no defense against any of this, either, unless you have some sort of USB-connected flotation device. With respect to spawning an activity on an incoming message, that should be possible, but please please please consider making it a Notification instead, or giving the user the option of a Notification or having an activity pop up in the middle of whatever they're doing. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _The Busy Coder's Guide to *Advanced* Android Development_ Version 1.2 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
Re: [android-developers] changing the content of the .apk archive at runtime
Mr.No wrote: it is allowed to change the content of a file in the .apk archive at runtime? SDK applications cannot access the APK, let alone modify it, at runtime. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android 1.6 Programming Books: http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Pixel Format Conversion in SF
Thank you Dianne. But if I set my CameraSurfaceView is of type mHolder.setType(SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS) for the purpose of pushing the preview frame onto the surface for display, does this surface also serve as my UI window? Thanks alot for your help! On Nov 27, 1:52 pm, Dianne Hackborn hack...@android.com wrote: Yes, you set the format and such by the setters you mentioned. The relation with surfaceChanged() is that this gets called after any such parameters have changed to provide a surface with the new configuration. On Fri, Nov 27, 2009 at 8:20 AM, android-newbie k...@itsaver.com wrote: Thanks Dianne so much for your reply. So let's say in my example I am working with SurfaceView for my CameraSurfaceView. I have a few questions, hope you can help me. 1. When this SurfaceView gets created (I assume via final CameraSurfaceView cameraView = new CameraSurfaceView (getApplicationContext()), this will result in a call createSurface() in SurfaceFlinger with format, width and height. How does the application pass these information like format, width and height to SurfaceFlinger for the allocation? Is it by using .setFormat, .setFixedSize? 2. How do they methods .setFormat, .setFixedSize related to the surfaceHolder.surfaceChanged() callback? On Nov 26, 5:41 pm, Dianne Hackborn hack...@android.com wrote: It totally depends. It may be surface flinger, it may be an overlay that is YUV, etc. On Thu, Nov 26, 2009 at 2:39 PM, android-newbie k...@itsaver.com wrote: I am looking at the source code of a Camera Preview application and learning that the preview buffers coming from the sensor is in YUV422 format. However, this preview frame is showed on the display in RGB. Can someone please let me know where the pixel format conversion happens? Is it inside Surface Flinger? If yes, can you please point me to the code? Thank you very much for your help, an -- You received this message because you are subscribed to the Google Groups Android Developers group. 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.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.- 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.comandroid-developers%2bunsubscr...@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.- 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: Advice on keeping app running/available
Hey Carl, Is any intent thrown upon receiving an SMS? My idea was going to be a BroadcastReceiver outlined in the manifest file to be run whenever a specific intent / pendingIntend is broadcast? On Nov 27, 1:59 pm, Carl Barton cbartonnhli...@gmail.com wrote: I have spent a lot of time playing and researching (including subscribing to the Mark Murphy¹s CommonsGuy stuff...excellent by the way) and I think I have enough info to be dangerous. I am just having issues coming up with best practices for doing what I need to do. My app is collecting specially formatted incoming SMS messages (currently default port but will later be processing port-directed using Verizon proprietary header info). I also need a UI application that will view the current messages that have been received and allow the user to read/delete/reply. All this stuff is working at this point but I just need to make sure it keeps itself running at all times (or will always be available when needed at least). My initial thoughts were to have a service which starts at boot handle the sms messaging (in and out) and incorporate a content provider in it to provide access to the collection of messages (Sqlite) to other applications requiring it. I tried launching the service from an activity but if someone uses a task killer to kill the activity it seems to take the service down with it. I tried having a service that runs at boot but had trouble getting it to launch an activity when a new message arrives (probably my issue). So, after floundering back and forth with my indecisions of how best to architect it, I figured I would ask around to get some suggestions and then attack it from there. So, any ideas from anyone? Thanks, Carl -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: AccountManager Authenticator only runs once per emulator restart.
It appears it's because there is some caching going on where my authenticator service is getting launched, the bind fails to return an authenticator IBinder, and then binding is not tried again for future runs of the application. Even if I install a new authenticator, the OS never bothers to try it again unless I restart the OS. Should I file a bug on this, since re-installing the authenticator should cause the service's onBind to call again, instead of using the cached one? On Nov 24, 12:43 pm, Micah mi...@zoltu.net wrote: I have written a simple Authenticator service to work with the new AccountManager API introduced in 2.0. When I launch a test app that uses the authenticator the authenticator service is launched (as expected) and it's onBind method is called. However, if I run my test application a second time in the same emulator (without restarting the emulator) my service is not launched and onBind is not called. So far the only way I have found to get my service to launch and onBind to call again is to restart the emulator, which is a very time consuming process. I have looked at the Devices view in Eclipse and ensured that all of my processes have been killed, just in case one of them was just being rebound to or something. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: Cant react to home button...
So do activities receive anything when the button is pressed? I thought activities are paused when they become hidden... On Nov 27, 6:09 am, Mark Murphy mmur...@commonsware.com wrote: dapaintballer331 wrote: How can I get my app to react when the Home button is pushed in the emulator? You can't. Activities do not receive this key event. -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android Consulting/App Development:http://commonsware.com/consulting -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Cant react to home button...
dapaintballer331 wrote: So do activities receive anything when the button is pressed? I thought activities are paused when they become hidden... Activities will be called with onPause() and onStop() when the HOME key is pressed. They will be called with those two methods in many other scenarios, though (incoming phone call, user launches an application from a notification, you start up another activity from your own code, etc.). -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android 1.6 Programming Books: http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Cant react to home button...
Thanks, I guess my cupcake/1.5 emulator is broken. The home key doesn't call onPause nor onStop On Nov 27, 3:29 pm, Mark Murphy mmur...@commonsware.com wrote: dapaintballer331 wrote: So do activities receive anything when the button is pressed? I thought activities are paused when they become hidden... Activities will be called with onPause() and onStop() when the HOME key is pressed. They will be called with those two methods in many other scenarios, though (incoming phone call, user launches an application from a notification, you start up another activity from your own code, etc.). -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android 1.6 Programming Books:http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Cant react to home button...
Nevermind, they are being called, however when the onStop/onPause is called because of the home button, it won't let me launch an activity. It only lets me if the back key is pressed. On Nov 27, 3:29 pm, Mark Murphy mmur...@commonsware.com wrote: dapaintballer331 wrote: So do activities receive anything when the button is pressed? I thought activities are paused when they become hidden... Activities will be called with onPause() and onStop() when the HOME key is pressed. They will be called with those two methods in many other scenarios, though (incoming phone call, user launches an application from a notification, you start up another activity from your own code, etc.). -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android 1.6 Programming Books:http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Cant react to home button...
The logcat says its launching the activity, however it only is displayed if the back key triggered this. On Nov 27, 3:29 pm, Mark Murphy mmur...@commonsware.com wrote: dapaintballer331 wrote: So do activities receive anything when the button is pressed? I thought activities are paused when they become hidden... Activities will be called with onPause() and onStop() when the HOME key is pressed. They will be called with those two methods in many other scenarios, though (incoming phone call, user launches an application from a notification, you start up another activity from your own code, etc.). -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android 1.6 Programming Books:http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Anyone get Camera#takePicture() to work on DROID?
I'm getting a SIGSEGV when trying to take a picture using Camera#takePicture() on a Motorola DROID. Has anyone gotten takePicture() to work on a DROID? More details, including the code of mine that's causing the MediaServer crash, can be found here: http://code.google.com/p/android/issues/detail?id=5090 Thanks in advance! -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android App Developer Books: http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Anyone get Camera#takePicture() to work on DROID?
Has anyone gotten takePicture() to work on a DROID? Did you try any other picture taking apps from the Market for comparison? I cannot tell because I have no Droid to test with, but my app does a takePicture() when key 'p' is pressed, so it is among the apps that you could try. However, I also have one user report stating that my app crashes anyway on the Droid... Regards The vOICe for Android http://www.seeingwithsound.com/android.htm On Nov 27, 10:15 pm, Mark Murphy mmur...@commonsware.com wrote: I'm getting a SIGSEGV when trying to take a picture using Camera#takePicture() on a Motorola DROID. Has anyone gotten takePicture() to work on a DROID? More details, including the code of mine that's causing the MediaServer crash, can be found here: http://code.google.com/p/android/issues/detail?id=5090 Thanks in advance! -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android App Developer Books:http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Cant react to home button...
I figured out how to get it to work! For the record: I'm unsure of why onPause / onStop won't start an activity in the emulator, if the home button is pressed (SDK 1.5), however a solution is to have onPause create an alarm to do the work for you :) -Brandon On Nov 27, 3:42 pm, dapaintballer331 dapaintballer...@gmail.com wrote: The logcat says its launching the activity, however it only is displayed if the back key triggered this. On Nov 27, 3:29 pm, Mark Murphy mmur...@commonsware.com wrote: dapaintballer331 wrote: So do activities receive anything when the button is pressed? I thought activities are paused when they become hidden... Activities will be called with onPause() and onStop() when the HOME key is pressed. They will be called with those two methods in many other scenarios, though (incoming phone call, user launches an application from a notification, you start up another activity from your own code, etc.). -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android 1.6 Programming Books:http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Cant react to home button...
onPause/onStop can happen for any number of reasons, not just pressing the Home button... On Fri, Nov 27, 2009 at 2:44 PM, dapaintballer331 dapaintballer...@gmail.com wrote: I figured out how to get it to work! For the record: I'm unsure of why onPause / onStop won't start an activity in the emulator, if the home button is pressed (SDK 1.5), however a solution is to have onPause create an alarm to do the work for you :) -Brandon On Nov 27, 3:42 pm, dapaintballer331 dapaintballer...@gmail.com wrote: The logcat says its launching the activity, however it only is displayed if the back key triggered this. On Nov 27, 3:29 pm, Mark Murphy mmur...@commonsware.com wrote: dapaintballer331 wrote: So do activities receive anything when the button is pressed? I thought activities are paused when they become hidden... Activities will be called with onPause() and onStop() when the HOME key is pressed. They will be called with those two methods in many other scenarios, though (incoming phone call, user launches an application from a notification, you start up another activity from your own code, etc.). -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Android 1.6 Programming Books:http://commonsware.com/books -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Re: How to get the highest API level supported by the device?
be aware that android.os.Build.VERSION.SDK is deprecated and android.os.Build.VERSION.SDK_INT only available in level 4. On Nov 26, 8:16 pm, Agus agus.sant...@gmail.com wrote: thanks On Thu, Nov 26, 2009 at 10:55 AM, Mark Murphy mmur...@commonsware.comwrote: Agus wrote: How to get the highest API level supported by the device? android.os.Build.VERSION.SDK. -- Mark Murphy (a Commons Guy) http://commonsware.com|http://twitter.com/commonsguy _Beginning Android_ from Apress Now Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.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] KeyEvent and GLSurfaceView
Hi, as soon as there's a GLSurfaceView in use, no other views receive any KeyEvents. MotionEvents however, are still working as expected. Is there a way to prevent GLSurfaceView from swallowing all KeyEvents? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: How to get the highest API level supported by the device?
It's only deprecated because it's better to use SDK_INT if your minSdkVersion is = 4. On Fri, Nov 27, 2009 at 3:23 PM, patrick patrick.boul...@gmail.com wrote: be aware that android.os.Build.VERSION.SDK is deprecated and android.os.Build.VERSION.SDK_INT only available in level 4. On Nov 26, 8:16 pm, Agus agus.sant...@gmail.com wrote: thanks On Thu, Nov 26, 2009 at 10:55 AM, Mark Murphy mmur...@commonsware.com wrote: Agus wrote: How to get the highest API level supported by the device? android.os.Build.VERSION.SDK. -- Mark Murphy (a Commons Guy) http://commonsware.com|http://twitter.com/commonsguy _Beginning Android_ from Apress Now Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.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 -- You received this message because you are subscribed to the Google Groups Android Developers group. 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 -- 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] How to set location of buttons programmatically
Hi, How do I set the location of buttons/other views programmatically? Below is my program snippet in the onCreate() method of my activity. //Create two buttons Button button1 = new Button(this); Button button2 = new Button(this); //Create layout params. Here, don't know how to //set the location (relative location or X ,Y) LayoutParams params = new LayoutParams (ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT); button1.setLayoutParams(params); button1.setText(Click this first); button2.setLayoutParams(params); button2.setText(Click this next); //Create relativelayout RelativeLayout layout = new RelativeLayout(this); RelativeLayout.LayoutParams layoutparams = new RelativeLayout.LayoutParams( RelativeLayout.LayoutParams.WRAP_CONTENT, RelativeLayout.LayoutParams.WRAP_CONTENT,10,10); //Add buttons to layout layout.addView(button1, layoutparams); layout.addView(button2, layoutparams); //Set layout as content of activity setContentView(layout); -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: KeyEvent and GLSurfaceView
I don't think you have fully identified the problem you are experiencing. If you read the source for GLSurfaceView, you will see that it does nothing special to handle KeyEvents. So the problem you are having is probably unrelated to GLSurfaceView. On Nov 28, 7:30 am, Mike internet...@hotmail.com wrote: Hi, as soon as there's a GLSurfaceView in use, no other views receive any KeyEvents. MotionEvents however, are still working as expected. Is there a way to prevent GLSurfaceView from swallowing all KeyEvents? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Anyone get Camera#takePicture() to work on DROID?
blindfold wrote: Did you try any other picture taking apps from the Market for comparison? No, because I wasn't sure how I'd tell Camera#takePicture() from launching the camera Intent. I cannot tell because I have no Droid to test with, but my app does a takePicture() when key 'p' is pressed, so it is among the apps that you could try. Well, taking a picture didn't blow up. It must be there's some parameter I need to set for the DROID that causes the SIGSEGV if I don't set it. I'll have to poke around. Thanks! -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _Android Programming Tutorials_ Version 1.0 Available! -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] How to update G1 firmware version to 2.0?
Hello, android-beginners How to update my G1 firmware version to 2.0, current is 1.5. Thank you. BR, Fion -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 update G1 firmware version to 2.0?
Fion Z wrote: Hello, android-beginners Please do not cross post to multiple mailing lists. How to update my G1 firmware version to 2.0, current is 1.5. Android 2.0 has not been officially released for the T-Mobile G1. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Warescription: Three Android Books, Plus Updates, $35/Year -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: KeyEvent and GLSurfaceView
Are you sure that the view you are expecting to receive key events has focus? On Nov 27, 6:30 pm, Mike internet...@hotmail.com wrote: Hi, as soon as there's a GLSurfaceView in use, no other views receive any KeyEvents. MotionEvents however, are still working as expected. Is there a way to prevent GLSurfaceView from swallowing all KeyEvents? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 in China - What is going on?
Appreciate the workaround Hong, i will give it a try. Don't get me wrong, i am not blaming Google for the cause of the problem, its not their fault they are being blocked but they must be aware of the problem and should make a statement as to what is happening will it stay like this or are they going to comply with whatever has caused the government to start blocking in the first place. Thanks On Nov 28, 2:06 am, Hong lordh...@gmail.com wrote: I will not go into details as why Chinese gov't blocking this and that, there are many reasons, and you certainly cannot hold Google accountable for the problems you have. Anyway, edit /system/etc/hosts, add 74.125.93.113 android.clients.google.com to your Android phone, and you are good to go. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Delete Bookmark?
How can I programmatically delete a bookmark in Android? Can't figure it out. Please let me know, 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] Question about selling paid apps from other countries
Hello! Can I sell paid apps in Android Market with Google Checkout if I live in Ukraine and have bank account in U.K. ? Or I need to register a company in U.K. with physical adress? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 set location of buttons programmatically
Not sure if it's the best way, but you can use padding to position elements in an absolute way. I think AbsoluteLayout is deprecated now, but you used to be able to use that to do what you want. On Nov 27, 8:01 pm, babu rkabhi1...@gmail.com wrote: Hi, How do I set the location of buttons/other views programmatically? Below is my program snippet in the onCreate() method of my activity. //Create two buttons Button button1 = new Button(this); Button button2 = new Button(this); //Create layout params. Here, don't know how to //set the location (relative location or X ,Y) LayoutParams params = new LayoutParams (ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT); button1.setLayoutParams(params); button1.setText(Click this first); button2.setLayoutParams(params); button2.setText(Click this next); //Create relativelayout RelativeLayout layout = new RelativeLayout(this); RelativeLayout.LayoutParams layoutparams = new RelativeLayout.LayoutParams( RelativeLayout.LayoutParams.WRAP_CONTENT, RelativeLayout.LayoutParams.WRAP_CONTENT,10,10); //Add buttons to layout layout.addView(button1, layoutparams); layout.addView(button2, layoutparams); //Set layout as content of activity setContentView(layout); -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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: Detect/intercept screen turning off
Hi, just came across this thread http://www.mail-archive.com/android-developers@googlegroups.com/msg63994.html. Hope this might help you. Also, does the use of android.os.PowerManager.WakeLock class feasible for your apps? On Nov 27, 3:47 am, David Given d...@cowlark.com wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Is there any way where I can detect that the screen is about to turn off, so I can do some work *before* it happens? I need this to work around bug 3755: OpenGL apps sometimes crash when the screen gets turned off because they don't get surfaceDestroyed()/surfaceCreated() events. http://code.google.com/p/android/issues/detail?id=3755 Simply put, I need to shut down OpenGL before the phone has a chance to detach the GPU. The only events I seems to be getting when the screen turns off are onPause() and onWindowFocusChanged()... both of which turn up *after* the GPU detaches, by which time it's too late. Can anyone suggest any way of doing this? (In desperation, I have tried to intercept the power key, but the power/hangup key is treated specially and doesn't generate keyboard events...) - -- ┌─── dg@cowlark.com ─http://www.cowlark.com─ │ │ Sufficiently advanced incompetence is indistinguishable from │ malice. -- Vernon Schryver -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (GNU/Linux) Comment: Using GnuPG with Mozilla -http://enigmail.mozdev.org iEYEARECAAYFAksPvFIACgkQf9E0noFvlzioGACfW5r72xNXqykHvSu4SocKo0bw rlkAoLNa6NZiWgczIBHtLmgJmzFZLiaR =HOwY -END PGP SIGNATURE- -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 release Drawable object from memory ?
As a crude sort of way to get around this problem, you can assign your drawable references to null once you do not find a use for them so that the GC can free these allocations. On Nov 26, 10:23 am, daniel.benedykt daniel.bened...@gmail.com wrote: Hi Probably you are having a memory leak Read this article from google blog. http://android-developers.blogspot.com/2009/01/avoiding-memory-leaks Hope this helps, Daniel On Nov 26, 3:42 pm, Syl sylvain.guyoma...@altran.com wrote: In my application, user can click on a button and then he can select a picture from his gallery. This image is then displayed. However, when the user performs 3 or 4 times this operation, the following exception is thrown, due to memory allocation problem : 11-26 18:31:34.119: ERROR/dalvikvm-heap(707): 6291456-byte external allocation too large for this process. 11-26 18:31:34.119: ERROR/(707): VM won't let us allocate 6291456 bytes 11-26 18:31:34.119: DEBUG/skia(707): allocPixelRef failed 11-26 18:31:36.005: DEBUG/AndroidRuntime(707): Shutting down VM 11-26 18:31:36.005: WARN/dalvikvm(707): threadid=3: thread exiting with uncaught exception (group=0x40013e28) 11-26 18:31:36.005: ERROR/AndroidRuntime(707): Uncaught handler: thread main exiting due to uncaught exception 11-26 18:31:36.099: ERROR/AndroidRuntime(707): java.lang.OutOfMemoryError: bitmap size exceeds VM budget 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.graphics.BitmapFactory.nativeDecodeStream(Native Method) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.graphics.BitmapFactory.decodeStream(BitmapFactory.java:304) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.graphics.drawable.Drawable.createFromStream(Drawable.java:635) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at com.altran.test.selectpicture.MainActivity.onActivityResult (MainActivity.java:74) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.app.Activity.dispatchActivityResult(Activity.java:3415) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.app.ActivityThread.deliverResults(ActivityThread.java:2835) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.app.ActivityThread.handleSendResult(ActivityThread.java:2881) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.app.ActivityThread.access$2300(ActivityThread.java:112) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1608) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.os.Handler.dispatchMessage(Handler.java:88) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.os.Looper.loop(Looper.java:123) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at android.app.ActivityThread.main(ActivityThread.java:3742) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at java.lang.reflect.Method.invokeNative(Native Method) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at java.lang.reflect.Method.invoke(Method.java:515) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:739) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:497) 11-26 18:31:36.099: ERROR/AndroidRuntime(707): at dalvik.system.NativeStart.main(Native Method) Here a sample of my code where problem is focused : InputStream is = getContentResolver().openInputStream( currImageURI ); Drawable drawable = Drawable.createFromStream( is, src ); is.close(); m_imageView.setBackgroundDrawable( drawable ); Is it possible to force object (here the Drawable object) to be released from memory ? Thanks. -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: disabling button onclicklistener for certain time
How about setting the onClickListener to null for that period of time and resetting it to a valid listener again? On Nov 26, 4:15 am, Mark Murphy mmur...@commonsware.com wrote: Jags wrote: I have a typical problem where if i keep repetedly press a button, a certain value increases, actually i am supposed to increase once till it disappears [it disappears in 700 ms] public class CatchMeOnClickListener implements OnClickListener { public void onClick(View v) { if(!alreadyCaught) value++; alreadyCaught = true; } } i have tried to put a flag which is set to false when the button is disappeared. still it seems not to work. Can i make the button nonclickable inside this ? how ? Try calling setEnabled(false) on your Button. -- Mark Murphy (a Commons Guy)http://commonsware.com|http://twitter.com/commonsguy Warescription: Three Android Books, Plus Updates, $35/Year -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 enable different css in WebView
Hi, we have a web page which include two different css: portrait.css and landscape.css. We want load this page only once and enable the right css according to phone's orientation. We have a plan to develop a chrome plugin by c++ to make it which got us to have to change firmware. I just wonder whether there is more elegant way to do it by java. Anyone can shed light on it? That will be appreciated! Best regards. James -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: How to set location of buttons programmatically
One plausible way is to use the RelativeLayout as your base layout and add all other children views to this layout using the RelativeLayout.LayoutParams class for setting the layout parameters. The RelativeLayout.Layoutparams.left and RelativeLayout.Layoutparams.top attributes can be your (x,y) co- ordinates on the base view. On Nov 27, 6:39 pm, Mark Wyszomierski mar...@gmail.com wrote: Not sure if it's the best way, but you can use padding to position elements in an absolute way. I think AbsoluteLayout is deprecated now, but you used to be able to use that to do what you want. On Nov 27, 8:01 pm, babu rkabhi1...@gmail.com wrote: Hi, How do I set the location of buttons/other views programmatically? Below is my program snippet in the onCreate() method of my activity. //Create two buttons Button button1 = new Button(this); Button button2 = new Button(this); //Create layout params. Here, don't know how to //set the location (relative location or X ,Y) LayoutParams params = new LayoutParams (ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT); button1.setLayoutParams(params); button1.setText(Click this first); button2.setLayoutParams(params); button2.setText(Click this next); //Create relativelayout RelativeLayout layout = new RelativeLayout(this); RelativeLayout.LayoutParams layoutparams = new RelativeLayout.LayoutParams( RelativeLayout.LayoutParams.WRAP_CONTENT, RelativeLayout.LayoutParams.WRAP_CONTENT,10,10); //Add buttons to layout layout.addView(button1, layoutparams); layout.addView(button2, layoutparams); //Set layout as content of activity setContentView(layout); -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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 in China - What is going on?
Google has already complied with the Chinese government by using Google.cn and g.cn instead of Google.com in China. Everything (DNS, servers, routers) are under local government surveillance and control. Not much they can do. On Fri, Nov 27, 2009 at 9:02 PM, shimsim shim@gmail.com wrote: Appreciate the workaround Hong, i will give it a try. Don't get me wrong, i am not blaming Google for the cause of the problem, its not their fault they are being blocked but they must be aware of the problem and should make a statement as to what is happening will it stay like this or are they going to comply with whatever has caused the government to start blocking in the first place. Thanks -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en
[android-developers] Re: How to set location of buttons programmatically
Thank you. That worked. On Nov 27, 8:52 pm, Anirudh aithalanir...@gmail.com wrote: One plausible way is to use the RelativeLayout as your base layout and add all other children views to this layout using the RelativeLayout.LayoutParams class for setting the layout parameters. The RelativeLayout.Layoutparams.left and RelativeLayout.Layoutparams.top attributes can be your (x,y) co- ordinates on the base view. On Nov 27, 6:39 pm, Mark Wyszomierski mar...@gmail.com wrote: Not sure if it's the best way, but you can use padding to position elements in an absolute way. I think AbsoluteLayout is deprecated now, but you used to be able to use that to do what you want. On Nov 27, 8:01 pm, babu rkabhi1...@gmail.com wrote: Hi, How do I set the location of buttons/other views programmatically? Below is my program snippet in the onCreate() method of my activity. //Create two buttons Button button1 = new Button(this); Button button2 = new Button(this); //Create layout params. Here, don't know how to //set the location (relative location or X ,Y) LayoutParams params = new LayoutParams (ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT); button1.setLayoutParams(params); button1.setText(Click this first); button2.setLayoutParams(params); button2.setText(Click this next); //Create relativelayout RelativeLayout layout = new RelativeLayout(this); RelativeLayout.LayoutParams layoutparams = new RelativeLayout.LayoutParams( RelativeLayout.LayoutParams.WRAP_CONTENT, RelativeLayout.LayoutParams.WRAP_CONTENT,10,10); //Add buttons to layout layout.addView(button1, layoutparams); layout.addView(button2, layoutparams); //Set layout as content of activity setContentView(layout); -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] Add custom View to XML layout
Hi, Currently, I am creating a custom View class (DrawView) that inherits the View class and adding to my activity programatically by using RelativeLayout and LaoutParams etc. But is there an easier way to do this by adding my DrawView to the layout XML file? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, 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] ImageButton handling of transparent src pngs
ImageButton doesn't honor the transparency of my android:src png. My src image is a rounded rectangle, with the remaining portion of the bounding rectangle set to be transparent. When the button is displayed, what should be transparent is a dark shadowy color. The images I'm using are OK, and display the proper transparency when shown in a browser. android:background=@android:color/transparent doesn't have any effect. Or do I need to subclass ImageView directly to get the desired handling of the src image transparency? -- You received this message because you are subscribed to the Google Groups Android Developers group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en