Skip to content

Commit

Permalink
[android] Enable low end device mode (#4625)
Browse files Browse the repository at this point in the history
1. Enable low end device mode to reduce memory usage.
2. The rendering issue was due to the memory limits in Blink, which is
resolved in m126+, where two upstream commits
(#4636,
#4637) were cherry picked.

b/380310632
  • Loading branch information
borongc authored Jan 6, 2025
1 parent e581321 commit 173ecc3
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -104,11 +104,8 @@ protected void createContent(final Bundle savedInstanceState) {
if (!CommandLine.isInitialized()) {
((CobaltApplication) getApplication()).initCommandLine();

// Note that appendSwitchesAndArguments excludes cobaltCommandLineParams[0]
// as the program name, and all other arguments SHOULD start with '--'.
String[] cobaltCommandLineParams =
new String[] {
"",
// Disable first run experience.
"--disable-fre",
// Disable user prompts in the first run.
Expand All @@ -125,6 +122,8 @@ protected void createContent(final Bundle savedInstanceState) {
"--enable-features=LogJsConsoleMessages",
// Disable rescaling Webpage.
"--force-device-scale-factor=1",
// Enable low end device mode.
"--enable-low-end-device-mode",
};
CommandLine.getInstance().appendSwitchesAndArguments(cobaltCommandLineParams);

Expand Down

0 comments on commit 173ecc3

Please sign in to comment.