修正:
首先对应activity的manifest文件中必须加入:android:theme标签。
然后activity中的onCreate函数:
requestWindowFeature(Window.FEATURE_CUSTOM_TITLE);
setContentView(layoutResID);
getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.custom_title);
修正:
首先对应activity的manifest文件中必须加入:android:theme标签。
然后activity中的onCreate函数:
requestWindowFeature(Window.FEATURE_CUSTOM_TITLE);
setContentView(layoutResID);
getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.custom_title);