Update to Chromium revision 14bd12d6 (#333041)

- Remove CefNavigationEntry::GetFrameName() (see http://crbug.com/477150#c5).
- Devirtualize base::BindState (see http://crbug.com/486594).
- Move Tuple to the base namespace.
This commit is contained in:
Marshall Greenblatt
2015-06-05 18:06:48 -04:00
parent d820080479
commit 378a64b39a
77 changed files with 523 additions and 549 deletions

View File

@@ -1,10 +1,10 @@
diff --git web_contents_impl.cc web_contents_impl.cc
index 3ce4b68..465b5e1 100644
index 4ab69e9..7c119d1 100644
--- web_contents_impl.cc
+++ web_contents_impl.cc
@@ -1205,22 +1205,29 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) {
params.browser_context, params.site_instance, params.routing_id,
@@ -1232,22 +1232,29 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) {
params.main_frame_routing_id);
frame_tree_.root()->SetFrameName(params.main_frame_name);
- WebContentsViewDelegate* delegate =
- GetContentClient()->browser()->GetWebContentsViewDelegate(this);
@@ -48,7 +48,7 @@ index 3ce4b68..465b5e1 100644
}
CHECK(render_view_host_delegate_view_);
CHECK(view_.get());
@@ -1556,6 +1563,9 @@ void WebContentsImpl::CreateNewWindow(
@@ -1583,6 +1590,9 @@ void WebContentsImpl::CreateNewWindow(
static_cast<SessionStorageNamespaceImpl*>(session_storage_namespace);
CHECK(session_storage_namespace_impl->IsFromContext(dom_storage_context));
@@ -58,7 +58,7 @@ index 3ce4b68..465b5e1 100644
if (delegate_ &&
!delegate_->ShouldCreateWebContents(this,
route_id,
@@ -1564,7 +1574,9 @@ void WebContentsImpl::CreateNewWindow(
@@ -1591,7 +1601,9 @@ void WebContentsImpl::CreateNewWindow(
params.frame_name,
params.target_url,
partition_id,
@@ -69,8 +69,8 @@ index 3ce4b68..465b5e1 100644
if (route_id != MSG_ROUTING_NONE &&
!RenderViewHost::FromID(render_process_id, route_id)) {
// If the embedder didn't create a WebContents for this route, we need to
@@ -1584,6 +1596,8 @@ void WebContentsImpl::CreateNewWindow(
create_params.main_frame_routing_id = main_frame_route_id;
@@ -1612,6 +1624,8 @@ void WebContentsImpl::CreateNewWindow(
create_params.main_frame_name = base::UTF16ToUTF8(params.frame_name);
create_params.opener = this;
create_params.opener_suppressed = params.opener_suppressed;
+ create_params.view = view;

View File

@@ -1,5 +1,5 @@
diff --git common.gypi common.gypi
index 7c3074b..53e5f64 100644
index cfa4352..b701fcc 100644
--- common.gypi
+++ common.gypi
@@ -9,6 +9,9 @@

View File

@@ -1,8 +1,8 @@
diff --git ui/browser.cc ui/browser.cc
index 8ba7764..16e15da 100644
index 1cc78f2..e2c4de0 100644
--- ui/browser.cc
+++ ui/browser.cc
@@ -1596,7 +1596,9 @@ bool Browser::ShouldCreateWebContents(
@@ -1606,7 +1606,9 @@ bool Browser::ShouldCreateWebContents(
const base::string16& frame_name,
const GURL& target_url,
const std::string& partition_id,
@@ -14,7 +14,7 @@ index 8ba7764..16e15da 100644
// If a BackgroundContents is created, suppress the normal WebContents.
return !MaybeCreateBackgroundContents(route_id,
diff --git ui/browser.h ui/browser.h
index f5d2c62..d8af427 100644
index c4a3a62..0cfedfa 100644
--- ui/browser.h
+++ ui/browser.h
@@ -590,7 +590,9 @@ class Browser : public TabStripModelObserver,

View File

@@ -1,10 +1,10 @@
diff --git content/browser/compositor/gpu_process_transport_factory.cc content/browser/compositor/gpu_process_transport_factory.cc
index f2d1b39..faf1f48 100644
index 68ee72c..6c8e8eb7 100644
--- content/browser/compositor/gpu_process_transport_factory.cc
+++ content/browser/compositor/gpu_process_transport_factory.cc
@@ -131,6 +131,13 @@ GpuProcessTransportFactory::CreateOffscreenCommandBufferContext() {
scoped_ptr<cc::SoftwareOutputDevice> CreateSoftwareOutputDevice(
@@ -141,6 +141,13 @@ GpuProcessTransportFactory::CreateOffscreenCommandBufferContext() {
scoped_ptr<cc::SoftwareOutputDevice>
GpuProcessTransportFactory::CreateSoftwareOutputDevice(
ui::Compositor* compositor) {
+ if (compositor->delegate()) {
+ scoped_ptr<cc::SoftwareOutputDevice> output_device =
@@ -14,10 +14,10 @@ index f2d1b39..faf1f48 100644
+ }
+
#if defined(OS_WIN)
return scoped_ptr<cc::SoftwareOutputDevice>(new SoftwareOutputDeviceWin(
compositor));
return scoped_ptr<cc::SoftwareOutputDevice>(
new SoftwareOutputDeviceWin(software_backing_.get(), compositor));
diff --git ui/compositor/compositor.h ui/compositor/compositor.h
index cf115b0..cddbaa0 100644
index e82c49d..97b438bf 100644
--- ui/compositor/compositor.h
+++ ui/compositor/compositor.h
@@ -15,6 +15,7 @@
@@ -28,7 +28,7 @@ index cf115b0..cddbaa0 100644
#include "cc/surfaces/surface_sequence.h"
#include "cc/trees/layer_tree_host_client.h"
#include "cc/trees/layer_tree_host_single_thread_client.h"
@@ -147,6 +148,17 @@ class COMPOSITOR_EXPORT CompositorBeginFrameObserver {
@@ -149,6 +150,17 @@ class COMPOSITOR_EXPORT CompositorBeginFrameObserver {
virtual void OnSendBeginFrame(const cc::BeginFrameArgs& args) = 0;
};
@@ -46,7 +46,7 @@ index cf115b0..cddbaa0 100644
// Compositor object to take care of GPU painting.
// A Browser compositor object is responsible for generating the final
// displayable form of pixels comprising a single widget's contents. It draws an
@@ -168,6 +180,9 @@ class COMPOSITOR_EXPORT Compositor
@@ -170,6 +182,9 @@ class COMPOSITOR_EXPORT Compositor
// Schedules a redraw of the layer tree associated with this compositor.
void ScheduleDraw();
@@ -56,7 +56,7 @@ index cf115b0..cddbaa0 100644
// Sets the root of the layer tree drawn by this Compositor. The root layer
// must have no parent. The compositor's root layer is reset if the root layer
// is destroyed. NULL can be passed to reset the root layer, in which case the
@@ -324,6 +339,8 @@ class COMPOSITOR_EXPORT Compositor
@@ -331,6 +346,8 @@ class COMPOSITOR_EXPORT Compositor
ui::ContextFactory* context_factory_;

View File

@@ -1,8 +1,8 @@
diff --git public/renderer/content_renderer_client.cc public/renderer/content_renderer_client.cc
index 6e66fe3..32957fc 100644
index 524a6cd..29aac98 100644
--- public/renderer/content_renderer_client.cc
+++ public/renderer/content_renderer_client.cc
@@ -99,7 +99,6 @@ bool ContentRendererClient::AllowPopup() {
@@ -101,7 +101,6 @@ bool ContentRendererClient::AllowPopup() {
return false;
}
@@ -10,7 +10,7 @@ index 6e66fe3..32957fc 100644
bool ContentRendererClient::HandleNavigation(
RenderFrame* render_frame,
DocumentState* document_state,
@@ -111,7 +110,6 @@ bool ContentRendererClient::HandleNavigation(
@@ -113,7 +112,6 @@ bool ContentRendererClient::HandleNavigation(
bool is_redirect) {
return false;
}
@@ -19,10 +19,10 @@ index 6e66fe3..32957fc 100644
bool ContentRendererClient::ShouldFork(blink::WebFrame* frame,
const GURL& url,
diff --git public/renderer/content_renderer_client.h public/renderer/content_renderer_client.h
index e4e8f03..f4392d9 100644
index 8c7d4fe..b88a6c9 100644
--- public/renderer/content_renderer_client.h
+++ public/renderer/content_renderer_client.h
@@ -193,7 +193,6 @@ class CONTENT_EXPORT ContentRendererClient {
@@ -197,7 +197,6 @@ class CONTENT_EXPORT ContentRendererClient {
// Returns true if a popup window should be allowed.
virtual bool AllowPopup();
@@ -30,7 +30,7 @@ index e4e8f03..f4392d9 100644
// TODO(sgurun) This callback is deprecated and will be removed as soon
// as android webview completes implementation of a resource throttle based
// shouldoverrideurl implementation. See crbug.com/325351
@@ -208,7 +207,6 @@ class CONTENT_EXPORT ContentRendererClient {
@@ -212,7 +211,6 @@ class CONTENT_EXPORT ContentRendererClient {
blink::WebNavigationType type,
blink::WebNavigationPolicy default_policy,
bool is_redirect);
@@ -39,10 +39,10 @@ index e4e8f03..f4392d9 100644
// Returns true if we should fork a new process for the given navigation.
// If |send_referrer| is set to false (which is the default), no referrer
diff --git renderer/render_frame_impl.cc renderer/render_frame_impl.cc
index 3cf9e9b..21cebc8 100644
index f67a40a..4b5b3f2 100644
--- renderer/render_frame_impl.cc
+++ renderer/render_frame_impl.cc
@@ -4186,7 +4186,6 @@ void RenderFrameImpl::OnFailedNavigation(
@@ -4088,7 +4088,6 @@ void RenderFrameImpl::OnFailedNavigation(
WebNavigationPolicy RenderFrameImpl::DecidePolicyForNavigation(
RenderFrame* render_frame,
const NavigationPolicyInfo& info) {
@@ -50,7 +50,7 @@ index 3cf9e9b..21cebc8 100644
// The handlenavigation API is deprecated and will be removed once
// crbug.com/325351 is resolved.
if (info.urlRequest.url() != GURL(kSwappedOutURL) &&
@@ -4201,7 +4200,6 @@ WebNavigationPolicy RenderFrameImpl::DecidePolicyForNavigation(
@@ -4103,7 +4102,6 @@ WebNavigationPolicy RenderFrameImpl::DecidePolicyForNavigation(
info.isRedirect)) {
return blink::WebNavigationPolicyIgnore;
}

View File

@@ -1,5 +1,5 @@
diff --git resource_ids resource_ids
index d56ba05..e754058 100644
index 20fc28b..85f1566 100644
--- resource_ids
+++ resource_ids
@@ -14,6 +14,12 @@

View File

@@ -1,15 +1,15 @@
diff --git input_method_win.cc input_method_win.cc
index 6961683..1f8c4b2 100644
index 29413f5..e1e2bd0 100644
--- input_method_win.cc
+++ input_method_win.cc
@@ -601,7 +601,9 @@ bool InputMethodWin::IsWindowFocused(const TextInputClient* client) const {
@@ -571,8 +571,9 @@ bool InputMethodWin::IsWindowFocused(const TextInputClient* client) const {
// receiving keyboard input as long as it is an active window. This works well
// even when the |attached_window_handle| becomes active but has not received
// WM_FOCUS yet.
- return attached_window_handle && GetActiveWindow() == attached_window_handle;
+ // With CEF |attached_window_handle| may be a child window.
+ return attached_window_handle &&
+ GetActiveWindow() == ::GetAncestor(attached_window_handle, GA_ROOT);
+ // With CEF |toplevel_window_handle_| may be a child window.
return toplevel_window_handle_ &&
- GetActiveWindow() == toplevel_window_handle_;
+ GetActiveWindow() == ::GetAncestor(toplevel_window_handle_, GA_ROOT);
}
bool InputMethodWin::DispatchFabricatedKeyEvent(const ui::KeyEvent& event) {

View File

@@ -1,10 +1,10 @@
diff --git message_loop.cc message_loop.cc
index eb0f968..1852eb1 100644
index 4222c77..bbc04b4 100644
--- message_loop.cc
+++ message_loop.cc
@@ -152,12 +152,6 @@ MessageLoop::MessageLoop(scoped_ptr<MessagePump> pump)
MessageLoop::~MessageLoop() {
DCHECK_EQ(this, current());
@@ -134,12 +134,6 @@ MessageLoop::~MessageLoop() {
// bound to a thread.
DCHECK(current() == this || !current());
- // iOS just attaches to the loop, it doesn't Run it.
- // TODO(stuartmorgan): Consider wiring up a Detach().

View File

@@ -1,10 +1,10 @@
diff --git url_request.h url_request.h
index e623c20..c6c9058 100644
index a2b2f6b..150f19f 100644
--- url_request.h
+++ url_request.h
@@ -608,10 +608,10 @@ class NET_EXPORT URLRequest : NON_EXPORTED_BASE(public base::NonThreadSafe),
return proxy_server_;
}
@@ -614,10 +614,10 @@ class NET_EXPORT URLRequest : NON_EXPORTED_BASE(public base::NonThreadSafe),
// or after the response headers are received.
void GetConnectionAttempts(ConnectionAttempts* out) const;
- protected:
// Allow the URLRequestJob class to control the is_pending() flag.

View File

@@ -1,8 +1,8 @@
diff --git public/common/common_param_traits_macros.h public/common/common_param_traits_macros.h
index 53f1128..46bbcf8 100644
index 9c8e453..03f5d51 100644
--- public/common/common_param_traits_macros.h
+++ public/common/common_param_traits_macros.h
@@ -194,6 +194,7 @@ IPC_STRUCT_TRAITS_BEGIN(content::WebPreferences)
@@ -192,6 +192,7 @@ IPC_STRUCT_TRAITS_BEGIN(content::WebPreferences)
IPC_STRUCT_TRAITS_MEMBER(main_frame_resizes_are_orientation_changes)
IPC_STRUCT_TRAITS_MEMBER(initialize_at_minimum_page_scale)
IPC_STRUCT_TRAITS_MEMBER(smart_insert_delete_enabled)
@@ -11,10 +11,10 @@ index 53f1128..46bbcf8 100644
IPC_STRUCT_TRAITS_MEMBER(navigate_on_drag_drop)
IPC_STRUCT_TRAITS_MEMBER(spatial_navigation_enabled)
diff --git public/common/web_preferences.cc public/common/web_preferences.cc
index b61e1dc..5b55207 100644
index 6279aba..242fd16 100644
--- public/common/web_preferences.cc
+++ public/common/web_preferences.cc
@@ -189,6 +189,7 @@ WebPreferences::WebPreferences()
@@ -187,6 +187,7 @@ WebPreferences::WebPreferences()
pinch_overlay_scrollbar_thickness(0),
use_solid_color_scrollbars(false),
navigate_on_drag_drop(true),
@@ -23,10 +23,10 @@ index b61e1dc..5b55207 100644
slimming_paint_enabled(false),
cookie_enabled(true),
diff --git public/common/web_preferences.h public/common/web_preferences.h
index 8d25487..23b25ae 100644
index 5dfc5d5..150bdf5 100644
--- public/common/web_preferences.h
+++ public/common/web_preferences.h
@@ -181,6 +181,7 @@ struct CONTENT_EXPORT WebPreferences {
@@ -179,6 +179,7 @@ struct CONTENT_EXPORT WebPreferences {
int pinch_overlay_scrollbar_thickness;
bool use_solid_color_scrollbars;
bool navigate_on_drag_drop;
@@ -35,10 +35,10 @@ index 8d25487..23b25ae 100644
bool slimming_paint_enabled;
diff --git renderer/render_view_impl.cc renderer/render_view_impl.cc
index 66d2c0d..1502e0a 100644
index 53ba225..d5ebdd8 100644
--- renderer/render_view_impl.cc
+++ renderer/render_view_impl.cc
@@ -950,6 +950,8 @@ void RenderView::ApplyWebPreferences(const WebPreferences& prefs,
@@ -945,6 +945,8 @@ void RenderView::ApplyWebPreferences(const WebPreferences& prefs,
settings->setJavaEnabled(prefs.java_enabled);

View File

@@ -1,8 +1,8 @@
diff --git printing/renderer/print_web_view_helper.cc printing/renderer/print_web_view_helper.cc
index cef7a95..f05255a 100644
index 313d12d..558052c 100644
--- printing/renderer/print_web_view_helper.cc
+++ printing/renderer/print_web_view_helper.cc
@@ -73,6 +73,7 @@ const double kMinDpi = 1.0;
@@ -75,6 +75,7 @@ const double kMinDpi = 1.0;
bool g_is_preview_enabled_ = false;
#else
bool g_is_preview_enabled_ = true;
@@ -10,7 +10,7 @@ index cef7a95..f05255a 100644
const char kPageLoadScriptFormat[] =
"document.open(); document.write(%s); document.close();";
@@ -87,7 +88,6 @@ void ExecuteScript(blink::WebFrame* frame,
@@ -89,7 +90,6 @@ void ExecuteScript(blink::WebFrame* frame,
std::string script = base::StringPrintf(script_format, json.c_str());
frame->executeScript(blink::WebString(base::UTF8ToUTF16(script)));
}
@@ -18,7 +18,7 @@ index cef7a95..f05255a 100644
int GetDPI(const PrintMsg_Print_Params* print_params) {
#if defined(OS_MACOSX)
@@ -484,7 +484,6 @@ blink::WebView* FrameReference::view() {
@@ -474,7 +474,6 @@ blink::WebView* FrameReference::view() {
return view_;
}
@@ -26,7 +26,7 @@ index cef7a95..f05255a 100644
// static - Not anonymous so that platform implementations can use it.
void PrintWebViewHelper::PrintHeaderAndFooter(
blink::WebCanvas* canvas,
@@ -541,7 +540,6 @@ void PrintWebViewHelper::PrintHeaderAndFooter(
@@ -532,7 +531,6 @@ void PrintWebViewHelper::PrintHeaderAndFooter(
web_view->close();
frame->close();
}
@@ -35,10 +35,10 @@ index cef7a95..f05255a 100644
// static - Not anonymous so that platform implementations can use it.
float PrintWebViewHelper::RenderPageContent(blink::WebFrame* frame,
diff --git printing/renderer/print_web_view_helper.h printing/renderer/print_web_view_helper.h
index d040dbc..72dd76e 100644
index 341ec8e..47777b8 100644
--- printing/renderer/print_web_view_helper.h
+++ printing/renderer/print_web_view_helper.h
@@ -305,7 +305,6 @@ class PrintWebViewHelper
@@ -309,7 +309,6 @@ class PrintWebViewHelper
double* scale_factor,
PageSizeMargins* page_layout_in_points);
@@ -46,7 +46,7 @@ index d040dbc..72dd76e 100644
// Given the |device| and |canvas| to draw on, prints the appropriate headers
// and footers using strings from |header_footer_info| on to the canvas.
static void PrintHeaderAndFooter(blink::WebCanvas* canvas,
@@ -315,7 +314,6 @@ class PrintWebViewHelper
@@ -319,7 +318,6 @@ class PrintWebViewHelper
float webkit_scale_factor,
const PageSizeMargins& page_layout_in_points,
const PrintMsg_Print_Params& params);

View File

@@ -1,8 +1,8 @@
diff --git web_contents.cc web_contents.cc
index aece7c6..63da2c9 100644
index a0c8a4d..1c102ae 100644
--- web_contents.cc
+++ web_contents.cc
@@ -18,7 +18,9 @@ WebContents::CreateParams::CreateParams(BrowserContext* context)
@@ -19,7 +19,9 @@ WebContents::CreateParams::CreateParams(BrowserContext* context)
initially_hidden(false),
guest_delegate(nullptr),
context(nullptr),
@@ -13,7 +13,7 @@ index aece7c6..63da2c9 100644
WebContents::CreateParams::CreateParams(
BrowserContext* context, SiteInstance* site)
@@ -31,7 +33,9 @@ WebContents::CreateParams::CreateParams(
@@ -33,7 +35,9 @@ WebContents::CreateParams::CreateParams(
initially_hidden(false),
guest_delegate(nullptr),
context(nullptr),
@@ -25,7 +25,7 @@ index aece7c6..63da2c9 100644
WebContents::CreateParams::~CreateParams() {
}
diff --git web_contents.h web_contents.h
index 4380412..a67739d 100644
index 768ece2..9c2d863 100644
--- web_contents.h
+++ web_contents.h
@@ -52,9 +52,11 @@ class PageState;
@@ -40,7 +40,7 @@ index 4380412..a67739d 100644
struct CustomContextMenuContext;
struct DropData;
struct Manifest;
@@ -128,6 +130,10 @@ class WebContents : public PageNavigator,
@@ -139,6 +141,10 @@ class WebContents : public PageNavigator,
// RenderFrame, have already been created on the renderer side, and
// WebContents construction should take this into account.
bool renderer_initiated_creation;
@@ -52,10 +52,10 @@ index 4380412..a67739d 100644
// Creates a new WebContents.
diff --git web_contents_delegate.cc web_contents_delegate.cc
index d4028fb..285f0c3 100644
index b1fc250..555e25d 100644
--- web_contents_delegate.cc
+++ web_contents_delegate.cc
@@ -133,7 +133,9 @@ bool WebContentsDelegate::ShouldCreateWebContents(
@@ -136,7 +136,9 @@ bool WebContentsDelegate::ShouldCreateWebContents(
const base::string16& frame_name,
const GURL& target_url,
const std::string& partition_id,
@@ -67,7 +67,7 @@ index d4028fb..285f0c3 100644
}
diff --git web_contents_delegate.h web_contents_delegate.h
index ef73451..17374f1 100644
index 66439df..c8779c9 100644
--- web_contents_delegate.h
+++ web_contents_delegate.h
@@ -37,9 +37,11 @@ class DownloadItem;
@@ -82,7 +82,7 @@ index ef73451..17374f1 100644
struct ColorSuggestion;
struct ContextMenuParams;
struct DropData;
@@ -292,7 +294,9 @@ class CONTENT_EXPORT WebContentsDelegate {
@@ -296,7 +298,9 @@ class CONTENT_EXPORT WebContentsDelegate {
const base::string16& frame_name,
const GURL& target_url,
const std::string& partition_id,

View File

@@ -1,8 +1,8 @@
diff --git render_process_host_impl.cc render_process_host_impl.cc
index 1e20d8e..6c0f5f4 100644
index f32d2bb..9874d50 100644
--- render_process_host_impl.cc
+++ render_process_host_impl.cc
@@ -2111,6 +2111,8 @@ void RenderProcessHostImpl::ProcessDied(bool already_dead,
@@ -2120,6 +2120,8 @@ void RenderProcessHostImpl::ProcessDied(bool already_dead,
#endif
RemoveUserData(kSessionStorageHolderKey);
@@ -11,7 +11,7 @@ index 1e20d8e..6c0f5f4 100644
IDMap<IPC::Listener>::iterator iter(&listeners_);
while (!iter.IsAtEnd()) {
iter.GetCurrentValue()->OnMessageReceived(
@@ -2120,8 +2122,6 @@ void RenderProcessHostImpl::ProcessDied(bool already_dead,
@@ -2129,8 +2131,6 @@ void RenderProcessHostImpl::ProcessDied(bool already_dead,
iter.Advance();
}

View File

@@ -1,5 +1,5 @@
diff --git spellcheck_factory.cc spellcheck_factory.cc
index bd4ac1f..ce1d28e 100644
index edbed40..b9a192b 100644
--- spellcheck_factory.cc
+++ spellcheck_factory.cc
@@ -16,6 +16,13 @@

View File

@@ -1,5 +1,5 @@
diff --git os_exchange_data_provider_aurax11.cc os_exchange_data_provider_aurax11.cc
index 714069f..56c7fa5 100644
index c9285a0..f82f90a 100644
--- os_exchange_data_provider_aurax11.cc
+++ os_exchange_data_provider_aurax11.cc
@@ -158,7 +158,8 @@ void OSExchangeDataProviderAuraX11::SetURL(const GURL& url,

View File

@@ -12,10 +12,10 @@ index a8e088c..838b6a0 100644
return host ? host->GetAcceleratedWidget() : NULL;
}
diff --git desktop_aura/desktop_window_tree_host_win.cc desktop_aura/desktop_window_tree_host_win.cc
index b53fc7f..0b24d2a 100644
index a663f38..a3dacca 100644
--- desktop_aura/desktop_window_tree_host_win.cc
+++ desktop_aura/desktop_window_tree_host_win.cc
@@ -134,7 +134,9 @@ void DesktopWindowTreeHostWin::Init(aura::Window* content_window,
@@ -132,7 +132,9 @@ void DesktopWindowTreeHostWin::Init(aura::Window* content_window,
native_widget_delegate_);
HWND parent_hwnd = NULL;
@@ -26,24 +26,16 @@ index b53fc7f..0b24d2a 100644
parent_hwnd = params.parent->GetHost()->GetAcceleratedWidget();
message_handler_->set_remove_standard_frame(params.remove_standard_frame);
@@ -821,6 +823,7 @@ void DesktopWindowTreeHostWin::HandleFrameChanged() {
@@ -799,6 +801,7 @@ void DesktopWindowTreeHostWin::HandleFrameChanged() {
void DesktopWindowTreeHostWin::HandleNativeFocus(HWND last_focused_window) {
// TODO(beng): inform the native_widget_delegate_.
+ GetWidget()->GetNativeWindow()->Focus();
InputMethod* input_method = GetInputMethod();
if (input_method)
input_method->OnFocus();
@@ -828,6 +831,7 @@ void DesktopWindowTreeHostWin::HandleNativeFocus(HWND last_focused_window) {
}
void DesktopWindowTreeHostWin::HandleNativeBlur(HWND focused_window) {
// TODO(beng): inform the native_widget_delegate_.
+ GetWidget()->GetNativeWindow()->Blur();
InputMethod* input_method = GetInputMethod();
if (input_method)
input_method->OnBlur();
diff --git desktop_aura/desktop_window_tree_host_x11.cc desktop_aura/desktop_window_tree_host_x11.cc
index 125e8f0..275e0d8 100644
index 4a8f64c..369867b 100644
--- desktop_aura/desktop_window_tree_host_x11.cc
+++ desktop_aura/desktop_window_tree_host_x11.cc
@@ -153,7 +153,8 @@ DesktopWindowTreeHostX11::DesktopWindowTreeHostX11(
@@ -66,7 +58,7 @@ index 125e8f0..275e0d8 100644
xwindow_ = None;
desktop_native_widget_aura_->OnHostClosed();
@@ -452,6 +454,8 @@ void DesktopWindowTreeHostX11::GetWindowPlacement(
@@ -466,6 +468,8 @@ void DesktopWindowTreeHostX11::GetWindowPlacement(
}
gfx::Rect DesktopWindowTreeHostX11::GetWindowBoundsInScreen() const {
@@ -75,7 +67,7 @@ index 125e8f0..275e0d8 100644
return ToDIPRect(bounds_in_pixels_);
}
@@ -894,6 +898,8 @@ void DesktopWindowTreeHostX11::Hide() {
@@ -906,6 +910,8 @@ void DesktopWindowTreeHostX11::HideImpl() {
}
gfx::Rect DesktopWindowTreeHostX11::GetBounds() const {
@@ -84,7 +76,7 @@ index 125e8f0..275e0d8 100644
return bounds_in_pixels_;
}
@@ -950,6 +956,8 @@ void DesktopWindowTreeHostX11::SetBounds(
@@ -962,6 +968,8 @@ void DesktopWindowTreeHostX11::SetBounds(
}
gfx::Point DesktopWindowTreeHostX11::GetLocationOnNativeScreen() const {
@@ -93,7 +85,7 @@ index 125e8f0..275e0d8 100644
return bounds_in_pixels_.origin();
}
@@ -1070,9 +1078,13 @@ void DesktopWindowTreeHostX11::InitX11Window(
@@ -1082,9 +1090,13 @@ void DesktopWindowTreeHostX11::InitX11Window(
}
}
@@ -108,7 +100,7 @@ index 125e8f0..275e0d8 100644
bounds_in_pixels_.y(), bounds_in_pixels_.width(),
bounds_in_pixels_.height(),
0, // border width
@@ -1719,6 +1731,10 @@ uint32_t DesktopWindowTreeHostX11::DispatchEvent(
@@ -1731,6 +1743,10 @@ uint32_t DesktopWindowTreeHostX11::DispatchEvent(
}
break;
}
@@ -120,7 +112,7 @@ index 125e8f0..275e0d8 100644
if (xev->xfocus.mode != NotifyGrab) {
ReleaseCapture();
diff --git desktop_aura/desktop_window_tree_host_x11.h desktop_aura/desktop_window_tree_host_x11.h
index 94d4b1b..2609f46 100644
index e2fd61f..46434af 100644
--- desktop_aura/desktop_window_tree_host_x11.h
+++ desktop_aura/desktop_window_tree_host_x11.h
@@ -86,6 +86,8 @@ class VIEWS_EXPORT DesktopWindowTreeHostX11
@@ -153,7 +145,7 @@ index 94d4b1b..2609f46 100644
};
diff --git widget.cc widget.cc
index 64e131e..aec1b43 100644
index b4d2a48..3890ab0 100644
--- widget.cc
+++ widget.cc
@@ -110,6 +110,7 @@ Widget::InitParams::InitParams()
@@ -196,7 +188,7 @@ index 64e131e..aec1b43 100644
// This must come after SetContentsView() or it might not be able to find
// the correct NativeTheme (on Linux). See http://crbug.com/384492
diff --git widget.h widget.h
index 59e7b1d..bf888d7 100644
index 9c21ea2..aa610fd 100644
--- widget.h
+++ widget.h
@@ -234,6 +234,7 @@ class VIEWS_EXPORT Widget : public internal::NativeWidgetDelegate,

View File

@@ -1,8 +1,8 @@
diff --git ThemeMac.mm ThemeMac.mm
index a35aaea..c049569 100644
index 20a4ff0..38cb2c4 100644
--- ThemeMac.mm
+++ ThemeMac.mm
@@ -490,7 +490,7 @@ static void paintButton(ControlPart part, ControlStates states, GraphicsContext*
@@ -482,7 +482,7 @@ static void paintButton(ControlPart part, ControlStates states, GraphicsContext*
[buttonCell drawWithFrame:NSRect(inflatedRect) inView:view];
#if !BUTTON_CELL_DRAW_WITH_FRAME_DRAWS_FOCUS_RING
@@ -12,19 +12,18 @@ index a35aaea..c049569 100644
#endif
[buttonCell setControlView:nil];
diff --git WebCoreNSCellExtras.h WebCoreNSCellExtras.h
index 8623826..b9f683d 100644
index 54e9c9a..075e076 100644
--- WebCoreNSCellExtras.h
+++ WebCoreNSCellExtras.h
@@ -26,12 +26,12 @@
@@ -26,11 +26,11 @@
#import <AppKit/AppKit.h>
#include "platform/PlatformExport.h"
-#define BUTTON_CELL_DRAW_WITH_FRAME_DRAWS_FOCUS_RING (!defined(MAC_OS_X_VERSION_10_7) || MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_7)
-#define BUTTON_CELL_DRAW_WITH_FRAME_DRAWS_FOCUS_RING (!defined(MAC_OS_X_VERSION_10_7) || MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_7)
+#define BUTTON_CELL_DRAW_WITH_FRAME_DRAWS_FOCUS_RING 1
#if !BUTTON_CELL_DRAW_WITH_FRAME_DRAWS_FOCUS_RING
// FIXME: Might want to use this on Mac once we only support OS X 10.8+
-@interface NSCell (WebCoreFocusRingDrawing)
+PLATFORM_EXPORT @interface NSCell (WebCoreFocusRingDrawing)
- (void)_web_drawFocusRingWithFrame:(NSRect)cellFrame inView:(NSView *)controlView;

View File

@@ -1,21 +1,21 @@
diff --git Source/web/ChromeClientImpl.cpp Source/web/ChromeClientImpl.cpp
index b47a0c6..1c59701 100644
index e1fd006..fa9486b 100644
--- Source/web/ChromeClientImpl.cpp
+++ Source/web/ChromeClientImpl.cpp
@@ -754,7 +754,7 @@ bool ChromeClientImpl::hasOpenedPopup() const
PassRefPtrWillBeRawPtr<PopupMenu> ChromeClientImpl::createPopupMenu(LocalFrame& frame, PopupMenuClient* client)
@@ -768,7 +768,7 @@ bool ChromeClientImpl::hasOpenedPopup() const
PassRefPtrWillBeRawPtr<PopupMenu> ChromeClientImpl::openPopupMenu(LocalFrame& frame, PopupMenuClient* client)
{
notifyPopupOpeningObservers();
- if (WebViewImpl::useExternalPopupMenus())
+ if (m_webView->useExternalPopupMenus())
return adoptRefWillBeNoop(new ExternalPopupMenu(frame, client, *m_webView));
if (RuntimeEnabledFeatures::htmlPopupMenuEnabled() && RuntimeEnabledFeatures::pagePopupEnabled())
ASSERT(RuntimeEnabledFeatures::pagePopupEnabled());
diff --git Source/web/WebViewImpl.cpp Source/web/WebViewImpl.cpp
index ee49268..ce794e9 100644
index 9a4161a..cf68085 100644
--- Source/web/WebViewImpl.cpp
+++ Source/web/WebViewImpl.cpp
@@ -394,6 +394,7 @@ WebViewImpl::WebViewImpl(WebViewClient* client)
@@ -397,6 +397,7 @@ WebViewImpl::WebViewImpl(WebViewClient* client)
, m_fakePageScaleAnimationPageScaleFactor(0)
, m_fakePageScaleAnimationUseAnchor(false)
, m_contextMenuAllowed(false)
@@ -23,7 +23,7 @@ index ee49268..ce794e9 100644
, m_doingDragAndDrop(false)
, m_ignoreInputEvents(false)
, m_compositorDeviceScaleFactorOverride(0)
@@ -4006,9 +4007,14 @@ void WebViewImpl::pageScaleFactorChanged()
@@ -3946,9 +3947,14 @@ void WebViewImpl::pageScaleFactorChanged()
m_client->pageScaleFactorChanged();
}
@@ -40,10 +40,10 @@ index ee49268..ce794e9 100644
void WebViewImpl::startDragging(LocalFrame* frame,
diff --git Source/web/WebViewImpl.h Source/web/WebViewImpl.h
index 285d824..765a2dd 100644
index f222ca0..51478ce 100644
--- Source/web/WebViewImpl.h
+++ Source/web/WebViewImpl.h
@@ -391,7 +391,8 @@ public:
@@ -390,7 +390,8 @@ public:
// Returns true if popup menus should be rendered by the browser, false if
// they should be rendered by WebKit (which is the default).
@@ -53,7 +53,7 @@ index 285d824..765a2dd 100644
bool contextMenuAllowed() const
{
@@ -685,6 +686,8 @@ private:
@@ -677,6 +678,8 @@ private:
bool m_contextMenuAllowed;
@@ -63,10 +63,10 @@ index 285d824..765a2dd 100644
bool m_ignoreInputEvents;
diff --git public/web/WebView.h public/web/WebView.h
index be2c85b..1e0057e 100644
index 4046206..fd01e64 100644
--- public/web/WebView.h
+++ public/web/WebView.h
@@ -395,6 +395,7 @@ public:
@@ -387,6 +387,7 @@ public:
// Sets whether select popup menus should be rendered by the browser.
BLINK_EXPORT static void setUseExternalPopupMenus(bool);