Droidcon UK 2015

Front door of Droidcon UK with Android robot

I was super fortunate to speak at Droidcon UK this year in London, and I had an amazing time!

My Talk

Even though I’ve given the “same” talk on accessibility before, my talk actually changes every time I give it.  This is because (1) Android is always changing, and (2) I am always learning new ways to improve accessibility.  Before this talk I had some coding work to do, to upgrade my sample app to support Marshmallow.  I also decided to pull in the new design compatibility library so I could use the official floating action button (FAB) and remove the 3rd party library I had previously been using.  It is really important to me that my accessibility repo doesn’t get stale, and can always be a resource for the latest and greatest in Android accessibility.

I decided to go the extra mile and add in some information about Snack Bar from the design compat lib to my talk. I figured that it would be a pretty simple addition, but it didn’t work out that way! Apparently, Snack Bar has a few big accessibility issues, as documented in my recent post Accessibility of Material Design.  After battling Snack Bar for quite some time, I decided to add to my talk some information about why Snack Bar wasn’t accessible. Unfortunately, this put my talk way over the time limit.  Ugh.  After all that, I decided to just not add Snack Bar to my talk. I was glad I’d done my homework, though, because I ended up having several great conversations about it with people at the conference.

Continue reading

Posted in Accessibility, Android, Conferences, Speaking | Leave a comment

Accessibility of Material Design

With the launch of Material Design at I/O 2014, Google made a bold statement that beautiful Android design is here to stay.  As a user I was excited to see some beautiful designs come to my platform.  As a developer, I was excited to see designers get excited about Android designs independently (vs designing for iOS and ‘porting’ to Android). However, as I began to dig into coding Material, I soon found that not all of the design paradigms are accessible.  Here are the top offenders, from least bad to most bad.

Animations

Animations are a huge part of Material Design.  The design docs break animation into 4 main categories:

  1. Authentic motion
  2. Responsive interaction
  3. Meaningful transitions
  4. Delightful details

Continue reading

Posted in Accessibility, Android | 1 Comment

Start Using the Percent Support Library Right Meow!

Cat and percent symbols

Recently I learned about a SUPER awesome little library that you should consider adding into your projects: The Percent Support Library.

This library allows you to specify a percentage value for layout width and height when you are using RelativeLayout or FrameLayout. Yipee!!!! Gone are the days of switching everything over to a LinearLayout when you realize halfway through coding that you really need weights in your layout.

First step is to pull the library into your project. Just add this line in your app level build.gradle:

compile 'com.android.support:percent:23.0.0'

Now you can use percents in your XML layout files. The library defines a new layout type called PercentRelativeLayout, which inherits from RelativeLayout. Here is a basic example on how to use it:

<android.support.percent.PercentRelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    tools:context=".MainActivity">

    <ImageView
        android:id="@+id/centered_image_2"
        android:layout_gravity="center"
        android:contentDescription="Android Robot"
        android:src="@mipmap/ic_launcher"
        app:layout_heightPercent="30%"
        app:layout_widthPercent="50%" />
    
</android.support.percent.PercentRelativeLayout>

Note that you must include percent symbols as units when defining the parameters (in place of dp).

Continue reading

Posted in Android | 1 Comment

Big Android BBQ 2015

IMG_20151022_090231889_HDR

I just got done with my first ever Big Android BBQ in Hurst, Texas, and I had a great time!  I was extra excited for this conference because I was debuting a brand new talk “Android Internal Library Dependency Management.”  Ever since I was introduced to the magical land that is Ruby’s Gemfile, I have been on a quest to find the best way to manage dependencies for Android. When I first started writing the talk, I was afraid I’d have so little to say that it would only last 10 minutes. By the time I finished writing it, I was struggling to get in under 1 hr and had to remove and rearrange some content! I set off for Texas feeling excited and nervous.

The conference kickoff pool party happened to correspond with the date that Doc Brown and Marty McFly travel into the future in the movie Back to the Future: II.  I was so excited to walk around the corner and find the De Lorean time machine in the parking lot!

De Lorean Time MachineKelly in the De Lorean Time Machine

Continue reading

Posted in Android, Conferences, Speaking | 3 Comments

Automated Calabash Testing on Marshmallow

Screen Shot 2015-10-19 at 5.08.50 PM

Recently I upgraded an Android app to targetMarshmallow (API 23, OS v 6.0).  I made all the necessary changes to our source code, and the app seemed to be working as expected.  However, I was pretty bummed to see that almost half of our automated Calabash tests failed for Marshmallow!  Upon closer inspection I saw that all failures were due to one thing: the Permissions Dialog popup.

This app is using android.permission.ACCESS_FINE_LOCATION, and with Marshmallow’s new permission management scheme, requires users to explicitly accept the permission.  Right before your code attempts to access fine location, user will see a popup asking if they would like to allow or deny your application’s access to this permission.  Our automated calabash UI tests failed because the dialog was covering elements they were trying to access, and the tests could not proceed.

I needed to amend our Calabash Ruby code to handle the dialogs for Marshmallow permissions, while still handling the older permissions model.

Continue reading

Posted in Android, Testing | 3 Comments

Book Review: The Facebook Effect

Facebook website and facebook library bookAfter reading Peter Thiel’s book Zero to One (which is actually a love letter to Mark Zuckerberg and Elon Musk, if you read in between the lines), I became interested in learning more about Mark Zuckerberg, Facebook’s founder & CEO.  So I decided to snoop around for a good book on Zuckerberg, and settled on The Facebook Effect by David Kirkpatrick.  This book was written five years ago in 2010, which makes it positively ancient by internet standards, especially when you consider that the timeline of the entire book is just seven years.  However, after skimming other books and Amazon reviews, it seemed like the best one to dive into. Besides, I was primarily interested in the story line from Facebook’s conception to its opening to global users, which would all be covered in the timeline.

Unlike the Yahoo / Marissa Mayer book, the Facebook story was one I was relatively familiar with in the fact that I had been a user of the product from fairly early on. It was interesting to reflect on how I had used Facebook personally through the years. I recalled the frenzy and excitement of Facebook coming to my university, using it to connect with other students from massive lecture courses to form study groups, and establishing silly campus groups to join. I also recalled the shift in my perception of Facebook, when it became open to everyone; it went from a place to connect with friends and be silly, to a place where I really started to police my tone, because anyone from my 8 year old niece to my 80 year old great aunt was watching. It changed from the cool hip thing, to this really uncool thing.  But interestingly enough, this uncool thing is actually really difficult to leave. So many of my friends and family have transferred their regular lives into Facebook, that I was going to miss out on engagement announcements and baby shower invites if I left. So I stayed.

Continue reading

Posted in Books, Business | Leave a comment

Be Polite with Android Broadcast Receiver

Performance, or ‘perf’ as all the cool kids now say, is a big topic in the Android world.  No matter how sleek your UX / UI, if your app is laggy or crashy, users will not be happy. Unfortunately, there is no silver bullet for performance; there is no one line code fix, and no library you can import to get good performance.  A high performing application is the result of many incremental software design and implementation decisions. On top of that, you have to be constantly monitoring your app’s performance. Any refactoring or new feature could result in a drop in performance. In other words, its not exactly easy.

Recently I refactored my Lunch In Receiver code a little. It was a simple refactor that could help performance, so I figured I’d share it!

An Android Broadcast Receiver is a background entity that receives information about the surrounding environment it has been designated to care about.  By default receivers are “always on,” meaning they are always listening in for their designated event to occur.  This means a user could download your app but never open it, yet a Broadcast Receiver in your app is firing away.

For many apps, a Broadcast Receiver’s actions might not make sense if the user hasn’t at least opened the app and performed some tasks. This was the case for the LunchOutDetectionReceiver in Lunch In.

This Broadcast Receiver listens for a change in wifi state to detect if you have left your office by moving off the office wifi signal.  The actual receiver fires if there is any change in wifi state, and then the code within the receiver checks to see if your change was related to your work wifi or not. Since receivers are “on” as soon as the app is installed, the receiver could be firing and checking against the user’s work wifi, before the user has even registered their work wifi in the apps settings. 🙁 This is wasteful!

Luckily, you can disable your Receiver until it makes sense to turn it on. The solution is easy and has 2 parts:

Continue reading

Posted in Android | Leave a comment

Book Review: Zero to One

IMG_20150703_125455810

As an engineer I’ve spent the last 10 years of my life devoted to technical details.  For most of this time all I could tell you about business was what I’d learned in college: B-schoolers get to party on Thursdays because they don’t have class on Fridays. 😉 Recently I’ve become intent on learning more about how business directly influences the technical projects I work on as an engineer.

A few months ago during an engaging conversation about tech business with my uncle, a university professor of business, he recommended I read Zero to One: Notes on Startups, or, How to Build the Future by Peter Thiel.  For those of you who don’t know of Mr. Thiel, he “co-founded PayPal and Palantir, made the first outside investment in Facebook, funded companies like SpaceX and LinkedIn, and started the Thiel Fellowship, which encourages young people to put learning before college” (excerpt taken from the back cover of Zero to One).

The title of the book comes from Thiel’s explanation of killer companies: they create something that has *never* been done before (moving from zero to one) as opposed to creating incremental improvement on an idea somebody else has already implemented (moving from n to n+1).

Continue reading

Posted in Books, Business | 2 Comments

Hackathon: Financial Literacy Summer Jam

lunchin

A few months ago Chiu-Ki Chan approached me with the idea of starting up an intermediate level study group for Android Development, where members would work on open source projects together. I loved the idea! She even had a cool name picked out: Android Atelier.

If you are in the area, you should come join us!

For our first team project we decided to submit to an online hackathon, the Venmo Financial Literacy Summer Jam.  Its been a lot of fun to meet other Android devs and work on a fun project with them.  And even more exciting, we won a prize at the hackathon! Yippee!

Check out our submission here.

We’re going to spend our next meetups putting some extra polish on our app, and cleaning up the code.  Hopefully we can release to the play store, and help everyone save money by eating lunch in. 🙂

Posted in Android, Hackathons | Leave a comment

AnDevCon Boston 2015

boston

I just got back from speaking about Accessibility at AnDevCon Boston, and I had a great time! AnDevCon has a really special place in my heart, because it was the first technical conference I attended to kick start my Android career.  It was also during that conference that the public speaking seed was planted in my mind.  Check out this tweet from my first AnDevCon:

…. and after a lot of hard work and help from some fantastic mentors, I finally made it to the podium at AnDevCon. Wow! 😀

Continue reading

Posted in Android, Conferences, Speaking | Leave a comment