mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Windows: Switch to aura/views architecture for content window creation (issue #180).
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1542 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
Index: common.gypi
|
||||
===================================================================
|
||||
--- common.gypi (revision 102269)
|
||||
--- common.gypi (revision 237081)
|
||||
+++ common.gypi (working copy)
|
||||
@@ -9,6 +9,9 @@
|
||||
# Variables expected to be overriden on the GYP command line (-D) or by
|
||||
@ -12,9 +12,18 @@ Index: common.gypi
|
||||
# Putting a variables dict inside another variables dict looks kind of
|
||||
# weird. This is done so that 'host_arch', 'chromeos', etc are defined as
|
||||
# variables within the outer variables dict here. This is necessary
|
||||
@@ -186,7 +189,7 @@
|
||||
'enable_app_list%': 0,
|
||||
}],
|
||||
|
||||
- ['use_aura==1 or (OS!="win" and OS!="mac" and OS!="ios" and OS!="android")', {
|
||||
+ ['OS!="win" and OS!="mac" and OS!="ios" and OS!="android"', {
|
||||
'use_default_render_theme%': 1,
|
||||
}, {
|
||||
'use_default_render_theme%': 0,
|
||||
Index: mac/strip_save_dsym
|
||||
===================================================================
|
||||
--- mac/strip_save_dsym (revision 102269)
|
||||
--- mac/strip_save_dsym (revision 237081)
|
||||
+++ mac/strip_save_dsym (working copy)
|
||||
@@ -48,7 +48,7 @@
|
||||
"bundle"]
|
||||
|
34
patch/patches/native_theme_180.patch
Normal file
34
patch/patches/native_theme_180.patch
Normal file
@ -0,0 +1,34 @@
|
||||
Index: native_theme_aura.cc
|
||||
===================================================================
|
||||
--- native_theme_aura.cc (revision 237081)
|
||||
+++ native_theme_aura.cc (working copy)
|
||||
@@ -17,10 +17,12 @@
|
||||
|
||||
namespace ui {
|
||||
|
||||
+#if !defined(OS_WIN)
|
||||
// static
|
||||
NativeTheme* NativeTheme::instance() {
|
||||
return NativeThemeAura::instance();
|
||||
}
|
||||
+#endif
|
||||
|
||||
// static
|
||||
NativeThemeAura* NativeThemeAura::instance() {
|
||||
Index: native_theme_win.cc
|
||||
===================================================================
|
||||
--- native_theme_win.cc (revision 237081)
|
||||
+++ native_theme_win.cc (working copy)
|
||||
@@ -211,12 +211,10 @@
|
||||
// TODO(sky): seems like we should default to NativeThemeWin, but that currently
|
||||
// breaks a couple of tests (FocusTraversalTest.NormalTraversal in
|
||||
// views_unittests).
|
||||
-#if !defined(USE_AURA)
|
||||
// static
|
||||
NativeTheme* NativeTheme::instance() {
|
||||
return NativeThemeWin::instance();
|
||||
}
|
||||
-#endif
|
||||
|
||||
// static
|
||||
NativeThemeWin* NativeThemeWin::instance() {
|
40
patch/patches/views_widget_180.patch
Normal file
40
patch/patches/views_widget_180.patch
Normal file
@ -0,0 +1,40 @@
|
||||
Index: desktop_aura/desktop_root_window_host_win.cc
|
||||
===================================================================
|
||||
--- desktop_aura/desktop_root_window_host_win.cc (revision 237081)
|
||||
+++ desktop_aura/desktop_root_window_host_win.cc (working copy)
|
||||
@@ -131,7 +131,9 @@
|
||||
native_widget_delegate_);
|
||||
|
||||
HWND parent_hwnd = NULL;
|
||||
- if (params.parent && params.parent->GetDispatcher()) {
|
||||
+ if (params.parent_widget) {
|
||||
+ parent_hwnd = params.parent_widget;
|
||||
+ } else if (params.parent && params.parent->GetDispatcher()) {
|
||||
parent_hwnd =
|
||||
params.parent->GetDispatcher()->host()->GetAcceleratedWidget();
|
||||
}
|
||||
Index: desktop_aura/desktop_screen_win.cc
|
||||
===================================================================
|
||||
--- desktop_aura/desktop_screen_win.cc (revision 237081)
|
||||
+++ desktop_aura/desktop_screen_win.cc (working copy)
|
||||
@@ -54,6 +54,8 @@
|
||||
}
|
||||
|
||||
HWND DesktopScreenWin::GetHWNDFromNativeView(gfx::NativeView window) const {
|
||||
+ if (!window)
|
||||
+ return NULL;
|
||||
aura::WindowEventDispatcher* dispatcher = window->GetDispatcher();
|
||||
return dispatcher ? dispatcher->host()->GetAcceleratedWidget() : NULL;
|
||||
}
|
||||
Index: widget.h
|
||||
===================================================================
|
||||
--- widget.h (revision 237081)
|
||||
+++ widget.h (working copy)
|
||||
@@ -201,6 +201,7 @@
|
||||
// Should the widget be double buffered? Default is false.
|
||||
bool double_buffer;
|
||||
gfx::NativeView parent;
|
||||
+ gfx::AcceleratedWidget parent_widget;
|
||||
// Specifies the initial bounds of the Widget. Default is empty, which means
|
||||
// the NativeWidget may specify a default size. If the parent is specified,
|
||||
// |bounds| is in the parent's coordinate system. If the parent is not
|
Reference in New Issue
Block a user