Only enable kEnableBeginFrameScheduling for offscreen
It has effects on performance and only gets turned on after Chrome 54.
This commit is contained in:
parent
63c34f3dcf
commit
aefd99ec7f
1 changed files with 5 additions and 1 deletions
|
@ -187,6 +187,10 @@ void WebContentsPreferences::AppendExtraCommandLineSwitches(
|
|||
command_line->AppendSwitch("hidden-page");
|
||||
}
|
||||
|
||||
// Use frame scheduling for offscreen renderers.
|
||||
// TODO(zcbenz): Remove this after Chrome 54, on which it becomes default.
|
||||
bool offscreen;
|
||||
if (web_preferences.Get("offscreen", &offscreen) && offscreen)
|
||||
command_line->AppendSwitch(cc::switches::kEnableBeginFrameScheduling);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue