Google: Developers to stop using menu button use Action Bar instead

0

Company wants developers to move to Action Bar from the traditional menu button in their Android apps. But I guess this is one of Google’s attempts to at least make it as consistent as possible. Many developers will no doubt follow suit.

“You might worry that it’s too much work to begin using the action bar, because you need to support versions of Android older than Honeycomb,” writes Scott Main on the Android developer blog. “However, it’s quite simple for most apps because you can continue to support the Menu button on pre-Honeycomb devices, but also provide the action bar on newer devices with only a few lines of code changes.”

He adds:

“If I had to put this whole post into one sentence, it’d be: Set targetSdkVersion to 14 and, if you use the options menu, surface a few actions in the action bar with showAsAction=”ifRoom”.

Developers should also stop thinking about activities using a “menu button” at all, just as apps should stop relying on a hardware menu button, he says. Activities, instead, should provide buttons for important actions directly in the action bar (or elsewhere on the screen), he says, adding that those that can’t fit into the action bar end up in the action overflow.

So what happens if those actions can’t fit on the action bar itself? Users will see the “overflow button” at the far right, which looks like a colon but with three dots, not two. Main also encouraged those apps writers who currently place the overflow button at the bottom of the screen to avoid doing so, to avoid user confusion.

Follow Us on our Channels: