Revert "Revert "Support highlightable Settings homepage menu for 2-pane""
This reverts commit 096c090b80
.
Reason for revert: crash is fixed in this change
Bug: 202510128
Test: manual, build
Change-Id: Ifff8d58cfdcf43e123b11dee308665b2617cb4b3
This commit is contained in:
@@ -62,4 +62,12 @@ public class ActivityEmbeddingUtils {
|
||||
|
||||
return isFlagEnabled && isSplitSupported;
|
||||
}
|
||||
|
||||
/** Whether the screen meets two-pane resolution. */
|
||||
public static boolean isTwoPaneResolution(Context context) {
|
||||
final Context appContext = context.getApplicationContext();
|
||||
final DisplayMetrics dm = appContext.getResources().getDisplayMetrics();
|
||||
return dm.widthPixels >= getMinCurrentScreenSplitWidthPx(appContext)
|
||||
&& dm.heightPixels >= getMinSmallestScreenSplitWidthPx(appContext);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user