Office Hours — Today, May 24

Thursday, May 19

May 24
7:25 PM
Mark M.
has entered the room
Mark M.
turned on guest access
fitz
has entered the room
fitz
hello
Mark M.
howdy, fitz!
fitz
so I have gdata now giving me good info for calendar and docs - what a twisted mess
Mark M.
how can I help you today?
7:30 PM
fitz
I think Google's mission is to confuse us - PERIOD
Mark M.
yeah, well, there are reasons why I don't use their APIs for anything much
Shawn L.
has entered the room
Shawn L.
Hello
Mark M.
howdy, Shawn!
fitz
can I take a project that runs as a JAVA APPLICATION - shows in Console in eclipse and convert to run as android app or is a rewrite
Mark M.
fitz: well, at least the UI is a rewrite
you may be able to salvage the rest -- impossible to say in the abstract
fitz
ok thanks - that is all for now
Mark M.
Shawn: how can I help you today?
Shawn L.
Hi Mark -- first, nice meeting you at Google I/O and chatting for about 5 minutes in the hall
Mark M.
likewise!
Shawn L.
second: I have a Bitmap that I'm creating in my app. I want to save it as a PNG
I'm using the compress() function, but it always returns false
and I can't tell why, don't know how to figure it out, etc.
Any idea?
Mark M.
what are you using for the OutputStream?
Shawn L.
I tried a ByteArrayOutputStream and the FileOutputStream returned from the system
7:35 PM
Shawn L.
just the output of openFileOutput()
Mark M.
hmmm
Shawn L.
I tried it on two devices too -- same result on both
and the source code just goes into the nativeCompress() method, so that doesn't help either
Mark M.
hehehe, I was just looking at the source and hit the same brick wall
yeah, beats me
Shawn L.
*sigh*
Mark M.
I would have thought the ByteArrayOutputStream would be immune to problems
anything unusual about the Bitmap?
Shawn L.
Yeah, I started with that
it's super simple -- it's just a signature
View paste
		Bitmap bm = Bitmap.createBitmap(mWidth, mHeight, Bitmap.Config.ALPHA_8);
		Canvas c = new Canvas(bm);
		c.drawPath(mSignaturePath, mSignaturePaint);
		return bm;
Mark M.
meaning you're capturing a signature via touch events and drawing it on a Bitmap-backed Canvas?
ok
ALPHA_8 seems a bit curious
isn't that purely an alpha channel?
Shawn L.
oh yeah? I think I just copied that from somewhere
I can change it to anything, didn't think to try that
Mark M.
try switching that to one of the others (RGB_565 or ARGB_8888)
Shawn L.
sure, let me try that quick, if you don't mind
Mark M.
I'm here for another ~50 minutes... :-)
Shawn L.
won't take quite that long
7:40 PM
Mark M.
meanwhile, I'm up for other questions
Shawn L.
you know, I noticed that and thought to change it, but didn't get around to doing that, I believe
well damn, that's it
Mark M.
booya
Shawn L.
yeah, thanks! Should have known it's the one bit of code I didn't understand
thanks!
Mark M.
happy to help
Shawn L.
hah, more questions -- I should check my stack overflow list :)
Mark M.
any chance you're releasing this code as open source?
Shawn L.
but they're all old questions
Mark M.
I've been keeping my eye out for an OSS signature capture widget
Shawn L.
no, not open source, it's for a company
Mark M.
phooey
Shawn L.
it was really not difficult
Mark M.
yeah, but I'm lazy
:-)
Shawn L.
yeah, lazy answering questions, what a slacker
it's just a Path object and call lineTo() with the inform from the MotionEvent
and I already pasted the final code
Mark M.
yeah, well, I've done next to nothing with the 2D APIs, and not much more with MotionEvent
7:45 PM
Mark M.
I don't have an immediate need for the capability
Shawn L.
me neither. If I figured it out in a few hours, anyone can
Mark M.
looking ahead 6-9 months
ok
Shawn L.
to be honest, that's by far what I need to improve
Mark M.
getting into more of that is on my docket for 2012
Shawn L.
Oh, I've got another one!
Mark M.
scary how far out I need to project things...
Shawn L.
I haven't dug into what's going on here, but since you're around
I've got an AsyncTask with an AlertDialog that gets shown as part of preExecute, or whatever it's called
Mark M.
onPreExecute()
Shawn L.
right. Well, actually I'm using RoboGuice and their RoboAsyncTask, but I suspect the problem is the same
in any case, I'm showing it on the UI thread
then a problem occurs and I need to show another alert dialog
however, that thing never shows -- even if I dismiss the initial dialog
if I dismiss the initial dialog first
this might be a simple bug on my part, but can you think of anything offhand?
Mark M.
well, I haven't run into that specific symptom before
7:50 PM
Mark M.
what is the purpose of the first dialog?
Shawn L.
ok, that's what I wanted to know more than anything else, I suppose
it's just a progress dialog
it's a remote call
Mark M.
maybe consider switching to the progress indicator in the title bar
though that reminds me, I need to see if that still works in Honeycomb...
Shawn L.
I haven't done much with that before -- I know that I don't have a title bar, but do have a proto-action bar
(i.e. not an ActionBar)
Mark M.
well, if you don't have a title bar, you can't use its progress indicator, so that's out
Shawn L.
It seems like most apps check the title bar
Mark M.
maybe stick a ProgressBar in your action proto-bar
Shawn L.
yeah, that seems to be a common approach
Mark M.
if I had to guess, that's the Honeycomb direction too
long-running dialogs make for crummy UX, because the user is locked down
Shawn L.
the problem is that in this app you're moving from one screen to the next, and so the progress on the top makes it look like you can do something at this point
well, don't get me started on the crummy UX part
Mark M.
why not move to the next, then display the progress indicator and kick off the work?
Shawn L.
nah, that won't work in this case either, because the remote call might fail, and need to stay on the same screen
I'll have to think about it some more
7:55 PM
Mark M.
oh
Shawn L.
But you've given me some ideas, and I know that it's not a bug that others have seen
Mark M.
well, others might have seen it -- I just haven't, and I don't recall running into a support question on it
that being said, there have been an awful lot of support questions, and it's not like I have them all memorized
Shawn L.
of course
k, that's it for me! Thanks for the help, see you around
Mark M.
see ya!
Shawn L.
has left the room
8:00 PM
Mark M.
fitz: if you come up with another question, feel free to chime in
fitz
sorry been on phone call - I should just turn it off while in here :)
so did you meet any others at Google IO fighting with how to make $ with android apps - any new ideas?
Mark M.
it didn't come up in any of the conversations I was in
I sat in the Android Market presentation, but it wasn't really focused on business models
I wasn't in any of the Google Ventures stuff to see if anything mobile was discussed there
8:05 PM
fitz
went last night to San Jose Meetup at DLA PIPER - they are VC's with 4,200 layers on staff (go figure). Anyways they had 5 companies talking about the fight they have had to get to market and they still are not making $ - yet VC's are funding it - is something broken here?
these are Android and IPhone companies
Mark M.
if by "broken here", you mean VCs funding firms with no immediate revenue, that's been done a lot
fitz
it is just fresh on the mind so I thought I would ask if you had any new ideas on it
Mark M.
not immediately, but I may be revisiting the subject later this year
fitz
ya the VC's are a strange group - but I guess you need em
Mark M.
one of my proposals for the Android Open conference was "50 Business Models in 20 Minutes"
fitz
I think I saw a slide presentation on that online - good stuff
8:10 PM
Mark M.
yeah, and that slide deck is old
fitz
ok have to jet thanks for info today
Mark M.
have a pleasant day!
fitz
has left the room
8:30 PM
Mark M.
turned off guest access

Thursday, May 19

 

Office Hours

People in this transcript

  • fitz
  • Mark Murphy
  • Shawn Lauzon