mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Update to Chromium revision 66afc5e5 (#540276)
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
#include "chrome/common/chrome_paths.h"
|
||||
#include "chrome/common/chrome_switches.h"
|
||||
#include "components/content_settings/core/common/content_settings_pattern.h"
|
||||
#include "components/viz/common/features.h"
|
||||
#include "content/public/browser/browser_main_runner.h"
|
||||
#include "content/public/browser/render_process_host.h"
|
||||
#include "content/public/common/content_features.h"
|
||||
@@ -34,7 +35,7 @@
|
||||
#include "content/public/common/main_function_params.h"
|
||||
#include "extensions/common/constants.h"
|
||||
#include "ipc/ipc_features.h"
|
||||
#include "pdf/pdf.h"
|
||||
#include "pdf/pdf_ppapi.h"
|
||||
#include "ui/base/layout.h"
|
||||
#include "ui/base/material_design/material_design_controller.h"
|
||||
#include "ui/base/resource/resource_bundle.h"
|
||||
@@ -437,19 +438,36 @@ bool CefMainDelegate::BasicStartupComplete(int* exit_code) {
|
||||
base::IntToString(settings.uncaught_exception_stack_size));
|
||||
}
|
||||
|
||||
// Disable AsyncWheelEvents when OSR is enabled to avoid DCHECKs in
|
||||
// MouseWheelEventQueue.
|
||||
if (settings.windowless_rendering_enabled &&
|
||||
features::kAsyncWheelEvents.default_state ==
|
||||
base::FEATURE_ENABLED_BY_DEFAULT) {
|
||||
std::vector<std::string> disable_features;
|
||||
|
||||
if (settings.windowless_rendering_enabled) {
|
||||
// Disable AsyncWheelEvents when OSR is enabled to avoid DCHECKs in
|
||||
// MouseWheelEventQueue.
|
||||
if (features::kAsyncWheelEvents.default_state ==
|
||||
base::FEATURE_ENABLED_BY_DEFAULT) {
|
||||
disable_features.push_back(features::kAsyncWheelEvents.name);
|
||||
}
|
||||
|
||||
// Disable SurfaceSynchronization when OSR is enabled, otherwise rendering
|
||||
// will fail.
|
||||
if (features::kEnableSurfaceSynchronization.default_state ==
|
||||
base::FEATURE_ENABLED_BY_DEFAULT) {
|
||||
disable_features.push_back(
|
||||
features::kEnableSurfaceSynchronization.name);
|
||||
}
|
||||
}
|
||||
|
||||
if (!disable_features.empty()) {
|
||||
DCHECK(!base::FeatureList::GetInstance());
|
||||
std::string disable_features =
|
||||
std::string disable_features_str =
|
||||
command_line->GetSwitchValueASCII(switches::kDisableFeatures);
|
||||
if (!disable_features.empty())
|
||||
disable_features += ",";
|
||||
disable_features += features::kAsyncWheelEvents.name;
|
||||
for (auto feature_str : disable_features) {
|
||||
if (!disable_features_str.empty())
|
||||
disable_features_str += ",";
|
||||
disable_features_str += feature_str;
|
||||
}
|
||||
command_line->AppendSwitchASCII(switches::kDisableFeatures,
|
||||
disable_features);
|
||||
disable_features_str);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user