Remove compile-time checks for toolkit_views

The toolkit_views=true setting is supported (and now required) on all platforms.
This commit is contained in:
Marshall Greenblatt
2022-04-11 18:50:05 -04:00
parent a0a7a35fe2
commit 17cb26b8b9
15 changed files with 170 additions and 471 deletions

View File

@@ -6,14 +6,11 @@
#include "include/cef_browser.h"
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
#include "libcef/browser/chrome/chrome_browser_host_impl.h"
#include "libcef/browser/chrome/views/chrome_child_window.h"
#include "libcef/browser/context.h"
#include "libcef/browser/thread_util.h"
#include "libcef/features/runtime.h"
#if defined(TOOLKIT_VIEWS)
#include "libcef/browser/chrome/views/chrome_child_window.h"
#endif
namespace {
class CreateBrowserHelper {
@@ -164,12 +161,10 @@ void CefBrowserCreateParams::MaybeSetWindowInfo(
CefRefPtr<CefBrowserHostBase> CefBrowserHostBase::Create(
CefBrowserCreateParams& create_params) {
if (cef::IsChromeRuntimeEnabled()) {
#if defined(TOOLKIT_VIEWS)
if (auto browser =
chrome_child_window::MaybeCreateChildBrowser(create_params)) {
return browser.get();
}
#endif
auto browser = ChromeBrowserHostImpl::Create(create_params);
return browser.get();
}