Summary of the method of setting full-screen untitled in Android ActionBarActivity
The newly created Activity inherits from ActionBarActivity. It is easy to set full screen without titles, but I didn’t expect that the app would hang for no reason, either with a white screen or a black screen. I've cheated on me for more than an hour! ! !
The reason is that when setting the ActionBarActivity theme, you can only use the theme starting with *** in the v7 package. Therefore, if you set the full screen without title, you need to customize a style:
<style name="ActionBarFullScreen" parent=""> <item name="android:windowFullscreen">true</item> <item name="android:windowNoTitle">true</item> <item name="android:windowContentOverlay">@null</item> </style>
Then in: Set android:theme="@style/ActionBarFullScreen" and it's OK!
Another solution is to change the inherited ActionBarActivity to FragmentActivity or Activity, and then set the theme directly
Android:theme="@android:style/"It's OK!
Thank you for reading, I hope it can help you. Thank you for your support for this site!