本文整理了Java中android.support.v7.widget.Toolbar.requestLayout()
方法的一些代码示例,展示了Toolbar.requestLayout()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Toolbar.requestLayout()
方法的具体详情如下:
包路径:android.support.v7.widget.Toolbar
类名称:Toolbar
方法名:requestLayout
暂无
代码示例来源:origin: powerpoint45/Lucid-Browser
@Override
public void onPageStarted(WebView view, String url, Bitmap favicon) {
if (activityRef.get()!=null && activityRef.get().webLayout!=null) {
CustomWebView WV = activityRef.get().webLayout
.findViewById(R.id.browser_page);
if (WV != null && CustomWebView.this == WV) {
if (PB == null)
try {
PB = activityRef.get().webLayout
.findViewById(R.id.webpgbar);
} catch (Exception e) {
}
if (view.getVisibility() == View.VISIBLE)
if (PB != null && PB.getVisibility() != View.VISIBLE
&& url.compareTo("about:blank") != 0)
PB.setVisibility(ProgressBar.VISIBLE);
ImageButton IB = activityRef.get().barHolder.findViewById(R.id.browser_refresh);
if (IB != null) {
IB.setImageResource(R.drawable.btn_toolbar_stop_loading_normal);
}
setUrlBarText(url);
//force colorize toolbar
activityRef.get().toolbar.requestLayout();
}
}
}
代码示例来源:origin: AbbyJM/weather
public static void setImmersiveStatusBarToolbar(@NonNull Toolbar toolbar, Context context) {
ViewGroup.MarginLayoutParams toolLayoutParams = (ViewGroup.MarginLayoutParams) toolbar.getLayoutParams();
toolLayoutParams.height = getStatusBarHeight() + getActionBarSize(context);
toolbar.setLayoutParams(toolLayoutParams);
toolbar.setPadding(0, getStatusBarHeight(), 0, 0);
toolbar.requestLayout();
}
代码示例来源:origin: ywwynm/EverythingDone
@Override
protected void setActionbar() {
FrameLayout.LayoutParams params = (FrameLayout.LayoutParams) mActionbar.getLayoutParams();
params.setMargins(0, DisplayUtil.getStatusbarHeight(this), 0, 0);
mActionbar.requestLayout();
setSupportActionBar(mActionbar);
ActionBar actionBar = getSupportActionBar();
if (actionBar != null) {
actionBar.setDisplayHomeAsUpEnabled(true);
}
updateAttachmentNumber();
mActionbar.setNavigationOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
returnToDetailActivity();
}
});
}
代码示例来源:origin: powerpoint45/Lucid-Browser
activityRef.get().toolbar.requestLayout();
代码示例来源:origin: kollerlukas/Camera-Roll-Android-App
toolbar.getLayoutParams());
selectorToolbar.requestLayout();
内容来源于网络,如有侵权,请联系作者删除!