*

Our Beautiful Faces is Jeremy Hunt Schoenherr and he does iPhone development, for now.

Mar 26

DevTip: Abuse threads

Sometimes your interfaces can become clunky. You hit a button, or slide a slider and things get all stuttery. No good. People hate that and so should you. Usually this is because when your control (button, slider, tab, etc) calls back to your handler, there is too much work going on.

Just start a new thread. This sounds simple, but sometimes people over look it. I ran into this when I was adding the volume control on the new audio stream player for MLB.com At Bat. I thought, yeah, no problem, I can make a call to the audio session and store the value in my user defaults in real time. Easy! But no, it made the volume control sticky, so I had to spawn threads. See below.

In Interface Builder, connect your control to your handler for the given event the IBAction below, and then in that method, start a thread and don’t wait around for the result.

- (void) threadedTargetMethod:(id)object {
   //Do you time consuming stuff
}


- (IBAction) targetMethod:(id)sender {
   [self performSelectorOnMainThread:@selector(threadedTargetMethod:) 
                          withObject:nil 
                       waitUntilDone:NO];
}


Comments (View)
Feb 20

DevTip: Always check your distribution builds

Old post, but very useful, Craig Hockenberry walks you through testing your distribution builds.  Do this to make sure you know exactly what you are submitting to iTunes Connect.  Sometimes build settings vary between targets/build configs, and the only way to know what you have is to run what you submit.


Comments (View)
Jan 29

Death Cab for Cutie app released!

So, at long last, the DCfC app is finally live in the App Store. It was a fun project. Props to Zeitgeist Management and the Band for making it such a fun experience. Oh, and big ups to Dan VonB for pointing them in my direction. :)

The app gives you all the DCfC info you could want. 10 full songs packaged in the app (not streaming) so you can listen whenever you want. Tours (with some sweet maps), Discography, Photos, Videos, and some other fun stuff.

Click here to download.


Comments (View)
Page 1 of 1