Skip to content

Commit

Permalink
Merge "Make Settings show in two-pane on portrait tablet" into tm-qpr…
Browse files Browse the repository at this point in the history
…-dev
  • Loading branch information
TreeHugger Robot authored and Android (Google) Code Review committed Feb 17, 2023
2 parents 67b00f0 + 1881749 commit 6014caf
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@

import androidx.window.embedding.ActivityFilter;
import androidx.window.embedding.ActivityRule;
import androidx.window.embedding.EmbeddingAspectRatio;
import androidx.window.embedding.RuleController;
import androidx.window.embedding.SplitAttributes;
import androidx.window.embedding.SplitPairFilter;
Expand Down Expand Up @@ -110,6 +111,7 @@ public static void registerTwoPanePairRule(Context context,
.setClearTop(clearTop)
.setMinWidthDp(ActivityEmbeddingUtils.getMinCurrentScreenSplitWidthDp())
.setMinSmallestWidthDp(ActivityEmbeddingUtils.getMinSmallestScreenSplitWidthDp())
.setMaxAspectRatioInPortrait(EmbeddingAspectRatio.alwaysAllow())
.setDefaultSplitAttributes(attributes)
.build();
RuleController.getInstance(context).addRule(splitPairRule);
Expand Down Expand Up @@ -230,6 +232,7 @@ private void registerHomepagePlaceholderRule() {
activityFilters, intent)
.setMinWidthDp(ActivityEmbeddingUtils.getMinCurrentScreenSplitWidthDp())
.setMinSmallestWidthDp(ActivityEmbeddingUtils.getMinSmallestScreenSplitWidthDp())
.setMaxAspectRatioInPortrait(EmbeddingAspectRatio.alwaysAllow())
.setSticky(false)
.setFinishPrimaryWithPlaceholder(SplitRule.FinishBehavior.ADJACENT)
.setDefaultSplitAttributes(attributes)
Expand Down

0 comments on commit 6014caf

Please sign in to comment.