mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Delete Alloy bootstrap (fixes #3685)
This commit is contained in:
@@ -21,7 +21,6 @@
|
||||
#include "cef/libcef/browser/image_impl.h"
|
||||
#include "cef/libcef/browser/views/widget.h"
|
||||
#include "cef/libcef/browser/views/window_impl.h"
|
||||
#include "cef/libcef/features/runtime.h"
|
||||
#include "ui/base/hit_test.h"
|
||||
#include "ui/display/screen.h"
|
||||
#include "ui/views/widget/widget.h"
|
||||
@@ -357,36 +356,15 @@ void UpdateModalDialogPosition(views::Widget* widget,
|
||||
}
|
||||
|
||||
bool ComputeAlloyStyle(CefWindowDelegate* cef_delegate) {
|
||||
#if BUILDFLAG(ENABLE_ALLOY_BOOTSTRAP)
|
||||
const bool supports_chrome_style = cef::IsChromeRuntimeEnabled();
|
||||
const auto default_style = cef::IsAlloyRuntimeEnabled()
|
||||
? CEF_RUNTIME_STYLE_ALLOY
|
||||
: CEF_RUNTIME_STYLE_CHROME;
|
||||
#else
|
||||
const auto default_style = CEF_RUNTIME_STYLE_CHROME;
|
||||
#endif
|
||||
|
||||
auto result_style = default_style;
|
||||
|
||||
if (cef_delegate) {
|
||||
auto requested_style = cef_delegate->GetWindowRuntimeStyle();
|
||||
#if BUILDFLAG(ENABLE_ALLOY_BOOTSTRAP)
|
||||
if (requested_style == CEF_RUNTIME_STYLE_ALLOY) {
|
||||
// Alloy style is always supported.
|
||||
result_style = requested_style;
|
||||
} else if (requested_style == CEF_RUNTIME_STYLE_CHROME) {
|
||||
if (supports_chrome_style) {
|
||||
result_style = requested_style;
|
||||
} else {
|
||||
LOG(ERROR) << "GetWindowRuntimeStyle() requested Chrome style; only "
|
||||
"Alloy style is supported";
|
||||
}
|
||||
}
|
||||
#else
|
||||
if (requested_style != CEF_RUNTIME_STYLE_DEFAULT) {
|
||||
result_style = requested_style;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
return result_style == CEF_RUNTIME_STYLE_ALLOY;
|
||||
|
Reference in New Issue
Block a user