Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-05-01 Thread Zy Z
30.44406N 86.59909W 在 2012-4-30 上午3:14,Jim Graham spooky1...@gmail.com写道: On Sun, Apr 29, 2012 at 12:04:01PM -0700, Jonathan S wrote: java.lang.NoSuchFieldError: android.graphics.PorterDuff$Mode.ADD it is telling Mode.ADD is not exists in 2.2 Hm, according to the developers guide,

[android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Alger Lin
I release a tool to help developer to dump API from Android device. This tool may help you to check if class, method, or field existed at target device. You can get it from Google Play by URL below. http://market.android.com/details?id=com.twrd.yulin.classminer -- You received this message

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Sun, Apr 29, 2012 at 11:39:04PM -0700, Alger Lin wrote: I release a tool to help developer to dump API from Android device. This tool may help you to check if class, method, or field existed at target device. You can get it from Google Play by URL below.

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Mark Murphy
Create a separate little project that accesses PorterDuff.Mode.ADD. Run it on the phone. If it crashes the same way, and particularly given your comment regarding external storage, your phone may be messed up, somehow. If it does not crash the same way, then you have a stake in the ground, around

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Mon, Apr 30, 2012 at 07:11:36AM -0400, Mark Murphy wrote: Create a separate little project that accesses PorterDuff.Mode.ADD. Run it on the phone. If it crashes the same way, and particularly given your comment regarding external storage, your phone may be messed up, somehow. If it does not

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jason Teagle
Call me suspicious, but in their own example at http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/graphics/Xfermodes.html they don't use either ADD or OVERLAY, but do list the remaining 16 from the PorterDuff enum: private static final Xfermode[] sModes = {

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Mark Murphy
To be honest, these past two emails have been fairly incomprehensible to me, and I don't mean the log output. At this point, I have no idea what is and is not working for you, other than an indication that perhaps your ADD problem persists. On Mon, Apr 30, 2012 at 11:33 AM, Jim Graham

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Mon, Apr 30, 2012 at 04:45:58PM +0100, Jason Teagle wrote: Call me suspicious, but in their own example at http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/graphics/Xfermodes.html they don't use either ADD or OVERLAY, but do list the remaining 16 from

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Mon, Apr 30, 2012 at 11:55:41AM -0400, Mark Murphy wrote: To be honest, these past two emails have been fairly incomprehensible to me, and I don't mean the log output. At this point, I have no idea what is and is not working for you, other than an indication that perhaps your ADD problem

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Mark Murphy
On Mon, Apr 30, 2012 at 12:10 PM, Jim Graham spooky1...@gmail.com wrote: ADD works in the example from Pro Android Media on my phone (Froyo). ADD does NOT work, using the exact same 4 or 5 lines of code (different variables) in my app on my phone.  It force closes claiming that the ADD mode

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
One more detail: in my app, if I replace ADD with MULTIPLY, it works on my phone, too (but doesn't do what I need like ADD does). That would seem to indicate that it's not the surrounding code, but a problem with ADD. Later, --jim -- THE SCORE: ME: 2 CANCER: 0 73 DE N5IAL (/4)

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Mon, Apr 30, 2012 at 12:35:45PM -0400, Mark Murphy wrote: On Mon, Apr 30, 2012 at 12:10 PM, Jim Graham spooky1...@gmail.com wrote: ADD works in the example from Pro Android Media on my phone (Froyo). ADD does NOT work, using the exact same 4 or 5 lines of code (different variables) in

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jason Teagle
And...why doesn't Froyo support what is clearly listed as supported since API level 1 in the dev guide? They should agree, shouldn't they? Be aware that they might mean that the *original* enum (16 values) was available from level 1, but that the ADD and OVERLAY additions may not have

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Mark Murphy
On Mon, Apr 30, 2012 at 1:11 PM, Jason Teagle teagle.ja...@gmail.com wrote: Be aware that they might mean that the *original* enum (16 values) was available from level 1, but that the ADD and OVERLAY additions may not have existed until, say, level 8. It could simply be worded badly, giving the

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Mark Murphy
On Mon, Apr 30, 2012 at 1:15 PM, Mark Murphy mmur...@commonsware.com wrote: Actually, based on a quick experiment, it appears that ADD was, er, added in API Level 11. ADD, SCREEN, and OVERLAY were added in API Level 11. I filed an issue regarding the documentation gap:

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Mon, Apr 30, 2012 at 01:18:43PM -0400, Mark Murphy wrote: On Mon, Apr 30, 2012 at 1:15 PM, Mark Murphy mmur...@commonsware.com wrote: Actually, based on a quick experiment, it appears that ADD was, er, added in API Level 11. ADD, SCREEN, and OVERLAY were added in API Level 11. I filed

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Raghav Sood
Depending on how many files the code is spread across, you could pick up the newer code from the Android source and incorporate it into your app, and call that. It might get too messy if there is too much code though. Thanks On Mon, Apr 30, 2012 at 11:00 PM, Jim Graham spooky1...@gmail.com

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Mark Murphy
On Mon, Apr 30, 2012 at 1:30 PM, Jim Graham spooky1...@gmail.com wrote: But again, how would I duplicate that mode without PorterDuff? Beats me -- I'd follow Jason's advice. To me, PorterDuff is a line of dark beer from The Simpsons... :-) -- Mark Murphy (a Commons Guy) http://commonsware.com

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Mon, Apr 30, 2012 at 06:11:02PM +0100, Jason Teagle wrote: How does what you expect ADD to do differ from a combination such as, say, SRC_OVER (in the images shown at http://softwyer.wordpress.com/2012/01/21/1009/, 'SrcOver' looks like we're seeing the yellow circle through the grey square

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jason Teagle
I tried lots of modes, including SRC_OVER. Imagine the following two filters: the first is a solid color blue filter; the second is a fog filter (graduated, upwards from the bottom)[1]. Every other method I tried did some combination of showing only one filter or the other where they

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Mon, Apr 30, 2012 at 01:35:34PM -0400, Mark Murphy wrote: On Mon, Apr 30, 2012 at 1:30 PM, Jim Graham spooky1...@gmail.com wrote: But again, how would I duplicate that mode without PorterDuff? Beats me -- I'd follow Jason's advice. To me, PorterDuff is a line of dark beer from The

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Mon, Apr 30, 2012 at 06:43:58PM +0100, Jason Teagle wrote: Could you perhaps show us a similar set of images for all modes available, but using your sample filters, so we can see how it differs? It'll take a little while, but yeah, I'll post a few. Later, --jim -- THE SCORE: ME: 2

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-30 Thread Jim Graham
On Mon, Apr 30, 2012 at 06:11:02PM +0100, Jason Teagle wrote: How does what you expect ADD to do differ from a combination such as, say, SRC_OVER (in the images shown at http://softwyer.wordpress.com/2012/01/21/1009/, 'SrcOver' looks like we're seeing the yellow circle through the grey square

[android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-29 Thread Jonathan S
java.lang.NoSuchFieldError: android.graphics.PorterDuff$Mode.ADD it is telling Mode.ADD is not exists in 2.2 On Sunday, April 29, 2012 12:45:34 PM UTC-4, Spooky wrote: The following code (which works fine earlier in the app on both devices) causes a force close (logcat below) on my Froyo

Re: [android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-29 Thread Jim Graham
On Sun, Apr 29, 2012 at 12:04:01PM -0700, Jonathan S wrote: java.lang.NoSuchFieldError: android.graphics.PorterDuff$Mode.ADD it is telling Mode.ADD is not exists in 2.2 Hm, according to the developers guide, it's existed since API Level 1 2.2 is API Level 8 Yeah, it exists in

[android-developers] Re: Strange force close on Froyo phone, works fine on ICS tablet

2012-04-29 Thread Jim Graham
I was wrong about one point here, so this post is to correct that error. Sorry. But now, the plot thickens (maybe) On Sun, Apr 29, 2012 at 11:45:34AM -0500, Jim Graham wrote: The following code (which works fine earlier in the app on both devices) I was WRONG about this point! It does NOT