android: adding button to the title of the app?

android, layout

Solution

The simplest way to do that, IMHO, is to get rid of the standard title bar (`android:theme="@android:style/Theme.NoTitleBar"` in the `<activity>` element in the manifest) and put your own "title bar" at the top of the activity.

Note, though, that the "button in the title bar" style is more iPhone-ish. Android would typically have that in the option menu, so the UI is less cluttered (at the cost of two taps to do the refresh).

Problem

Is it possible to add a button to the right corner of the app title? e.g., adding a "refresh" button to the title of "Feed: my feeds"? http://www.android.com/market/apps/feedr-lg-01.jpg

Original source