You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description: AppBarLayout.LayoutParams defaults scrollFlags to SCROLL_FLAG_SCROLL (1) at field declaration, but XML inflation defaults to 0 (no scroll) when attribute is absent.
Expected behavior:
Both should default to 0 for consistency.
Source code:
// Field declaration - defaults to 1intscrollFlags = SCROLL_FLAG_SCROLL;
// XML inflation - defaults to 0 when attribute missingscrollFlags = a.getInt(R.styleable.AppBarLayout_Layout_layout_scrollFlags, 0);
Workaround:
Explicitly set params.scrollFlags = 0 when creating programmatically.
Description:
AppBarLayout.LayoutParamsdefaultsscrollFlagstoSCROLL_FLAG_SCROLL(1) at field declaration, but XML inflation defaults to0(no scroll) when attribute is absent.Expected behavior:
Both should default to
0for consistency.Source code:
Workaround:
Explicitly set
params.scrollFlags = 0when creating programmatically.