Back at Twitter, I worked with the search team to introduce image results in the Android app. The designer came up with a wonderful layout that at that time, was challenging, but we managed to launch it.

Image for post
Image for post
Twitter image search (courtesy Twitter)

During that time, there was no RecyclerView, no abstract layout managers that can be extended to easily build an asymmetrical grid view. Instead of trying to reinvent ListView’s recycling logic, that gallery was built on ListView and LinearLayout in addition to some math to handle the edge cases.

Today, however, the Android ecosystem has a lot of abstractions that can be leveraged to build a similar gallery. In fact, it can be just built with the basic features available in the RecyclerView library and as before some math to handle the edge cases. …

About

bidyut

Engineer. Photographer. Writer.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store