Need help?

I'm available for remote short term contracting or consultancy work. Please check out my LinkedIn profile for more details on my experience.

Please feel free to use the form below to contact me.


If you're trying to programmatically figure out how to move or drag a view with your finger, then read on.

I was looking for a solution to this problem just the other day, and couldn't really find that much. What I needed was a view that you could move with your finger, and upon lifting the finger, it would snap into place at a set location. Seeing as I couldn't find anything like this, I decided to write my own custom view, which did just that.

The view I wrote extends UIImageView, but you can change that to UIView if you want. So how does this work you ask? Well, it basically takes a topLock, bottomLock, and whether it's moving on the x axis or not (if not, then it uses the y axis). The top lock is the x(or y) point where the view will lock into place, and same with the bottom lock. And how that works is that it'll check which one is closest, and lock it into that spot. So here's an example, if you drag the view up on the y axis all the way to the top and let go, it'll move it to the closest lock point (which will most likely be the top lock. This will also give that nice swing-back (gravity) effect that you see on the iPhone tableviews.

jon | April 23, 2010 | Comments (2)

I'm going to be referring to iOS related Objective-C, as the blocks were just released in version 4, so it's an interesting topic.

Before the blocks functionality, the typical way to do a callback would be to pass the delegate of the object which would be called to the worker object. Once the worker object finished the task, it would then reference a specific method (defined by the protocol), which executes the callback code. This approach works fine, but gets very bloated when you need to do certain kinds of tasks - not going to be getting to the protocols vs blocks in this article though. They do both serve their own purposes, and I'm just going to be getting into the relations they have to the Java anonymous classes.

jon | April 23, 2010 | Comments (2)

If you're struggling to decide which phone to get, then you're in a similar predicament that I was in not too long ago - the difference being, that I actually got to play around with each of these phones for a bit before actually deciding to stick with one.

Since the Samsung Galaxy S came out a few days before the iPhone 4, I decided to get it just to satisfy my gadget hunger. After playing around with the Galaxy S, I was quite impressed - the interface was real smooth, and transitioning through the different menues (desktops) was speedy - this is in comparison to my not so old old phone, the Nexus One.

jon | April 23, 2010 | Comments (2)

This was the first and only app that I developed for the iPhone, in the hopes that I could get a better understanding of iPhone application development.

Why would I choose to do an app that retrieves the Google PageRank & Alexa Ranking? Well... why not? It's not like I was looking to make money out of it - I just wanted to develop something that allowed me to improve my iPhone SDK/Objective C/Cocoa skill base.

jon | April 23, 2010 | Comments (257)