Now Your Friends Seem Animated
statusItem.setTitle("Show Status Entry");
}
return(super.onPrepareOptionsMenu(menu));
}
Here, we see if the status entry row is visible and set our menu item
accordingly.
At this point, if you recompile and reinstall Patchy, you will see the new
menu item, though it will not do anything just yet:
Figure 44. The "Hide Status Entry" menu option in Patchy
Step #2: Show and Hide the Status Entry Widgets
It would be nice, of course, if the newly-created menu item actually did
something.
So, we need to add another case to onOptionsItemSelected() in Patchy to
handle this new menu item: