mirror of
https://github.com/material-components/material-components-android.git
synced 2026-02-20 08:39:55 +08:00
am 0fcf19cd: am 7021cb02: Merge "Allow CoordinatorLayout to handle root level pkg" into mnc-ub-dev
* commit '0fcf19cdbaabb79ed13568f3267cc6d827f94805': Allow CoordinatorLayout to handle root level pkg GitOrigin-RevId=3f787b7f9a4d67e423445fbcbbf983a5042737a4 PiperOrigin-RevId: 140550430
This commit is contained in:
parent
8dfd9da670
commit
ebd4649bb2
@ -87,7 +87,12 @@ import java.util.Map;
|
||||
*/
|
||||
public class CoordinatorLayout extends ViewGroup implements NestedScrollingParent {
|
||||
static final String TAG = "CoordinatorLayout";
|
||||
static final String WIDGET_PACKAGE_NAME = CoordinatorLayout.class.getPackage().getName();
|
||||
static final String WIDGET_PACKAGE_NAME;
|
||||
|
||||
static {
|
||||
final Package pkg = CoordinatorLayout.class.getPackage();
|
||||
WIDGET_PACKAGE_NAME = pkg != null ? pkg.getName() : null;
|
||||
}
|
||||
|
||||
private static final int TYPE_ON_INTERCEPT = 0;
|
||||
private static final int TYPE_ON_TOUCH = 1;
|
||||
@ -503,8 +508,10 @@ public class CoordinatorLayout extends ViewGroup implements NestedScrollingParen
|
||||
// Fully qualified package name.
|
||||
fullName = name;
|
||||
} else {
|
||||
// Assume stock behavior in this package.
|
||||
fullName = WIDGET_PACKAGE_NAME + '.' + name;
|
||||
// Assume stock behavior in this package (if we have one)
|
||||
fullName = !TextUtils.isEmpty(WIDGET_PACKAGE_NAME)
|
||||
? (WIDGET_PACKAGE_NAME + '.' + name)
|
||||
: name;
|
||||
}
|
||||
|
||||
try {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user