Staying in true geek form, since GSoC ended, I decided to take a “break” and tinker around with some Android development. What you see above, is a screenshot from the fruits of my labour over the past week or so. I call it SyncMyPix.
Originally, my inspiration came from Blackberry. My girlfriend’s Pearl has a feature that allows her to automatically sync up her contacts’ pictures with Facebook. So, I thought, “Hey, I want my phone to do that.” And, with SyncMyPix, now it can. I figured it’d be a cool little app to try out as my first Android application.
Here’s a run down of the features currently implemented:
- Sync your phone’s contacts with your Facebook friends’ profile pictures
- If do not want to overwrite manually set contact pictures on your phone, the Skip if non-SyncMyPix picture exists option will let you do that
- If a Facebook friend matches up with multiple contacts, you can skip them by checking the Skip if multiple phone contacts found option
- Sync runs in the background leaving you free to do other tasks
- View the results of the last sync operation
I decided that with so many social networks around these days, the app shouldn’t be made specifically for Facebook (even though all it can handle is Facebook, right now). In the future, I’d like to add more sync sources. Maybe using the OpenSocial API.
I used Android’s built in menu system for the actions you see above. It’s a much cleaner interface than a bunch of buttons.
The login action loads up the Facebook login webpage within a WebKit embedded widget. I’ve actually written a tiny, weeny Facebook Java library which I make use of here to interact with the Facebook REST API. After logging in, you’ll also have to authorize the application, so it can access the API. As you can see, I’m letting Facebook do all the authentication work by directing you to their site.
After logging in, you get brought back to the original screen.
Now that the user has been authenticated, a sync operation can begin. After clicking the “Sync” menu option, a notification is sent…
…and the sync gets underway. During the sync operation, SyncMyPix will attempt to match up your social networking friends’ names with your phone’s contact names. Name matching is currently very strict. As an example, a social networking friend named “Billy Bob” will match the following contacts on your phone:
- Billy Bob
- Bob, Billy
- Bob,Billy
The sync operation takes place in a separate thread, so the UI is free for the user to do whatever they want. If the HOME key is pressed, the user can come back to SyncMyPix by re-launching the application or clicking on the SyncMyPix notification. If the sync is still in progress, the progress bar will be displayed.
Once the sync is complete, you’ll get a friendly message telling you so.
Then, you can click the “Results” menu option and see exactly what happened (names have been blurred to respect my friends’ privacy).
As you can see, the application is a no-frills, just get it done type of app. The code and UI could use some polish, but it’s in a decent, very usable state as is.
With a brand, spankin’ new 48x48 icon, hot off the Inkscape press, I’ve just launch SyncMyPix 0.1 on the Android market. It’s available for free, and I hope some will get some use out of it. So next time you’re in the market for a new app, give mine a try. You can search for it in the Android market, or, if you’re browsing this page from your Android phone, here is a direct link.
Look for the following new features in the future:
- An improved “Results” interface where the picture downloaded from a social network is displayed when selecting a friend from the list
- Manual conflict resolution in the “Results” interface where a long press on a friend would allow the picture to be manually added to a contact of the user’s choosing
- A new “Progress” interface where the progress bar is integrated in the screen and an image widget displays the last picture downloaded
- Automatic scheduling of the picture download service with configurable frequency
- Improved extensibility with more social networking sites as picture sources
- Improved name matching