本文整理汇总了Java中com.aries.ui.view.title.TitleBarView.setTitleMainText方法的典型用法代码示例。如果您正苦于以下问题:Java TitleBarView.setTitleMainText方法的具体用法?Java TitleBarView.setTitleMainText怎么用?Java TitleBarView.setTitleMainText使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.aries.ui.view.title.TitleBarView
的用法示例。
在下文中一共展示了TitleBarView.setTitleMainText方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: initTitle
import com.aries.ui.view.title.TitleBarView; //导入方法依赖的package包/类
protected void initTitle() {
titleBar = (TitleBarView) findViewById(R.id.titleBar);
if (titleBar == null) {
return;
}
type = titleBar.getStatusBarModeType();
if (type <= 0) {//无法设置白底黑字
titleBar.setStatusAlpha(102);//5.0 半透明模式alpha-102
}
titleBar.setTitleMainText(mContext.getClass().getSimpleName());
setTitleBar();
titleBar.setOnLeftTextClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
onBackPressed();
}
});
setTitleLine(isShowLine());
}
示例2: setTitleBar
import com.aries.ui.view.title.TitleBarView; //导入方法依赖的package包/类
@Override
public void setTitleBar(TitleBarView titleBar) {
titles = getResources().getStringArray(R.array.arrays_tab_news);
mPosition = getArguments().getInt("position");
titleBar.setTitleMainTextSize(TypedValue.COMPLEX_UNIT_DIP, 16);
if (mPosition == 3) {
titleBar.setTitleMainTextColor(Color.WHITE)
.setBackgroundResource(R.color.colorMainAli);
}
if (mPosition == 0 || mPosition == 2) {
View view = View.inflate(mContext, R.layout.layout_news_sliding, null);
mSlidingTab = view.findViewById(R.id.tabLayout_slidingNews);
titleBar.addCenterAction(titleBar.new ViewAction(view));
} else {
titleBar.setTitleMainText(titles[mPosition]);
}
titleBar.setLeftTextDrawable(mPosition == 0 || mPosition == 1 ? R.drawable.ic_news_search : 0)
.setLeftText(mPosition == 1 ? getString(R.string.find) : "")
.setRightTextDrawable(mPosition == 3 ? R.drawable.ic_news_setting_normal : mPosition == 0 ? R.drawable.ic_news_channel_plus : 0);
}
示例3: setTitleBar
import com.aries.ui.view.title.TitleBarView; //导入方法依赖的package包/类
@Override
public void setTitleBar(TitleBarView titleBar) {
titleBar.setTitleMainText("ToastUtil工具类示例");
}
示例4: setTitleBar
import com.aries.ui.view.title.TitleBarView; //导入方法依赖的package包/类
@Override
public void setTitleBar(TitleBarView titleBar) {
titleBar.setTitleMainText(R.string.third_part);
}
示例5: setTitleBar
import com.aries.ui.view.title.TitleBarView; //导入方法依赖的package包/类
@Override
public void setTitleBar(TitleBarView titleBar) {
titleBar.setTitleMainText(R.string.setting);
}
示例6: setTitleBar
import com.aries.ui.view.title.TitleBarView; //导入方法依赖的package包/类
@Override
public void setTitleBar(TitleBarView titleBar) {
titleBar.setTitleMainText(R.string.mine);
}