mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Rename CefBrowserHostImpl to AlloyBrowserHostImpl (see issue #2969)
After commit 38d8acfa18
this object is only used with the alloy runtime.
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
|
||||
#include "libcef/browser/native/browser_platform_delegate_native.h"
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
|
||||
#include "content/public/browser/render_view_host.h"
|
||||
#include "content/public/browser/render_widget_host.h"
|
||||
|
@@ -6,7 +6,7 @@
|
||||
|
||||
#include <sys/sysinfo.h>
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
#include "libcef/browser/context.h"
|
||||
#include "libcef/browser/native/menu_runner_linux.h"
|
||||
#include "libcef/browser/native/window_delegate_view.h"
|
||||
@@ -50,7 +50,7 @@ CefBrowserPlatformDelegateNativeLinux::CefBrowserPlatformDelegateNativeLinux(
|
||||
window_widget_(nullptr) {}
|
||||
|
||||
void CefBrowserPlatformDelegateNativeLinux::BrowserDestroyed(
|
||||
CefBrowserHostImpl* browser) {
|
||||
AlloyBrowserHostImpl* browser) {
|
||||
CefBrowserPlatformDelegateNative::BrowserDestroyed(browser);
|
||||
|
||||
if (host_window_created_) {
|
||||
|
@@ -19,7 +19,7 @@ class CefBrowserPlatformDelegateNativeLinux
|
||||
SkColor background_color);
|
||||
|
||||
// CefBrowserPlatformDelegate methods:
|
||||
void BrowserDestroyed(CefBrowserHostImpl* browser) override;
|
||||
void BrowserDestroyed(AlloyBrowserHostImpl* browser) override;
|
||||
bool CreateHostWindow() override;
|
||||
void CloseHostWindow() override;
|
||||
CefWindowHandle GetHostWindowHandle() const override;
|
||||
|
@@ -19,7 +19,7 @@ class CefBrowserPlatformDelegateNativeMac
|
||||
SkColor background_color);
|
||||
|
||||
// CefBrowserPlatformDelegate methods:
|
||||
void BrowserDestroyed(CefBrowserHostImpl* browser) override;
|
||||
void BrowserDestroyed(AlloyBrowserHostImpl* browser) override;
|
||||
bool CreateHostWindow() override;
|
||||
void CloseHostWindow() override;
|
||||
CefWindowHandle GetHostWindowHandle() const override;
|
||||
|
@@ -7,7 +7,7 @@
|
||||
#import <Cocoa/Cocoa.h>
|
||||
#import <CoreServices/CoreServices.h>
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
#include "libcef/browser/context.h"
|
||||
#include "libcef/browser/native/file_dialog_runner_mac.h"
|
||||
#include "libcef/browser/native/javascript_dialog_runner_mac.h"
|
||||
@@ -34,10 +34,10 @@
|
||||
// the view is deleted.
|
||||
@interface CefBrowserHostView : NSView {
|
||||
@private
|
||||
CefBrowserHostImpl* browser_; // weak
|
||||
AlloyBrowserHostImpl* browser_; // weak
|
||||
}
|
||||
|
||||
@property(nonatomic, assign) CefBrowserHostImpl* browser;
|
||||
@property(nonatomic, assign) AlloyBrowserHostImpl* browser;
|
||||
|
||||
@end
|
||||
|
||||
@@ -60,15 +60,17 @@
|
||||
// Receives notifications from the browser window. Will delete itself when done.
|
||||
@interface CefWindowDelegate : NSObject <NSWindowDelegate> {
|
||||
@private
|
||||
CefBrowserHostImpl* browser_; // weak
|
||||
AlloyBrowserHostImpl* browser_; // weak
|
||||
NSWindow* window_;
|
||||
}
|
||||
- (id)initWithWindow:(NSWindow*)window andBrowser:(CefBrowserHostImpl*)browser;
|
||||
- (id)initWithWindow:(NSWindow*)window
|
||||
andBrowser:(AlloyBrowserHostImpl*)browser;
|
||||
@end
|
||||
|
||||
@implementation CefWindowDelegate
|
||||
|
||||
- (id)initWithWindow:(NSWindow*)window andBrowser:(CefBrowserHostImpl*)browser {
|
||||
- (id)initWithWindow:(NSWindow*)window
|
||||
andBrowser:(AlloyBrowserHostImpl*)browser {
|
||||
if (self = [super init]) {
|
||||
window_ = window;
|
||||
browser_ = browser;
|
||||
@@ -150,7 +152,7 @@ CefBrowserPlatformDelegateNativeMac::CefBrowserPlatformDelegateNativeMac(
|
||||
host_window_created_(false) {}
|
||||
|
||||
void CefBrowserPlatformDelegateNativeMac::BrowserDestroyed(
|
||||
CefBrowserHostImpl* browser) {
|
||||
AlloyBrowserHostImpl* browser) {
|
||||
CefBrowserPlatformDelegateNative::BrowserDestroyed(browser);
|
||||
|
||||
if (host_window_created_) {
|
||||
|
@@ -8,7 +8,7 @@
|
||||
#include <wininet.h>
|
||||
#include <winspool.h>
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
#include "libcef/browser/context.h"
|
||||
#include "libcef/browser/native/file_dialog_runner_win.h"
|
||||
#include "libcef/browser/native/javascript_dialog_runner_win.h"
|
||||
@@ -132,7 +132,7 @@ CefBrowserPlatformDelegateNativeWin::CefBrowserPlatformDelegateNativeWin(
|
||||
window_widget_(nullptr) {}
|
||||
|
||||
void CefBrowserPlatformDelegateNativeWin::BrowserDestroyed(
|
||||
CefBrowserHostImpl* browser) {
|
||||
AlloyBrowserHostImpl* browser) {
|
||||
CefBrowserPlatformDelegateNative::BrowserDestroyed(browser);
|
||||
|
||||
if (host_window_created_) {
|
||||
@@ -530,7 +530,7 @@ LRESULT CALLBACK CefBrowserPlatformDelegateNativeWin::WndProc(HWND hwnd,
|
||||
WPARAM wParam,
|
||||
LPARAM lParam) {
|
||||
CefBrowserPlatformDelegateNativeWin* platform_delegate = nullptr;
|
||||
CefBrowserHostImpl* browser = nullptr;
|
||||
AlloyBrowserHostImpl* browser = nullptr;
|
||||
|
||||
if (message != WM_NCCREATE) {
|
||||
platform_delegate = static_cast<CefBrowserPlatformDelegateNativeWin*>(
|
||||
|
@@ -17,7 +17,7 @@ class CefBrowserPlatformDelegateNativeWin
|
||||
SkColor background_color);
|
||||
|
||||
// CefBrowserPlatformDelegate methods:
|
||||
void BrowserDestroyed(CefBrowserHostImpl* browser) override;
|
||||
void BrowserDestroyed(AlloyBrowserHostImpl* browser) override;
|
||||
bool CreateHostWindow() override;
|
||||
void CloseHostWindow() override;
|
||||
CefWindowHandle GetHostWindowHandle() const override;
|
||||
|
@@ -18,7 +18,7 @@ class CefFileDialogRunnerMac : public CefFileDialogRunner {
|
||||
CefFileDialogRunnerMac();
|
||||
|
||||
// CefFileDialogRunner methods:
|
||||
void Run(CefBrowserHostImpl* browser,
|
||||
void Run(AlloyBrowserHostImpl* browser,
|
||||
const FileChooserParams& params,
|
||||
RunFileChooserCallback callback) override;
|
||||
|
||||
|
@@ -8,7 +8,7 @@
|
||||
#import <Cocoa/Cocoa.h>
|
||||
#import <CoreServices/CoreServices.h>
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
|
||||
#include "base/mac/mac_util.h"
|
||||
#include "base/stl_util.h"
|
||||
@@ -231,7 +231,7 @@ void AddFilters(NSPopUpButton* button,
|
||||
|
||||
CefFileDialogRunnerMac::CefFileDialogRunnerMac() : weak_ptr_factory_(this) {}
|
||||
|
||||
void CefFileDialogRunnerMac::Run(CefBrowserHostImpl* browser,
|
||||
void CefFileDialogRunnerMac::Run(AlloyBrowserHostImpl* browser,
|
||||
const FileChooserParams& params,
|
||||
RunFileChooserCallback callback) {
|
||||
callback_ = std::move(callback);
|
||||
|
@@ -11,7 +11,7 @@
|
||||
#include <shlobj.h>
|
||||
#include <wrl/client.h>
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
|
||||
#include "base/files/file_util.h"
|
||||
#include "base/stl_util.h"
|
||||
@@ -517,7 +517,7 @@ bool RunSaveFileDialog(const CefFileDialogRunner::FileChooserParams& params,
|
||||
|
||||
CefFileDialogRunnerWin::CefFileDialogRunnerWin() {}
|
||||
|
||||
void CefFileDialogRunnerWin::Run(CefBrowserHostImpl* browser,
|
||||
void CefFileDialogRunnerWin::Run(AlloyBrowserHostImpl* browser,
|
||||
const FileChooserParams& params,
|
||||
RunFileChooserCallback callback) {
|
||||
int filter_index = params.selected_accept_filter;
|
||||
|
@@ -14,7 +14,7 @@ class CefFileDialogRunnerWin : public CefFileDialogRunner {
|
||||
CefFileDialogRunnerWin();
|
||||
|
||||
// CefFileDialogRunner methods:
|
||||
void Run(CefBrowserHostImpl* browser,
|
||||
void Run(AlloyBrowserHostImpl* browser,
|
||||
const FileChooserParams& params,
|
||||
RunFileChooserCallback callback) override;
|
||||
};
|
||||
|
@@ -24,7 +24,7 @@ class CefJavaScriptDialogRunnerMac : public CefJavaScriptDialogRunner {
|
||||
~CefJavaScriptDialogRunnerMac() override;
|
||||
|
||||
// CefJavaScriptDialogRunner methods:
|
||||
void Run(CefBrowserHostImpl* browser,
|
||||
void Run(AlloyBrowserHostImpl* browser,
|
||||
content::JavaScriptDialogType message_type,
|
||||
const base::string16& display_url,
|
||||
const base::string16& message_text,
|
||||
|
@@ -87,7 +87,7 @@ CefJavaScriptDialogRunnerMac::~CefJavaScriptDialogRunnerMac() {
|
||||
}
|
||||
|
||||
void CefJavaScriptDialogRunnerMac::Run(
|
||||
CefBrowserHostImpl* browser,
|
||||
AlloyBrowserHostImpl* browser,
|
||||
content::JavaScriptDialogType message_type,
|
||||
const base::string16& display_url,
|
||||
const base::string16& message_text,
|
||||
|
@@ -5,7 +5,7 @@
|
||||
|
||||
#include "libcef/browser/native/javascript_dialog_runner_win.h"
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
#include "libcef_dll/resource.h"
|
||||
|
||||
#include "base/files/file_path.h"
|
||||
@@ -91,7 +91,7 @@ CefJavaScriptDialogRunnerWin::~CefJavaScriptDialogRunnerWin() {
|
||||
}
|
||||
|
||||
void CefJavaScriptDialogRunnerWin::Run(
|
||||
CefBrowserHostImpl* browser,
|
||||
AlloyBrowserHostImpl* browser,
|
||||
content::JavaScriptDialogType message_type,
|
||||
const base::string16& display_url,
|
||||
const base::string16& message_text,
|
||||
|
@@ -17,7 +17,7 @@ class CefJavaScriptDialogRunnerWin : public CefJavaScriptDialogRunner {
|
||||
~CefJavaScriptDialogRunnerWin() override;
|
||||
|
||||
// CefJavaScriptDialogRunner methods:
|
||||
void Run(CefBrowserHostImpl* browser,
|
||||
void Run(AlloyBrowserHostImpl* browser,
|
||||
content::JavaScriptDialogType message_type,
|
||||
const base::string16& display_url,
|
||||
const base::string16& message_text,
|
||||
|
@@ -4,7 +4,7 @@
|
||||
|
||||
#include "libcef/browser/native/menu_runner_linux.h"
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
|
||||
#include "base/compiler_specific.h"
|
||||
#include "base/strings/string_util.h"
|
||||
@@ -13,7 +13,7 @@
|
||||
CefMenuRunnerLinux::CefMenuRunnerLinux() {}
|
||||
|
||||
bool CefMenuRunnerLinux::RunContextMenu(
|
||||
CefBrowserHostImpl* browser,
|
||||
AlloyBrowserHostImpl* browser,
|
||||
CefMenuModelImpl* model,
|
||||
const content::ContextMenuParams& params) {
|
||||
menu_.reset(
|
||||
|
@@ -15,7 +15,7 @@ class CefMenuRunnerLinux : public CefMenuRunner {
|
||||
CefMenuRunnerLinux();
|
||||
|
||||
// CefMenuRunner methods.
|
||||
bool RunContextMenu(CefBrowserHostImpl* browser,
|
||||
bool RunContextMenu(AlloyBrowserHostImpl* browser,
|
||||
CefMenuModelImpl* model,
|
||||
const content::ContextMenuParams& params) override;
|
||||
void CancelContextMenu() override;
|
||||
|
@@ -22,7 +22,7 @@ class CefMenuRunnerMac : public CefMenuRunner {
|
||||
~CefMenuRunnerMac() override;
|
||||
|
||||
// CefMenuRunner methods.
|
||||
bool RunContextMenu(CefBrowserHostImpl* browser,
|
||||
bool RunContextMenu(AlloyBrowserHostImpl* browser,
|
||||
CefMenuModelImpl* model,
|
||||
const content::ContextMenuParams& params) override;
|
||||
void CancelContextMenu() override;
|
||||
|
@@ -4,7 +4,7 @@
|
||||
|
||||
#include "libcef/browser/native/menu_runner_mac.h"
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
|
||||
#include "base/compiler_specific.h"
|
||||
#import "base/mac/scoped_sending_event.h"
|
||||
@@ -17,7 +17,7 @@ CefMenuRunnerMac::CefMenuRunnerMac() {}
|
||||
CefMenuRunnerMac::~CefMenuRunnerMac() {}
|
||||
|
||||
bool CefMenuRunnerMac::RunContextMenu(
|
||||
CefBrowserHostImpl* browser,
|
||||
AlloyBrowserHostImpl* browser,
|
||||
CefMenuModelImpl* model,
|
||||
const content::ContextMenuParams& params) {
|
||||
// Create a menu controller based on the model.
|
||||
|
@@ -4,7 +4,7 @@
|
||||
|
||||
#include "libcef/browser/native/menu_runner_win.h"
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
#include "libcef/browser/native/menu_2.h"
|
||||
|
||||
#include "base/task/current_thread.h"
|
||||
@@ -13,7 +13,7 @@
|
||||
CefMenuRunnerWin::CefMenuRunnerWin() {}
|
||||
|
||||
bool CefMenuRunnerWin::RunContextMenu(
|
||||
CefBrowserHostImpl* browser,
|
||||
AlloyBrowserHostImpl* browser,
|
||||
CefMenuModelImpl* model,
|
||||
const content::ContextMenuParams& params) {
|
||||
// Create a menu based on the model.
|
||||
|
@@ -15,7 +15,7 @@ class CefMenuRunnerWin : public CefMenuRunner {
|
||||
CefMenuRunnerWin();
|
||||
|
||||
// CefMenuRunner methods.
|
||||
bool RunContextMenu(CefBrowserHostImpl* browser,
|
||||
bool RunContextMenu(AlloyBrowserHostImpl* browser,
|
||||
CefMenuModelImpl* model,
|
||||
const content::ContextMenuParams& params) override;
|
||||
|
||||
|
@@ -47,7 +47,7 @@ void CefWindowDelegateView::Init(gfx::AcceleratedWidget parent_widget,
|
||||
// Tell Aura not to draw the window frame on resize.
|
||||
params.remove_standard_frame = true;
|
||||
// Cause WidgetDelegate::CanActivate to return true. See comments in
|
||||
// CefBrowserHostImpl::PlatformSetFocus.
|
||||
// AlloyBrowserHostImpl::PlatformSetFocus.
|
||||
params.activatable = views::Widget::InitParams::ACTIVATABLE_YES;
|
||||
|
||||
params.z_order = always_on_top_ ? ui::ZOrderLevel::kFloatingWindow
|
||||
|
@@ -92,7 +92,7 @@ CEF_EXPORT XDisplay* cef_get_xdisplay() {
|
||||
return gfx::GetXDisplay();
|
||||
}
|
||||
|
||||
CefWindowX11::CefWindowX11(CefRefPtr<CefBrowserHostImpl> browser,
|
||||
CefWindowX11::CefWindowX11(CefRefPtr<AlloyBrowserHostImpl> browser,
|
||||
::Window parent_xwindow,
|
||||
const gfx::Rect& bounds,
|
||||
const std::string& title)
|
||||
|
@@ -12,7 +12,7 @@ typedef unsigned long Window;
|
||||
struct _XDisplay;
|
||||
typedef struct _XDisplay Display;
|
||||
|
||||
#include "libcef/browser/browser_host_impl.h"
|
||||
#include "libcef/browser/alloy/alloy_browser_host_impl.h"
|
||||
|
||||
#include "base/memory/weak_ptr.h"
|
||||
#include "ui/events/platform/platform_event_dispatcher.h"
|
||||
@@ -29,7 +29,7 @@ class DesktopWindowTreeHostLinux;
|
||||
class CefWindowX11 : public ui::PlatformEventDispatcher,
|
||||
public ui::XEventDispatcher {
|
||||
public:
|
||||
CefWindowX11(CefRefPtr<CefBrowserHostImpl> browser,
|
||||
CefWindowX11(CefRefPtr<AlloyBrowserHostImpl> browser,
|
||||
::Window parent_xwindow,
|
||||
const gfx::Rect& bounds,
|
||||
const std::string& title);
|
||||
@@ -69,7 +69,7 @@ class CefWindowX11 : public ui::PlatformEventDispatcher,
|
||||
bool IsTargetedBy(const x11::Event& x11_event) const;
|
||||
void ProcessXEvent(x11::Event* xev);
|
||||
|
||||
CefRefPtr<CefBrowserHostImpl> browser_;
|
||||
CefRefPtr<AlloyBrowserHostImpl> browser_;
|
||||
|
||||
// The display and the native X window hosting the root window.
|
||||
::Display* xdisplay_;
|
||||
|
Reference in New Issue
Block a user