[英]How can I divide the Action bar of android while adding more than one fragment on Activity
Is there any way to put the search icon aligned with the left fragment(list of email) and others action bar action related to right fragment(detail of selected email)with right.有没有办法将搜索图标与左侧片段(电子邮件列表)和其他与右侧片段(所选电子邮件的详细信息)相关的操作栏操作与右侧对齐。 Is there any way (custom or standard) to utilize the status bar for putting icon related to fragment like in gmail app.有没有办法(自定义或标准)利用状态栏来放置与 gmail 应用程序中的片段相关的图标。
It's not status bar, it's ActionBar.它不是状态栏,而是 ActionBar。 Yes, you can.是的你可以。 In your Activity, before setContentView
:在您的活动中,在setContentView
之前:
requestWindowFeature(Window.FEATURE_CUSTOM_TITLE);
this.getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.title);
So you need to make custom title
layout and put there everything you want所以你需要制作自定义title
布局并将你想要的一切放在那里
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.