With the new Lollipop API, we have to use a Toolbar if we want to personalize the action bar aspect.
Adding a ProgressBar to the Toolbar is as simple as adding it to
I also hit the same wall, but programmatically it works:
Toolbar.LayoutParams layoutParams = new Toolbar.LayoutParams( ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT, Gravity.TOP | Gravity.RIGHT);
In my snippet, I align it to the top, to match the alignment of the menu.