I have an Activity
which extends the AppCompatActivity
and uses the support ActionBar
. Compile SDK version is 23, test devices SDK are 21-22.
I need to get the ActionBar
's title TextView
, however, the most known way of doing this
int resId = getResources().getIdentifier("action_bar_title", "id", "android");
return (TextView) findViewById(resId);
doesn't work starting with API 21. Is there a way to reference the title TextView
on Lollipop?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…