Remove web_contents from NativeWindow's constructor
This commit is contained in:
parent
6fc819dae1
commit
97e8800677
7 changed files with 10 additions and 11 deletions
|
@ -12,17 +12,14 @@
|
||||||
#include "atom/browser/window_list.h"
|
#include "atom/browser/window_list.h"
|
||||||
#include "atom/common/color_util.h"
|
#include "atom/common/color_util.h"
|
||||||
#include "atom/common/options_switches.h"
|
#include "atom/common/options_switches.h"
|
||||||
#include "brightray/browser/inspectable_web_contents.h"
|
|
||||||
#include "native_mate/dictionary.h"
|
#include "native_mate/dictionary.h"
|
||||||
|
|
||||||
DEFINE_WEB_CONTENTS_USER_DATA_KEY(atom::NativeWindowRelay);
|
DEFINE_WEB_CONTENTS_USER_DATA_KEY(atom::NativeWindowRelay);
|
||||||
|
|
||||||
namespace atom {
|
namespace atom {
|
||||||
|
|
||||||
NativeWindow::NativeWindow(
|
NativeWindow::NativeWindow(const mate::Dictionary& options,
|
||||||
brightray::InspectableWebContents* inspectable_web_contents,
|
NativeWindow* parent)
|
||||||
const mate::Dictionary& options,
|
|
||||||
NativeWindow* parent)
|
|
||||||
: has_frame_(true),
|
: has_frame_(true),
|
||||||
transparent_(false),
|
transparent_(false),
|
||||||
enable_larger_than_screen_(false),
|
enable_larger_than_screen_(false),
|
||||||
|
|
|
@ -11,13 +11,11 @@
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "atom/browser/native_window_observer.h"
|
#include "atom/browser/native_window_observer.h"
|
||||||
#include "atom/browser/ui/atom_menu_model.h"
|
|
||||||
#include "base/memory/weak_ptr.h"
|
#include "base/memory/weak_ptr.h"
|
||||||
#include "base/observer_list.h"
|
#include "base/observer_list.h"
|
||||||
#include "base/supports_user_data.h"
|
#include "base/supports_user_data.h"
|
||||||
#include "content/public/browser/web_contents_user_data.h"
|
#include "content/public/browser/web_contents_user_data.h"
|
||||||
#include "extensions/browser/app_window/size_constraints.h"
|
#include "extensions/browser/app_window/size_constraints.h"
|
||||||
#include "native_mate/persistent_dictionary.h"
|
|
||||||
|
|
||||||
class SkRegion;
|
class SkRegion;
|
||||||
|
|
||||||
|
@ -39,10 +37,12 @@ class Size;
|
||||||
|
|
||||||
namespace mate {
|
namespace mate {
|
||||||
class Dictionary;
|
class Dictionary;
|
||||||
|
class PersistentDictionary;
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace atom {
|
namespace atom {
|
||||||
|
|
||||||
|
class AtomMenuModel;
|
||||||
class NativeBrowserView;
|
class NativeBrowserView;
|
||||||
|
|
||||||
struct DraggableRegion;
|
struct DraggableRegion;
|
||||||
|
@ -272,8 +272,7 @@ class NativeWindow : public base::SupportsUserData {
|
||||||
bool is_modal() const { return is_modal_; }
|
bool is_modal() const { return is_modal_; }
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
NativeWindow(brightray::InspectableWebContents* inspectable_web_contents,
|
NativeWindow(const mate::Dictionary& options,
|
||||||
const mate::Dictionary& options,
|
|
||||||
NativeWindow* parent);
|
NativeWindow* parent);
|
||||||
|
|
||||||
void set_browser_view(NativeBrowserView* browser_view) {
|
void set_browser_view(NativeBrowserView* browser_view) {
|
||||||
|
|
|
@ -780,7 +780,7 @@ NativeWindowMac::NativeWindowMac(
|
||||||
brightray::InspectableWebContents* web_contents,
|
brightray::InspectableWebContents* web_contents,
|
||||||
const mate::Dictionary& options,
|
const mate::Dictionary& options,
|
||||||
NativeWindow* parent)
|
NativeWindow* parent)
|
||||||
: NativeWindow(web_contents, options, parent),
|
: NativeWindow(options, parent),
|
||||||
is_kiosk_(false),
|
is_kiosk_(false),
|
||||||
was_fullscreen_(false),
|
was_fullscreen_(false),
|
||||||
zoom_to_page_width_(false),
|
zoom_to_page_width_(false),
|
||||||
|
|
|
@ -122,7 +122,7 @@ NativeWindowViews::NativeWindowViews(
|
||||||
brightray::InspectableWebContents* web_contents,
|
brightray::InspectableWebContents* web_contents,
|
||||||
const mate::Dictionary& options,
|
const mate::Dictionary& options,
|
||||||
NativeWindow* parent)
|
NativeWindow* parent)
|
||||||
: NativeWindow(web_contents, options, parent),
|
: NativeWindow(options, parent),
|
||||||
window_(new views::Widget),
|
window_(new views::Widget),
|
||||||
web_view_(web_contents->GetView()->GetView()),
|
web_view_(web_contents->GetView()->GetView()),
|
||||||
focused_view_(web_contents->GetView()->GetWebView()),
|
focused_view_(web_contents->GetView()->GetWebView()),
|
||||||
|
|
|
@ -16,6 +16,7 @@
|
||||||
#include "chrome/browser/ui/libgtkui/gtk_signal.h"
|
#include "chrome/browser/ui/libgtkui/gtk_signal.h"
|
||||||
#include "chrome/browser/ui/libgtkui/gtk_util.h"
|
#include "chrome/browser/ui/libgtkui/gtk_util.h"
|
||||||
#include "chrome/browser/ui/libgtkui/skia_utils_gtk.h"
|
#include "chrome/browser/ui/libgtkui/skia_utils_gtk.h"
|
||||||
|
#include "ui/gfx/image/image_skia.h"
|
||||||
#include "ui/views/widget/desktop_aura/x11_desktop_handler.h"
|
#include "ui/views/widget/desktop_aura/x11_desktop_handler.h"
|
||||||
|
|
||||||
#define ANSI_FOREGROUND_RED "\x1b[31m"
|
#define ANSI_FOREGROUND_RED "\x1b[31m"
|
||||||
|
|
|
@ -11,6 +11,7 @@
|
||||||
#include "base/mac/mac_util.h"
|
#include "base/mac/mac_util.h"
|
||||||
#include "base/strings/sys_string_conversions.h"
|
#include "base/strings/sys_string_conversions.h"
|
||||||
#include "skia/ext/skia_utils_mac.h"
|
#include "skia/ext/skia_utils_mac.h"
|
||||||
|
#include "ui/gfx/image/image_skia.h"
|
||||||
|
|
||||||
@interface ModalDelegate : NSObject {
|
@interface ModalDelegate : NSObject {
|
||||||
@private
|
@private
|
||||||
|
|
|
@ -21,6 +21,7 @@
|
||||||
#include "base/win/scoped_gdi_object.h"
|
#include "base/win/scoped_gdi_object.h"
|
||||||
#include "content/public/browser/browser_thread.h"
|
#include "content/public/browser/browser_thread.h"
|
||||||
#include "ui/gfx/icon_util.h"
|
#include "ui/gfx/icon_util.h"
|
||||||
|
#include "ui/gfx/image/image_skia.h"
|
||||||
|
|
||||||
namespace atom {
|
namespace atom {
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue