Delete Alloy bootstrap (fixes #3685)

This commit is contained in:
Marshall Greenblatt
2024-06-25 20:12:37 -04:00
parent b95b3e6fd5
commit a461a89728
282 changed files with 360 additions and 22399 deletions

View File

@@ -1,57 +0,0 @@
// Copyright 2022 The Chromium Embedded Framework Authors.
// Portions copyright 2020 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "cef/libcef/browser/alloy/dialogs/alloy_javascript_dialog_manager_delegate.h"
#include "base/logging.h"
#include "cef/libcef/browser/browser_host_base.h"
namespace {
class AlloyJavaScriptTabModalDialogManagerDelegateDesktop
: public JavaScriptTabModalDialogManagerDelegateDesktop {
public:
explicit AlloyJavaScriptTabModalDialogManagerDelegateDesktop(
content::WebContents* web_contents)
: JavaScriptTabModalDialogManagerDelegateDesktop(web_contents),
web_contents_(web_contents) {}
AlloyJavaScriptTabModalDialogManagerDelegateDesktop(
const AlloyJavaScriptTabModalDialogManagerDelegateDesktop&) = delete;
AlloyJavaScriptTabModalDialogManagerDelegateDesktop& operator=(
const AlloyJavaScriptTabModalDialogManagerDelegateDesktop&) = delete;
// javascript_dialogs::TabModalDialogManagerDelegate methods:
void WillRunDialog() override {}
void DidCloseDialog() override {}
void SetTabNeedsAttention(bool attention) override {}
bool IsWebContentsForemost() override {
if (auto browser =
CefBrowserHostBase::GetBrowserForContents(web_contents_)) {
return browser->IsVisible();
}
return false;
}
bool IsApp() override { return false; }
private:
// The WebContents for the tab over which the dialog will be modal. This may
// be different from the WebContents that requested the dialog, such as with
// Chrome app <webview>s.
raw_ptr<content::WebContents> web_contents_;
};
} // namespace
std::unique_ptr<JavaScriptTabModalDialogManagerDelegateDesktop>
CreateAlloyJavaScriptTabModalDialogManagerDelegateDesktop(
content::WebContents* web_contents) {
return std::make_unique<AlloyJavaScriptTabModalDialogManagerDelegateDesktop>(
web_contents);
}

View File

@@ -1,18 +0,0 @@
// Copyright 2022 The Chromium Embedded Framework Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CEF_LIBCEF_BROWSER_ALLOY_DIALOGS_ALLOY_JAVASCRIPT_DIALOG_MANAGER_DELEGATE_H_
#define CEF_LIBCEF_BROWSER_ALLOY_DIALOGS_ALLOY_JAVASCRIPT_DIALOG_MANAGER_DELEGATE_H_
#include <memory>
#include "chrome/browser/ui/javascript_dialogs/javascript_tab_modal_dialog_manager_delegate_desktop.h"
// Creates a JavaScriptTabModalDialogManagerDelegateDesktop for the Chrome
// environment.
std::unique_ptr<JavaScriptTabModalDialogManagerDelegateDesktop>
CreateAlloyJavaScriptTabModalDialogManagerDelegateDesktop(
content::WebContents* web_contents);
#endif // CEF_LIBCEF_BROWSER_ALLOY_DIALOGS_ALLOY_JAVASCRIPT_DIALOG_MANAGER_DELEGATE_H_