Update to Chromium revision 233896.

- The CefBrowserSettings.author_and_user_styles option is now always enabled.

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1512 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt 2013-11-08 21:28:56 +00:00
parent d789d84c30
commit 133e06c50a
52 changed files with 452 additions and 414 deletions

View File

@ -17,5 +17,5 @@
{ {
'chromium_url': 'http://src.chromium.org/svn/trunk/src', 'chromium_url': 'http://src.chromium.org/svn/trunk/src',
'chromium_revision': '231322', 'chromium_revision': '233896',
} }

View File

@ -485,12 +485,6 @@ typedef struct _cef_browser_settings_t {
/// ///
cef_state_t tab_to_links; cef_state_t tab_to_links;
///
// Controls whether style sheets can be used. Also configurable using the
// "disable-author-and-user-styles" command-line switch.
///
cef_state_t author_and_user_styles;
/// ///
// Controls whether local storage can be used. Also configurable using the // Controls whether local storage can be used. Also configurable using the
// "disable-local-storage" command-line switch. // "disable-local-storage" command-line switch.

View File

@ -449,7 +449,6 @@ struct CefBrowserSettingsTraits {
src->image_shrink_standalone_to_fit; src->image_shrink_standalone_to_fit;
target->text_area_resize = src->text_area_resize; target->text_area_resize = src->text_area_resize;
target->tab_to_links = src->tab_to_links; target->tab_to_links = src->tab_to_links;
target->author_and_user_styles = src->author_and_user_styles;
target->local_storage = src->local_storage; target->local_storage = src->local_storage;
target->databases= src->databases; target->databases= src->databases;
target->application_cache = src->application_cache; target->application_cache = src->application_cache;

View File

@ -253,12 +253,20 @@ net::URLRequestContextGetter*
void CefBrowserContextImpl::RequestMIDISysExPermission( void CefBrowserContextImpl::RequestMIDISysExPermission(
int render_process_id, int render_process_id,
int render_view_id, int render_view_id,
int bridge_id,
const GURL& requesting_frame, const GURL& requesting_frame,
const MIDISysExPermissionCallback& callback) { const MIDISysExPermissionCallback& callback) {
// TODO(CEF): Implement Web MIDI API permission handling. // TODO(CEF): Implement Web MIDI API permission handling.
callback.Run(false); callback.Run(false);
} }
void CefBrowserContextImpl::CancelMIDISysExPermissionRequest(
int render_process_id,
int render_view_id,
int bridge_id,
const GURL& requesting_frame) {
}
content::ResourceContext* CefBrowserContextImpl::GetResourceContext() { content::ResourceContext* CefBrowserContextImpl::GetResourceContext() {
return resource_context_.get(); return resource_context_.get();
} }

View File

@ -42,8 +42,14 @@ class CefBrowserContextImpl : public CefBrowserContext {
virtual void RequestMIDISysExPermission( virtual void RequestMIDISysExPermission(
int render_process_id, int render_process_id,
int render_view_id, int render_view_id,
int bridge_id,
const GURL& requesting_frame, const GURL& requesting_frame,
const MIDISysExPermissionCallback& callback) OVERRIDE; const MIDISysExPermissionCallback& callback) OVERRIDE;
virtual void CancelMIDISysExPermissionRequest(
int render_process_id,
int render_view_id,
int bridge_id,
const GURL& requesting_frame) OVERRIDE;
virtual content::ResourceContext* GetResourceContext() OVERRIDE; virtual content::ResourceContext* GetResourceContext() OVERRIDE;
virtual content::GeolocationPermissionContext* virtual content::GeolocationPermissionContext*
GetGeolocationPermissionContext() OVERRIDE; GetGeolocationPermissionContext() OVERRIDE;

View File

@ -115,12 +115,20 @@ net::URLRequestContextGetter*
void CefBrowserContextProxy::RequestMIDISysExPermission( void CefBrowserContextProxy::RequestMIDISysExPermission(
int render_process_id, int render_process_id,
int render_view_id, int render_view_id,
int bridge_id,
const GURL& requesting_frame, const GURL& requesting_frame,
const MIDISysExPermissionCallback& callback) { const MIDISysExPermissionCallback& callback) {
// TODO(CEF): Implement Web MIDI API permission handling. // TODO(CEF): Implement Web MIDI API permission handling.
callback.Run(false); callback.Run(false);
} }
void CefBrowserContextProxy::CancelMIDISysExPermissionRequest(
int render_process_id,
int render_view_id,
int bridge_id,
const GURL& requesting_frame) {
}
content::ResourceContext* CefBrowserContextProxy::GetResourceContext() { content::ResourceContext* CefBrowserContextProxy::GetResourceContext() {
return resource_context_.get(); return resource_context_.get();
} }

View File

@ -50,8 +50,14 @@ class CefBrowserContextProxy : public CefBrowserContext {
virtual void RequestMIDISysExPermission( virtual void RequestMIDISysExPermission(
int render_process_id, int render_process_id,
int render_view_id, int render_view_id,
int bridge_id,
const GURL& requesting_frame, const GURL& requesting_frame,
const MIDISysExPermissionCallback& callback) OVERRIDE; const MIDISysExPermissionCallback& callback) OVERRIDE;
virtual void CancelMIDISysExPermissionRequest(
int render_process_id,
int render_view_id,
int bridge_id,
const GURL& requesting_frame) OVERRIDE;
virtual content::ResourceContext* GetResourceContext() OVERRIDE; virtual content::ResourceContext* GetResourceContext() OVERRIDE;
virtual content::GeolocationPermissionContext* virtual content::GeolocationPermissionContext*
GetGeolocationPermissionContext() OVERRIDE; GetGeolocationPermissionContext() OVERRIDE;

View File

@ -107,16 +107,16 @@ void ShowDevToolsWithHelper(ShowDevToolsHelper* helper) {
bool GetCefKeyEvent(const content::NativeWebKeyboardEvent& event, bool GetCefKeyEvent(const content::NativeWebKeyboardEvent& event,
CefKeyEvent& cef_event) { CefKeyEvent& cef_event) {
switch (event.type) { switch (event.type) {
case WebKit::WebKeyboardEvent::RawKeyDown: case blink::WebKeyboardEvent::RawKeyDown:
cef_event.type = KEYEVENT_RAWKEYDOWN; cef_event.type = KEYEVENT_RAWKEYDOWN;
break; break;
case WebKit::WebKeyboardEvent::KeyDown: case blink::WebKeyboardEvent::KeyDown:
cef_event.type = KEYEVENT_KEYDOWN; cef_event.type = KEYEVENT_KEYDOWN;
break; break;
case WebKit::WebKeyboardEvent::KeyUp: case blink::WebKeyboardEvent::KeyUp:
cef_event.type = KEYEVENT_KEYUP; cef_event.type = KEYEVENT_KEYUP;
break; break;
case WebKit::WebKeyboardEvent::Char: case blink::WebKeyboardEvent::Char:
cef_event.type = KEYEVENT_CHAR; cef_event.type = KEYEVENT_CHAR;
break; break;
default: default:
@ -124,15 +124,15 @@ bool GetCefKeyEvent(const content::NativeWebKeyboardEvent& event,
} }
cef_event.modifiers = 0; cef_event.modifiers = 0;
if (event.modifiers & WebKit::WebKeyboardEvent::ShiftKey) if (event.modifiers & blink::WebKeyboardEvent::ShiftKey)
cef_event.modifiers |= EVENTFLAG_SHIFT_DOWN; cef_event.modifiers |= EVENTFLAG_SHIFT_DOWN;
if (event.modifiers & WebKit::WebKeyboardEvent::ControlKey) if (event.modifiers & blink::WebKeyboardEvent::ControlKey)
cef_event.modifiers |= EVENTFLAG_CONTROL_DOWN; cef_event.modifiers |= EVENTFLAG_CONTROL_DOWN;
if (event.modifiers & WebKit::WebKeyboardEvent::AltKey) if (event.modifiers & blink::WebKeyboardEvent::AltKey)
cef_event.modifiers |= EVENTFLAG_ALT_DOWN; cef_event.modifiers |= EVENTFLAG_ALT_DOWN;
if (event.modifiers & WebKit::WebKeyboardEvent::MetaKey) if (event.modifiers & blink::WebKeyboardEvent::MetaKey)
cef_event.modifiers |= EVENTFLAG_COMMAND_DOWN; cef_event.modifiers |= EVENTFLAG_COMMAND_DOWN;
if (event.modifiers & WebKit::WebKeyboardEvent::IsKeyPad) if (event.modifiers & blink::WebKeyboardEvent::IsKeyPad)
cef_event.modifiers |= EVENTFLAG_IS_KEY_PAD; cef_event.modifiers |= EVENTFLAG_IS_KEY_PAD;
cef_event.windows_key_code = event.windowsKeyCode; cef_event.windows_key_code = event.windowsKeyCode;
@ -679,7 +679,7 @@ void CefBrowserHostImpl::Find(int identifier, const CefString& searchText,
if (!web_contents_) if (!web_contents_)
return; return;
WebKit::WebFindOptions options; blink::WebFindOptions options;
options.forward = forward; options.forward = forward;
options.matchCase = matchCase; options.matchCase = matchCase;
options.findNext = findNext; options.findNext = findNext;
@ -891,7 +891,7 @@ void CefBrowserHostImpl::SendMouseClickEvent(const CefMouseEvent& event,
return; return;
} }
WebKit::WebMouseEvent web_event; blink::WebMouseEvent web_event;
PlatformTranslateClickEvent(web_event, event, type, mouseUp, clickCount); PlatformTranslateClickEvent(web_event, event, type, mouseUp, clickCount);
SendMouseEvent(web_event); SendMouseEvent(web_event);
@ -906,7 +906,7 @@ void CefBrowserHostImpl::SendMouseMoveEvent(const CefMouseEvent& event,
return; return;
} }
WebKit::WebMouseEvent web_event; blink::WebMouseEvent web_event;
PlatformTranslateMoveEvent(web_event, event, mouseLeave); PlatformTranslateMoveEvent(web_event, event, mouseLeave);
SendMouseEvent(web_event); SendMouseEvent(web_event);
@ -921,7 +921,7 @@ void CefBrowserHostImpl::SendMouseWheelEvent(const CefMouseEvent& event,
return; return;
} }
WebKit::WebMouseWheelEvent web_event; blink::WebMouseWheelEvent web_event;
PlatformTranslateWheelEvent(web_event, event, deltaX, deltaY); PlatformTranslateWheelEvent(web_event, event, deltaX, deltaY);
if (!IsWindowRenderingDisabled()) { if (!IsWindowRenderingDisabled()) {
@ -945,33 +945,33 @@ int CefBrowserHostImpl::TranslateModifiers(uint32 cef_modifiers) {
int webkit_modifiers = 0; int webkit_modifiers = 0;
// Set modifiers based on key state. // Set modifiers based on key state.
if (cef_modifiers & EVENTFLAG_SHIFT_DOWN) if (cef_modifiers & EVENTFLAG_SHIFT_DOWN)
webkit_modifiers |= WebKit::WebInputEvent::ShiftKey; webkit_modifiers |= blink::WebInputEvent::ShiftKey;
if (cef_modifiers & EVENTFLAG_CONTROL_DOWN) if (cef_modifiers & EVENTFLAG_CONTROL_DOWN)
webkit_modifiers |= WebKit::WebInputEvent::ControlKey; webkit_modifiers |= blink::WebInputEvent::ControlKey;
if (cef_modifiers & EVENTFLAG_ALT_DOWN) if (cef_modifiers & EVENTFLAG_ALT_DOWN)
webkit_modifiers |= WebKit::WebInputEvent::AltKey; webkit_modifiers |= blink::WebInputEvent::AltKey;
if (cef_modifiers & EVENTFLAG_COMMAND_DOWN) if (cef_modifiers & EVENTFLAG_COMMAND_DOWN)
webkit_modifiers |= WebKit::WebInputEvent::MetaKey; webkit_modifiers |= blink::WebInputEvent::MetaKey;
if (cef_modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON) if (cef_modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON)
webkit_modifiers |= WebKit::WebInputEvent::LeftButtonDown; webkit_modifiers |= blink::WebInputEvent::LeftButtonDown;
if (cef_modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON) if (cef_modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON)
webkit_modifiers |= WebKit::WebInputEvent::MiddleButtonDown; webkit_modifiers |= blink::WebInputEvent::MiddleButtonDown;
if (cef_modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON) if (cef_modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON)
webkit_modifiers |= WebKit::WebInputEvent::RightButtonDown; webkit_modifiers |= blink::WebInputEvent::RightButtonDown;
if (cef_modifiers & EVENTFLAG_CAPS_LOCK_ON) if (cef_modifiers & EVENTFLAG_CAPS_LOCK_ON)
webkit_modifiers |= WebKit::WebInputEvent::CapsLockOn; webkit_modifiers |= blink::WebInputEvent::CapsLockOn;
if (cef_modifiers & EVENTFLAG_NUM_LOCK_ON) if (cef_modifiers & EVENTFLAG_NUM_LOCK_ON)
webkit_modifiers |= WebKit::WebInputEvent::NumLockOn; webkit_modifiers |= blink::WebInputEvent::NumLockOn;
if (cef_modifiers & EVENTFLAG_IS_LEFT) if (cef_modifiers & EVENTFLAG_IS_LEFT)
webkit_modifiers |= WebKit::WebInputEvent::IsLeft; webkit_modifiers |= blink::WebInputEvent::IsLeft;
if (cef_modifiers & EVENTFLAG_IS_RIGHT) if (cef_modifiers & EVENTFLAG_IS_RIGHT)
webkit_modifiers |= WebKit::WebInputEvent::IsRight; webkit_modifiers |= blink::WebInputEvent::IsRight;
if (cef_modifiers & EVENTFLAG_IS_KEY_PAD) if (cef_modifiers & EVENTFLAG_IS_KEY_PAD)
webkit_modifiers |= WebKit::WebInputEvent::IsKeyPad; webkit_modifiers |= blink::WebInputEvent::IsKeyPad;
return webkit_modifiers; return webkit_modifiers;
} }
void CefBrowserHostImpl::SendMouseEvent(const WebKit::WebMouseEvent& event) { void CefBrowserHostImpl::SendMouseEvent(const blink::WebMouseEvent& event) {
if (!IsWindowRenderingDisabled()) { if (!IsWindowRenderingDisabled()) {
content::RenderWidgetHost* widget = web_contents()->GetRenderViewHost(); content::RenderWidgetHost* widget = web_contents()->GetRenderViewHost();
if (widget) if (widget)
@ -1772,7 +1772,7 @@ void CefBrowserHostImpl::HandleKeyboardEvent(
bool CefBrowserHostImpl::CanDragEnter( bool CefBrowserHostImpl::CanDragEnter(
content::WebContents* source, content::WebContents* source,
const content::DropData& data, const content::DropData& data,
WebKit::WebDragOperationsMask mask) { blink::WebDragOperationsMask mask) {
CefRefPtr<CefDragHandler> handler = client_->GetDragHandler(); CefRefPtr<CefDragHandler> handler = client_->GetDragHandler();
if (handler.get()) { if (handler.get()) {
CefRefPtr<CefDragData> drag_data(new CefDragDataImpl(data)); CefRefPtr<CefDragData> drag_data(new CefDragDataImpl(data));

View File

@ -34,7 +34,7 @@ namespace content {
struct NativeWebKeyboardEvent; struct NativeWebKeyboardEvent;
} }
namespace WebKit { namespace blink {
class WebMouseEvent; class WebMouseEvent;
class WebMouseWheelEvent; class WebMouseWheelEvent;
class WebInputEvent; class WebInputEvent;
@ -321,7 +321,7 @@ class CefBrowserHostImpl : public CefBrowserHost,
virtual bool CanDragEnter( virtual bool CanDragEnter(
content::WebContents* source, content::WebContents* source,
const content::DropData& data, const content::DropData& data,
WebKit::WebDragOperationsMask operations_allowed) OVERRIDE; blink::WebDragOperationsMask operations_allowed) OVERRIDE;
virtual bool ShouldCreateWebContents( virtual bool ShouldCreateWebContents(
content::WebContents* web_contents, content::WebContents* web_contents,
int route_id, int route_id,
@ -453,21 +453,21 @@ class CefBrowserHostImpl : public CefBrowserHost,
void PlatformTranslateKeyEvent(content::NativeWebKeyboardEvent& native_event, void PlatformTranslateKeyEvent(content::NativeWebKeyboardEvent& native_event,
const CefKeyEvent& key_event); const CefKeyEvent& key_event);
void PlatformTranslateClickEvent(WebKit::WebMouseEvent& web_event, void PlatformTranslateClickEvent(blink::WebMouseEvent& web_event,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
CefBrowserHost::MouseButtonType type, CefBrowserHost::MouseButtonType type,
bool mouseUp, int clickCount); bool mouseUp, int clickCount);
void PlatformTranslateMoveEvent(WebKit::WebMouseEvent& web_event, void PlatformTranslateMoveEvent(blink::WebMouseEvent& web_event,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
bool mouseLeave); bool mouseLeave);
void PlatformTranslateWheelEvent(WebKit::WebMouseWheelEvent& web_event, void PlatformTranslateWheelEvent(blink::WebMouseWheelEvent& web_event,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
int deltaX, int deltaY); int deltaX, int deltaY);
void PlatformTranslateMouseEvent(WebKit::WebMouseEvent& web_event, void PlatformTranslateMouseEvent(blink::WebMouseEvent& web_event,
const CefMouseEvent& mouse_event); const CefMouseEvent& mouse_event);
int TranslateModifiers(uint32 cefKeyStates); int TranslateModifiers(uint32 cefKeyStates);
void SendMouseEvent(const WebKit::WebMouseEvent& web_event); void SendMouseEvent(const blink::WebMouseEvent& web_event);
void OnAddressChange(CefRefPtr<CefFrame> frame, void OnAddressChange(CefRefPtr<CefFrame> frame,
const GURL& url); const GURL& url);

View File

@ -443,13 +443,13 @@ void CefBrowserHostImpl::PlatformTranslateKeyEvent(
switch (key_event.type) { switch (key_event.type) {
case KEYEVENT_RAWKEYDOWN: case KEYEVENT_RAWKEYDOWN:
case KEYEVENT_KEYDOWN: case KEYEVENT_KEYDOWN:
result.type = WebKit::WebInputEvent::RawKeyDown; result.type = blink::WebInputEvent::RawKeyDown;
break; break;
case KEYEVENT_KEYUP: case KEYEVENT_KEYUP:
result.type = WebKit::WebInputEvent::KeyUp; result.type = blink::WebInputEvent::KeyUp;
break; break;
case KEYEVENT_CHAR: case KEYEVENT_CHAR:
result.type = WebKit::WebInputEvent::Char; result.type = blink::WebInputEvent::Char;
break; break;
default: default:
NOTREACHED(); NOTREACHED();
@ -457,7 +457,7 @@ void CefBrowserHostImpl::PlatformTranslateKeyEvent(
} }
void CefBrowserHostImpl::PlatformTranslateClickEvent( void CefBrowserHostImpl::PlatformTranslateClickEvent(
WebKit::WebMouseEvent& result, blink::WebMouseEvent& result,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
MouseButtonType type, MouseButtonType type,
bool mouseUp, int clickCount) { bool mouseUp, int clickCount) {
@ -465,19 +465,19 @@ void CefBrowserHostImpl::PlatformTranslateClickEvent(
switch (type) { switch (type) {
case MBT_LEFT: case MBT_LEFT:
result.type = mouseUp ? WebKit::WebInputEvent::MouseUp : result.type = mouseUp ? blink::WebInputEvent::MouseUp :
WebKit::WebInputEvent::MouseDown; blink::WebInputEvent::MouseDown;
result.button = WebKit::WebMouseEvent::ButtonLeft; result.button = blink::WebMouseEvent::ButtonLeft;
break; break;
case MBT_MIDDLE: case MBT_MIDDLE:
result.type = mouseUp ? WebKit::WebInputEvent::MouseUp : result.type = mouseUp ? blink::WebInputEvent::MouseUp :
WebKit::WebInputEvent::MouseDown; blink::WebInputEvent::MouseDown;
result.button = WebKit::WebMouseEvent::ButtonMiddle; result.button = blink::WebMouseEvent::ButtonMiddle;
break; break;
case MBT_RIGHT: case MBT_RIGHT:
result.type = mouseUp ? WebKit::WebInputEvent::MouseUp : result.type = mouseUp ? blink::WebInputEvent::MouseUp :
WebKit::WebInputEvent::MouseDown; blink::WebInputEvent::MouseDown;
result.button = WebKit::WebMouseEvent::ButtonRight; result.button = blink::WebMouseEvent::ButtonRight;
break; break;
default: default:
NOTREACHED(); NOTREACHED();
@ -487,37 +487,37 @@ void CefBrowserHostImpl::PlatformTranslateClickEvent(
} }
void CefBrowserHostImpl::PlatformTranslateMoveEvent( void CefBrowserHostImpl::PlatformTranslateMoveEvent(
WebKit::WebMouseEvent& result, blink::WebMouseEvent& result,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
bool mouseLeave) { bool mouseLeave) {
PlatformTranslateMouseEvent(result, mouse_event); PlatformTranslateMouseEvent(result, mouse_event);
if (!mouseLeave) { if (!mouseLeave) {
result.type = WebKit::WebInputEvent::MouseMove; result.type = blink::WebInputEvent::MouseMove;
if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON) if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonLeft; result.button = blink::WebMouseEvent::ButtonLeft;
else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonMiddle; result.button = blink::WebMouseEvent::ButtonMiddle;
else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonRight; result.button = blink::WebMouseEvent::ButtonRight;
else else
result.button = WebKit::WebMouseEvent::ButtonNone; result.button = blink::WebMouseEvent::ButtonNone;
} else { } else {
result.type = WebKit::WebInputEvent::MouseLeave; result.type = blink::WebInputEvent::MouseLeave;
result.button = WebKit::WebMouseEvent::ButtonNone; result.button = blink::WebMouseEvent::ButtonNone;
} }
result.clickCount = 0; result.clickCount = 0;
} }
void CefBrowserHostImpl::PlatformTranslateWheelEvent( void CefBrowserHostImpl::PlatformTranslateWheelEvent(
WebKit::WebMouseWheelEvent& result, blink::WebMouseWheelEvent& result,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
int deltaX, int deltaY) { int deltaX, int deltaY) {
result = WebKit::WebMouseWheelEvent(); result = blink::WebMouseWheelEvent();
PlatformTranslateMouseEvent(result, mouse_event); PlatformTranslateMouseEvent(result, mouse_event);
result.type = WebKit::WebInputEvent::MouseWheel; result.type = blink::WebInputEvent::MouseWheel;
static const double scrollbarPixelsPerGtkTick = 40.0; static const double scrollbarPixelsPerGtkTick = 40.0;
result.deltaX = deltaX; result.deltaX = deltaX;
@ -528,21 +528,21 @@ void CefBrowserHostImpl::PlatformTranslateWheelEvent(
// Unless the phase and momentumPhase are passed in as parameters to this // Unless the phase and momentumPhase are passed in as parameters to this
// function, there is no way to know them // function, there is no way to know them
result.phase = WebKit::WebMouseWheelEvent::PhaseNone; result.phase = blink::WebMouseWheelEvent::PhaseNone;
result.momentumPhase = WebKit::WebMouseWheelEvent::PhaseNone; result.momentumPhase = blink::WebMouseWheelEvent::PhaseNone;
if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON) if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonLeft; result.button = blink::WebMouseEvent::ButtonLeft;
else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonMiddle; result.button = blink::WebMouseEvent::ButtonMiddle;
else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonRight; result.button = blink::WebMouseEvent::ButtonRight;
else else
result.button = WebKit::WebMouseEvent::ButtonNone; result.button = blink::WebMouseEvent::ButtonNone;
} }
void CefBrowserHostImpl::PlatformTranslateMouseEvent( void CefBrowserHostImpl::PlatformTranslateMouseEvent(
WebKit::WebMouseEvent& result, blink::WebMouseEvent& result,
const CefMouseEvent& mouse_event) { const CefMouseEvent& mouse_event) {
// position // position
result.x = mouse_event.x; result.x = mouse_event.x;

View File

@ -521,13 +521,13 @@ void CefBrowserHostImpl::PlatformTranslateKeyEvent(
native_event = content::NativeWebKeyboardEvent(synthetic_event); native_event = content::NativeWebKeyboardEvent(synthetic_event);
if (key_event.type == KEYEVENT_CHAR) if (key_event.type == KEYEVENT_CHAR)
native_event.type = WebKit::WebInputEvent::Char; native_event.type = blink::WebInputEvent::Char;
native_event.isSystemKey = key_event.is_system_key; native_event.isSystemKey = key_event.is_system_key;
} }
void CefBrowserHostImpl::PlatformTranslateClickEvent( void CefBrowserHostImpl::PlatformTranslateClickEvent(
WebKit::WebMouseEvent& result, blink::WebMouseEvent& result,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
MouseButtonType type, MouseButtonType type,
bool mouseUp, int clickCount) { bool mouseUp, int clickCount) {
@ -535,19 +535,19 @@ void CefBrowserHostImpl::PlatformTranslateClickEvent(
switch (type) { switch (type) {
case MBT_LEFT: case MBT_LEFT:
result.type = mouseUp ? WebKit::WebInputEvent::MouseUp : result.type = mouseUp ? blink::WebInputEvent::MouseUp :
WebKit::WebInputEvent::MouseDown; blink::WebInputEvent::MouseDown;
result.button = WebKit::WebMouseEvent::ButtonLeft; result.button = blink::WebMouseEvent::ButtonLeft;
break; break;
case MBT_MIDDLE: case MBT_MIDDLE:
result.type = mouseUp ? WebKit::WebInputEvent::MouseUp : result.type = mouseUp ? blink::WebInputEvent::MouseUp :
WebKit::WebInputEvent::MouseDown; blink::WebInputEvent::MouseDown;
result.button = WebKit::WebMouseEvent::ButtonMiddle; result.button = blink::WebMouseEvent::ButtonMiddle;
break; break;
case MBT_RIGHT: case MBT_RIGHT:
result.type = mouseUp ? WebKit::WebInputEvent::MouseUp : result.type = mouseUp ? blink::WebInputEvent::MouseUp :
WebKit::WebInputEvent::MouseDown; blink::WebInputEvent::MouseDown;
result.button = WebKit::WebMouseEvent::ButtonRight; result.button = blink::WebMouseEvent::ButtonRight;
break; break;
default: default:
NOTREACHED(); NOTREACHED();
@ -557,37 +557,37 @@ void CefBrowserHostImpl::PlatformTranslateClickEvent(
} }
void CefBrowserHostImpl::PlatformTranslateMoveEvent( void CefBrowserHostImpl::PlatformTranslateMoveEvent(
WebKit::WebMouseEvent& result, blink::WebMouseEvent& result,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
bool mouseLeave) { bool mouseLeave) {
PlatformTranslateMouseEvent(result, mouse_event); PlatformTranslateMouseEvent(result, mouse_event);
if (!mouseLeave) { if (!mouseLeave) {
result.type = WebKit::WebInputEvent::MouseMove; result.type = blink::WebInputEvent::MouseMove;
if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON) if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonLeft; result.button = blink::WebMouseEvent::ButtonLeft;
else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonMiddle; result.button = blink::WebMouseEvent::ButtonMiddle;
else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonRight; result.button = blink::WebMouseEvent::ButtonRight;
else else
result.button = WebKit::WebMouseEvent::ButtonNone; result.button = blink::WebMouseEvent::ButtonNone;
} else { } else {
result.type = WebKit::WebInputEvent::MouseLeave; result.type = blink::WebInputEvent::MouseLeave;
result.button = WebKit::WebMouseEvent::ButtonNone; result.button = blink::WebMouseEvent::ButtonNone;
} }
result.clickCount = 0; result.clickCount = 0;
} }
void CefBrowserHostImpl::PlatformTranslateWheelEvent( void CefBrowserHostImpl::PlatformTranslateWheelEvent(
WebKit::WebMouseWheelEvent& result, blink::WebMouseWheelEvent& result,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
int deltaX, int deltaY) { int deltaX, int deltaY) {
result = WebKit::WebMouseWheelEvent(); result = blink::WebMouseWheelEvent();
PlatformTranslateMouseEvent(result, mouse_event); PlatformTranslateMouseEvent(result, mouse_event);
result.type = WebKit::WebInputEvent::MouseWheel; result.type = blink::WebInputEvent::MouseWheel;
static const double scrollbarPixelsPerCocoaTick = 40.0; static const double scrollbarPixelsPerCocoaTick = 40.0;
result.deltaX = deltaX; result.deltaX = deltaX;
@ -598,21 +598,21 @@ void CefBrowserHostImpl::PlatformTranslateWheelEvent(
// Unless the phase and momentumPhase are passed in as parameters to this // Unless the phase and momentumPhase are passed in as parameters to this
// function, there is no way to know them // function, there is no way to know them
result.phase = WebKit::WebMouseWheelEvent::PhaseNone; result.phase = blink::WebMouseWheelEvent::PhaseNone;
result.momentumPhase = WebKit::WebMouseWheelEvent::PhaseNone; result.momentumPhase = blink::WebMouseWheelEvent::PhaseNone;
if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON) if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonLeft; result.button = blink::WebMouseEvent::ButtonLeft;
else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonMiddle; result.button = blink::WebMouseEvent::ButtonMiddle;
else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonRight; result.button = blink::WebMouseEvent::ButtonRight;
else else
result.button = WebKit::WebMouseEvent::ButtonNone; result.button = blink::WebMouseEvent::ButtonNone;
} }
void CefBrowserHostImpl::PlatformTranslateMouseEvent( void CefBrowserHostImpl::PlatformTranslateMouseEvent(
WebKit::WebMouseEvent& result, blink::WebMouseEvent& result,
const CefMouseEvent& mouse_event) { const CefMouseEvent& mouse_event) {
// position // position
result.x = mouse_event.x; result.x = mouse_event.x;

View File

@ -695,31 +695,31 @@ void CefBrowserHostImpl::PlatformTranslateKeyEvent(
switch (key_event.type) { switch (key_event.type) {
case KEYEVENT_RAWKEYDOWN: case KEYEVENT_RAWKEYDOWN:
case KEYEVENT_KEYDOWN: case KEYEVENT_KEYDOWN:
result.type = WebKit::WebInputEvent::RawKeyDown; result.type = blink::WebInputEvent::RawKeyDown;
break; break;
case KEYEVENT_KEYUP: case KEYEVENT_KEYUP:
result.type = WebKit::WebInputEvent::KeyUp; result.type = blink::WebInputEvent::KeyUp;
break; break;
case KEYEVENT_CHAR: case KEYEVENT_CHAR:
result.type = WebKit::WebInputEvent::Char; result.type = blink::WebInputEvent::Char;
break; break;
default: default:
NOTREACHED(); NOTREACHED();
} }
if (result.type == WebKit::WebInputEvent::Char || if (result.type == blink::WebInputEvent::Char ||
result.type == WebKit::WebInputEvent::RawKeyDown) { result.type == blink::WebInputEvent::RawKeyDown) {
result.text[0] = result.windowsKeyCode; result.text[0] = result.windowsKeyCode;
result.unmodifiedText[0] = result.windowsKeyCode; result.unmodifiedText[0] = result.windowsKeyCode;
} }
if (result.type != WebKit::WebInputEvent::Char) if (result.type != blink::WebInputEvent::Char)
result.setKeyIdentifierFromWindowsKeyCode(); result.setKeyIdentifierFromWindowsKeyCode();
result.modifiers |= TranslateModifiers(key_event.modifiers); result.modifiers |= TranslateModifiers(key_event.modifiers);
} }
void CefBrowserHostImpl::PlatformTranslateClickEvent( void CefBrowserHostImpl::PlatformTranslateClickEvent(
WebKit::WebMouseEvent& result, blink::WebMouseEvent& result,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
CefBrowserHost::MouseButtonType type, CefBrowserHost::MouseButtonType type,
bool mouseUp, int clickCount) { bool mouseUp, int clickCount) {
@ -727,19 +727,19 @@ void CefBrowserHostImpl::PlatformTranslateClickEvent(
switch (type) { switch (type) {
case MBT_LEFT: case MBT_LEFT:
result.type = mouseUp ? WebKit::WebInputEvent::MouseUp : result.type = mouseUp ? blink::WebInputEvent::MouseUp :
WebKit::WebInputEvent::MouseDown; blink::WebInputEvent::MouseDown;
result.button = WebKit::WebMouseEvent::ButtonLeft; result.button = blink::WebMouseEvent::ButtonLeft;
break; break;
case MBT_MIDDLE: case MBT_MIDDLE:
result.type = mouseUp ? WebKit::WebInputEvent::MouseUp : result.type = mouseUp ? blink::WebInputEvent::MouseUp :
WebKit::WebInputEvent::MouseDown; blink::WebInputEvent::MouseDown;
result.button = WebKit::WebMouseEvent::ButtonMiddle; result.button = blink::WebMouseEvent::ButtonMiddle;
break; break;
case MBT_RIGHT: case MBT_RIGHT:
result.type = mouseUp ? WebKit::WebInputEvent::MouseUp : result.type = mouseUp ? blink::WebInputEvent::MouseUp :
WebKit::WebInputEvent::MouseDown; blink::WebInputEvent::MouseDown;
result.button = WebKit::WebMouseEvent::ButtonRight; result.button = blink::WebMouseEvent::ButtonRight;
break; break;
default: default:
NOTREACHED(); NOTREACHED();
@ -749,37 +749,37 @@ void CefBrowserHostImpl::PlatformTranslateClickEvent(
} }
void CefBrowserHostImpl::PlatformTranslateMoveEvent( void CefBrowserHostImpl::PlatformTranslateMoveEvent(
WebKit::WebMouseEvent& result, blink::WebMouseEvent& result,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
bool mouseLeave) { bool mouseLeave) {
PlatformTranslateMouseEvent(result, mouse_event); PlatformTranslateMouseEvent(result, mouse_event);
if (!mouseLeave) { if (!mouseLeave) {
result.type = WebKit::WebInputEvent::MouseMove; result.type = blink::WebInputEvent::MouseMove;
if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON) if (mouse_event.modifiers & EVENTFLAG_LEFT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonLeft; result.button = blink::WebMouseEvent::ButtonLeft;
else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_MIDDLE_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonMiddle; result.button = blink::WebMouseEvent::ButtonMiddle;
else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON) else if (mouse_event.modifiers & EVENTFLAG_RIGHT_MOUSE_BUTTON)
result.button = WebKit::WebMouseEvent::ButtonRight; result.button = blink::WebMouseEvent::ButtonRight;
else else
result.button = WebKit::WebMouseEvent::ButtonNone; result.button = blink::WebMouseEvent::ButtonNone;
} else { } else {
result.type = WebKit::WebInputEvent::MouseLeave; result.type = blink::WebInputEvent::MouseLeave;
result.button = WebKit::WebMouseEvent::ButtonNone; result.button = blink::WebMouseEvent::ButtonNone;
} }
result.clickCount = 0; result.clickCount = 0;
} }
void CefBrowserHostImpl::PlatformTranslateWheelEvent( void CefBrowserHostImpl::PlatformTranslateWheelEvent(
WebKit::WebMouseWheelEvent& result, blink::WebMouseWheelEvent& result,
const CefMouseEvent& mouse_event, const CefMouseEvent& mouse_event,
int deltaX, int deltaY) { int deltaX, int deltaY) {
PlatformTranslateMouseEvent(result, mouse_event); PlatformTranslateMouseEvent(result, mouse_event);
result.type = WebKit::WebInputEvent::MouseWheel; result.type = blink::WebInputEvent::MouseWheel;
result.button = WebKit::WebMouseEvent::ButtonNone; result.button = blink::WebMouseEvent::ButtonNone;
float wheelDelta; float wheelDelta;
bool horizontalScroll = false; bool horizontalScroll = false;
@ -818,7 +818,7 @@ void CefBrowserHostImpl::PlatformTranslateWheelEvent(
} }
void CefBrowserHostImpl::PlatformTranslateMouseEvent( void CefBrowserHostImpl::PlatformTranslateMouseEvent(
WebKit::WebMouseEvent& result, blink::WebMouseEvent& result,
const CefMouseEvent& mouse_event) { const CefMouseEvent& mouse_event) {
// position // position
result.x = mouse_event.x; result.x = mouse_event.x;

View File

@ -49,8 +49,6 @@ void SetDefaults(WebPreferences& web) {
!command_line.HasSwitch(switches::kDisableTextAreaResize); !command_line.HasSwitch(switches::kDisableTextAreaResize);
web.tabs_to_links = web.tabs_to_links =
!command_line.HasSwitch(switches::kDisableTabToLinks); !command_line.HasSwitch(switches::kDisableTabToLinks);
web.author_and_user_styles_enabled =
!command_line.HasSwitch(switches::kDisableAuthorAndUserStyles);
} }
// Helper macro for setting a WebPreferences variable based on the value of a // Helper macro for setting a WebPreferences variable based on the value of a
@ -131,7 +129,6 @@ void BrowserToWebSettings(const CefBrowserSettings& cef, WebPreferences& web) {
web.shrinks_standalone_images_to_fit); web.shrinks_standalone_images_to_fit);
SET_STATE(cef.text_area_resize, web.text_areas_are_resizable); SET_STATE(cef.text_area_resize, web.text_areas_are_resizable);
SET_STATE(cef.tab_to_links, web.tabs_to_links); SET_STATE(cef.tab_to_links, web.tabs_to_links);
SET_STATE(cef.author_and_user_styles, web.author_and_user_styles_enabled);
SET_STATE(cef.local_storage, web.local_storage_enabled); SET_STATE(cef.local_storage, web.local_storage_enabled);
SET_STATE(cef.databases, web.databases_enabled); SET_STATE(cef.databases, web.databases_enabled);
SET_STATE(cef.application_cache, web.application_cache_enabled); SET_STATE(cef.application_cache, web.application_cache_enabled);

View File

@ -247,7 +247,7 @@ class CefPluginServiceFilter : public content::PluginServiceFilter {
} }
}; };
void TranslatePopupFeatures(const WebKit::WebWindowFeatures& webKitFeatures, void TranslatePopupFeatures(const blink::WebWindowFeatures& webKitFeatures,
CefPopupFeatures& features) { CefPopupFeatures& features) {
features.x = static_cast<int>(webKitFeatures.x); features.x = static_cast<int>(webKitFeatures.x);
features.xSet = webKitFeatures.xSet; features.xSet = webKitFeatures.xSet;
@ -633,7 +633,7 @@ bool CefContentBrowserClient::CanCreateWindow(
const GURL& target_url, const GURL& target_url,
const content::Referrer& referrer, const content::Referrer& referrer,
WindowOpenDisposition disposition, WindowOpenDisposition disposition,
const WebKit::WebWindowFeatures& features, const blink::WebWindowFeatures& features,
bool user_gesture, bool user_gesture,
bool opener_suppressed, bool opener_suppressed,
content::ResourceContext* context, content::ResourceContext* context,

View File

@ -116,7 +116,7 @@ class CefContentBrowserClient : public content::ContentBrowserClient {
const GURL& target_url, const GURL& target_url,
const content::Referrer& referrer, const content::Referrer& referrer,
WindowOpenDisposition disposition, WindowOpenDisposition disposition,
const WebKit::WebWindowFeatures& features, const blink::WebWindowFeatures& features,
bool user_gesture, bool user_gesture,
bool opener_suppressed, bool opener_suppressed,
content::ResourceContext* context, content::ResourceContext* context,

View File

@ -35,7 +35,7 @@ CefContextMenuParamsImpl::TypeFlags CefContextMenuParamsImpl::GetTypeFlags() {
type_flags |= CM_TYPEFLAG_FRAME; type_flags |= CM_TYPEFLAG_FRAME;
if (!params.link_url.is_empty()) if (!params.link_url.is_empty())
type_flags |= CM_TYPEFLAG_LINK; type_flags |= CM_TYPEFLAG_LINK;
if (params.media_type != WebKit::WebContextMenuData::MediaTypeNone) if (params.media_type != blink::WebContextMenuData::MediaTypeNone)
type_flags |= CM_TYPEFLAG_MEDIA; type_flags |= CM_TYPEFLAG_MEDIA;
if (!params.selection_text.empty()) if (!params.selection_text.empty())
type_flags |= CM_TYPEFLAG_SELECTION; type_flags |= CM_TYPEFLAG_SELECTION;

View File

@ -64,19 +64,19 @@ void RenderParamsFromPrintSettings(const printing::PrintSettings& settings,
params->margin_left = settings.page_setup_device_units().content_area().x(); params->margin_left = settings.page_setup_device_units().content_area().x();
params->dpi = settings.dpi(); params->dpi = settings.dpi();
// Currently hardcoded at 1.25. See PrintSettings' constructor. // Currently hardcoded at 1.25. See PrintSettings' constructor.
params->min_shrink = settings.min_shrink; params->min_shrink = settings.min_shrink();
// Currently hardcoded at 2.0. See PrintSettings' constructor. // Currently hardcoded at 2.0. See PrintSettings' constructor.
params->max_shrink = settings.max_shrink; params->max_shrink = settings.max_shrink();
// Currently hardcoded at 72dpi. See PrintSettings' constructor. // Currently hardcoded at 72dpi. See PrintSettings' constructor.
params->desired_dpi = settings.desired_dpi; params->desired_dpi = settings.desired_dpi();
// Always use an invalid cookie. // Always use an invalid cookie.
params->document_cookie = 0; params->document_cookie = 0;
params->selection_only = settings.selection_only; params->selection_only = settings.selection_only();
params->supports_alpha_blend = settings.supports_alpha_blend(); params->supports_alpha_blend = settings.supports_alpha_blend();
params->should_print_backgrounds = settings.should_print_backgrounds; params->should_print_backgrounds = settings.should_print_backgrounds();
params->display_header_footer = settings.display_header_footer; params->display_header_footer = settings.display_header_footer();
params->title = settings.title; params->title = settings.title();
params->url = settings.url; params->url = settings.url();
} }
} // namespace } // namespace
@ -375,7 +375,7 @@ void PrintingMessageFilter::OnScriptedPrintReply(
RenderParamsFromPrintSettings(printer_query->settings(), &params.params); RenderParamsFromPrintSettings(printer_query->settings(), &params.params);
params.params.document_cookie = printer_query->cookie(); params.params.document_cookie = printer_query->cookie();
params.pages = params.pages =
printing::PageRange::GetPages(printer_query->settings().ranges); printing::PageRange::GetPages(printer_query->settings().ranges());
} }
PrintHostMsg_ScriptedPrint::WriteReplyParams(reply_msg, params); PrintHostMsg_ScriptedPrint::WriteReplyParams(reply_msg, params);
Send(reply_msg); Send(reply_msg);
@ -432,7 +432,7 @@ void PrintingMessageFilter::OnUpdatePrintSettingsReply(
RenderParamsFromPrintSettings(printer_query->settings(), &params.params); RenderParamsFromPrintSettings(printer_query->settings(), &params.params);
params.params.document_cookie = printer_query->cookie(); params.params.document_cookie = printer_query->cookie();
params.pages = params.pages =
printing::PageRange::GetPages(printer_query->settings().ranges); printing::PageRange::GetPages(printer_query->settings().ranges());
} }
PrintHostMsg_UpdatePrintSettings::WriteReplyParams(reply_msg, params); PrintHostMsg_UpdatePrintSettings::WriteReplyParams(reply_msg, params);
Send(reply_msg); Send(reply_msg);

View File

@ -19,15 +19,15 @@ namespace {
const float kDefaultScaleFactor = 1.0; const float kDefaultScaleFactor = 1.0;
static WebKit::WebScreenInfo webScreenInfoFrom(const CefScreenInfo& src) { static blink::WebScreenInfo webScreenInfoFrom(const CefScreenInfo& src) {
WebKit::WebScreenInfo webScreenInfo; blink::WebScreenInfo webScreenInfo;
webScreenInfo.deviceScaleFactor = src.device_scale_factor; webScreenInfo.deviceScaleFactor = src.device_scale_factor;
webScreenInfo.depth = src.depth; webScreenInfo.depth = src.depth;
webScreenInfo.depthPerComponent = src.depth_per_component; webScreenInfo.depthPerComponent = src.depth_per_component;
webScreenInfo.isMonochrome = src.is_monochrome; webScreenInfo.isMonochrome = src.is_monochrome;
webScreenInfo.rect = WebKit::WebRect(src.rect.x, src.rect.y, webScreenInfo.rect = blink::WebRect(src.rect.x, src.rect.y,
src.rect.width, src.rect.height); src.rect.width, src.rect.height);
webScreenInfo.availableRect = WebKit::WebRect(src.available_rect.x, webScreenInfo.availableRect = blink::WebRect(src.available_rect.x,
src.available_rect.y, src.available_rect.y,
src.available_rect.width, src.available_rect.width,
src.available_rect.height); src.available_rect.height);
@ -250,7 +250,7 @@ void CefRenderWidgetHostViewOSR::WillWmDestroy() {
} }
#endif #endif
void CefRenderWidgetHostViewOSR::GetScreenInfo(WebKit::WebScreenInfo* results) { void CefRenderWidgetHostViewOSR::GetScreenInfo(blink::WebScreenInfo* results) {
if (!browser_impl_.get()) if (!browser_impl_.get())
return; return;
@ -358,6 +358,10 @@ bool CefRenderWidgetHostViewOSR::CanCopyToVideoFrame() const {
void CefRenderWidgetHostViewOSR::OnAcceleratedCompositingStateChange() { void CefRenderWidgetHostViewOSR::OnAcceleratedCompositingStateChange() {
} }
void CefRenderWidgetHostViewOSR::AcceleratedSurfaceInitialized(
int host_id, int route_id) {
}
void CefRenderWidgetHostViewOSR::SetHasHorizontalScrollbar( void CefRenderWidgetHostViewOSR::SetHasHorizontalScrollbar(
bool has_horizontal_scrollbar) { bool has_horizontal_scrollbar) {
} }
@ -576,11 +580,11 @@ void CefRenderWidgetHostViewOSR::SendKeyEvent(
} }
void CefRenderWidgetHostViewOSR::SendMouseEvent( void CefRenderWidgetHostViewOSR::SendMouseEvent(
const WebKit::WebMouseEvent& event) { const blink::WebMouseEvent& event) {
TRACE_EVENT0("libcef", "CefRenderWidgetHostViewOSR::SendMouseEvent"); TRACE_EVENT0("libcef", "CefRenderWidgetHostViewOSR::SendMouseEvent");
if (!IsPopupWidget() && popup_host_view_) { if (!IsPopupWidget() && popup_host_view_) {
if (popup_host_view_->popup_position_.Contains(event.x, event.y)) { if (popup_host_view_->popup_position_.Contains(event.x, event.y)) {
WebKit::WebMouseEvent popup_event(event); blink::WebMouseEvent popup_event(event);
popup_event.x -= popup_host_view_->popup_position_.x(); popup_event.x -= popup_host_view_->popup_position_.x();
popup_event.y -= popup_host_view_->popup_position_.y(); popup_event.y -= popup_host_view_->popup_position_.y();
popup_event.windowX = popup_event.x; popup_event.windowX = popup_event.x;
@ -596,11 +600,11 @@ void CefRenderWidgetHostViewOSR::SendMouseEvent(
} }
void CefRenderWidgetHostViewOSR::SendMouseWheelEvent( void CefRenderWidgetHostViewOSR::SendMouseWheelEvent(
const WebKit::WebMouseWheelEvent& event) { const blink::WebMouseWheelEvent& event) {
TRACE_EVENT0("libcef", "CefRenderWidgetHostViewOSR::SendMouseWheelEvent"); TRACE_EVENT0("libcef", "CefRenderWidgetHostViewOSR::SendMouseWheelEvent");
if (!IsPopupWidget() && popup_host_view_) { if (!IsPopupWidget() && popup_host_view_) {
if (popup_host_view_->popup_position_.Contains(event.x, event.y)) { if (popup_host_view_->popup_position_.Contains(event.x, event.y)) {
WebKit::WebMouseWheelEvent popup_event(event); blink::WebMouseWheelEvent popup_event(event);
popup_event.x -= popup_host_view_->popup_position_.x(); popup_event.x -= popup_host_view_->popup_position_.x();
popup_event.y -= popup_host_view_->popup_position_.y(); popup_event.y -= popup_host_view_->popup_position_.y();
popup_event.windowX = popup_event.x; popup_event.windowX = popup_event.x;

View File

@ -137,7 +137,7 @@ class CefRenderWidgetHostViewOSR : public content::RenderWidgetHostViewBase {
#if defined(OS_WIN) && !defined(USE_AURA) #if defined(OS_WIN) && !defined(USE_AURA)
virtual void WillWmDestroy() OVERRIDE; virtual void WillWmDestroy() OVERRIDE;
#endif #endif
virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE; virtual void GetScreenInfo(blink::WebScreenInfo* results) OVERRIDE;
virtual gfx::Rect GetBoundsInRootWindow() OVERRIDE; virtual gfx::Rect GetBoundsInRootWindow() OVERRIDE;
virtual void OnAccessibilityEvents( virtual void OnAccessibilityEvents(
const std::vector<AccessibilityHostMsg_EventParams>& params) const std::vector<AccessibilityHostMsg_EventParams>& params)
@ -159,6 +159,8 @@ class CefRenderWidgetHostViewOSR : public content::RenderWidgetHostViewBase {
const base::Callback<void(bool)>& callback) OVERRIDE; const base::Callback<void(bool)>& callback) OVERRIDE;
virtual bool CanCopyToVideoFrame() const OVERRIDE; virtual bool CanCopyToVideoFrame() const OVERRIDE;
virtual void OnAcceleratedCompositingStateChange() OVERRIDE; virtual void OnAcceleratedCompositingStateChange() OVERRIDE;
virtual void AcceleratedSurfaceInitialized(
int host_id, int route_id) OVERRIDE;
virtual void SetHasHorizontalScrollbar( virtual void SetHasHorizontalScrollbar(
bool has_horizontal_scrollbar) OVERRIDE; bool has_horizontal_scrollbar) OVERRIDE;
virtual void SetScrollOffsetPinning( virtual void SetScrollOffsetPinning(
@ -191,8 +193,8 @@ class CefRenderWidgetHostViewOSR : public content::RenderWidgetHostViewBase {
virtual void SetBackground(const SkBitmap& background) OVERRIDE; virtual void SetBackground(const SkBitmap& background) OVERRIDE;
void SendKeyEvent(const content::NativeWebKeyboardEvent& event); void SendKeyEvent(const content::NativeWebKeyboardEvent& event);
void SendMouseEvent(const WebKit::WebMouseEvent& event); void SendMouseEvent(const blink::WebMouseEvent& event);
void SendMouseWheelEvent(const WebKit::WebMouseWheelEvent& event); void SendMouseWheelEvent(const blink::WebMouseWheelEvent& event);
void Invalidate(const gfx::Rect& rect, void Invalidate(const gfx::Rect& rect,
CefBrowserHost::PaintElementType type); CefBrowserHost::PaintElementType type);
@ -215,7 +217,7 @@ class CefRenderWidgetHostViewOSR : public content::RenderWidgetHostViewBase {
void set_parent_host_view(CefRenderWidgetHostViewOSR* parent_view); void set_parent_host_view(CefRenderWidgetHostViewOSR* parent_view);
bool IsPopupWidget() const { bool IsPopupWidget() const {
return popup_type_ != WebKit::WebPopupTypeNone; return popup_type_ != blink::WebPopupTypeNone;
} }
private: private:

View File

@ -62,7 +62,7 @@
string16 markedText_; string16 markedText_;
// Underline information of the |markedText_|. // Underline information of the |markedText_|.
std::vector<WebKit::WebCompositionUnderline> underlines_; std::vector<blink::WebCompositionUnderline> underlines_;
// Indicates if doCommandBySelector method receives any edit command when // Indicates if doCommandBySelector method receives any edit command when
// handling a key down event. // handling a key down event.

View File

@ -13,7 +13,7 @@
namespace { namespace {
// TODO(suzhe): Upstream this function. // TODO(suzhe): Upstream this function.
WebKit::WebColor WebColorFromNSColor(NSColor *color) { blink::WebColor WebColorFromNSColor(NSColor *color) {
CGFloat r, g, b, a; CGFloat r, g, b, a;
[color getRed:&r green:&g blue:&b alpha:&a]; [color getRed:&r green:&g blue:&b alpha:&a];
@ -27,7 +27,7 @@ WebKit::WebColor WebColorFromNSColor(NSColor *color) {
// Extract underline information from an attributed string. Mostly copied from // Extract underline information from an attributed string. Mostly copied from
// third_party/WebKit/Source/WebKit/mac/WebView/WebHTMLView.mm // third_party/WebKit/Source/WebKit/mac/WebView/WebHTMLView.mm
void ExtractUnderlines(NSAttributedString* string, void ExtractUnderlines(NSAttributedString* string,
std::vector<WebKit::WebCompositionUnderline>* underlines) { std::vector<blink::WebCompositionUnderline>* underlines) {
int length = [[string string] length]; int length = [[string string] length];
int i = 0; int i = 0;
while (i < length) { while (i < length) {
@ -37,13 +37,13 @@ void ExtractUnderlines(NSAttributedString* string,
inRange:NSMakeRange(i, length - i)]; inRange:NSMakeRange(i, length - i)];
NSNumber *style = [attrs objectForKey: NSUnderlineStyleAttributeName]; NSNumber *style = [attrs objectForKey: NSUnderlineStyleAttributeName];
if (style) { if (style) {
WebKit::WebColor color = SK_ColorBLACK; blink::WebColor color = SK_ColorBLACK;
if (NSColor *colorAttr = if (NSColor *colorAttr =
[attrs objectForKey:NSUnderlineColorAttributeName]) { [attrs objectForKey:NSUnderlineColorAttributeName]) {
color = WebColorFromNSColor( color = WebColorFromNSColor(
[colorAttr colorUsingColorSpaceName:NSDeviceRGBColorSpace]); [colorAttr colorUsingColorSpaceName:NSDeviceRGBColorSpace]);
} }
underlines->push_back(WebKit::WebCompositionUnderline( underlines->push_back(blink::WebCompositionUnderline(
range.location, NSMaxRange(range), color, [style intValue] > 1)); range.location, NSMaxRange(range), color, [style intValue] > 1));
} }
i = range.location + range.length; i = range.location + range.length;
@ -150,7 +150,7 @@ extern "C" {
ExtractUnderlines(aString, &underlines_); ExtractUnderlines(aString, &underlines_);
} else { } else {
// Use a thin black underline by default. // Use a thin black underline by default.
underlines_.push_back(WebKit::WebCompositionUnderline(0, length, underlines_.push_back(blink::WebCompositionUnderline(0, length,
SK_ColorBLACK, false)); SK_ColorBLACK, false));
} }
@ -305,7 +305,7 @@ extern "C" {
textToBeInserted_.length() <= 1) { textToBeInserted_.length() <= 1) {
content::NativeWebKeyboardEvent event(keyEvent); content::NativeWebKeyboardEvent event(keyEvent);
if (textToBeInserted_.length() == 1) { if (textToBeInserted_.length() == 1) {
event.type = WebKit::WebInputEvent::Type::Char; event.type = blink::WebInputEvent::Type::Char;
event.text[0] = textToBeInserted_[0]; event.text[0] = textToBeInserted_[0];
event.text[1] = 0; event.text[1] = 0;
} }

View File

@ -123,7 +123,7 @@ bool CefWebContentsViewOSR::GetAllowOverlappingViews() const {
void CefWebContentsViewOSR::StartDragging( void CefWebContentsViewOSR::StartDragging(
const content::DropData& drop_data, const content::DropData& drop_data,
WebKit::WebDragOperationsMask allowed_ops, blink::WebDragOperationsMask allowed_ops,
const gfx::ImageSkia& image, const gfx::ImageSkia& image,
const gfx::Vector2d& image_offset, const gfx::Vector2d& image_offset,
const content::DragEventSourceInfo& event_info) { const content::DragEventSourceInfo& event_info) {

View File

@ -60,7 +60,7 @@ class CefWebContentsViewOSR : public content::WebContentsViewPort,
// RenderViewHostDelegateView methods. // RenderViewHostDelegateView methods.
virtual void StartDragging( virtual void StartDragging(
const content::DropData& drop_data, const content::DropData& drop_data,
WebKit::WebDragOperationsMask allowed_ops, blink::WebDragOperationsMask allowed_ops,
const gfx::ImageSkia& image, const gfx::ImageSkia& image,
const gfx::Vector2d& image_offset, const gfx::Vector2d& image_offset,
const content::DragEventSourceInfo& event_info) OVERRIDE; const content::DragEventSourceInfo& event_info) OVERRIDE;

View File

@ -80,7 +80,7 @@ IPC_STRUCT_BEGIN(CefMsg_LoadRequest_Params)
// The URL to send in the "Referer" header field. Can be empty if there is // The URL to send in the "Referer" header field. Can be empty if there is
// no referrer. // no referrer.
IPC_STRUCT_MEMBER(GURL, referrer) IPC_STRUCT_MEMBER(GURL, referrer)
// One of the WebKit::WebReferrerPolicy values. // One of the blink::WebReferrerPolicy values.
IPC_STRUCT_MEMBER(int, referrer_policy) IPC_STRUCT_MEMBER(int, referrer_policy)
// Identifies the frame within the RenderView that sent the request. // Identifies the frame within the RenderView that sent the request.

View File

@ -77,9 +77,6 @@ const char kDisableTextAreaResize[] = "disable-text-area-resize";
// Disable using the tab key to advance focus to links. // Disable using the tab key to advance focus to links.
const char kDisableTabToLinks[] = "disable-tab-to-links"; const char kDisableTabToLinks[] = "disable-tab-to-links";
// Disable user style sheets.
const char kDisableAuthorAndUserStyles[] = "disable-author-and-user-styles";
// Persist session cookies. // Persist session cookies.
const char kPersistSessionCookies[] = "persist-session-cookies"; const char kPersistSessionCookies[] = "persist-session-cookies";

View File

@ -36,7 +36,6 @@ extern const char kDisableImageLoading[];
extern const char kImageShrinkStandaloneToFit[]; extern const char kImageShrinkStandaloneToFit[];
extern const char kDisableTextAreaResize[]; extern const char kDisableTextAreaResize[];
extern const char kDisableTabToLinks[]; extern const char kDisableTabToLinks[];
extern const char kDisableAuthorAndUserStyles[];
extern const char kPersistSessionCookies[]; extern const char kPersistSessionCookies[];
extern const char kEnableMediaStream[]; extern const char kEnableMediaStream[];
extern const char kEnableSpeechInput[]; extern const char kEnableSpeechInput[];

View File

@ -282,7 +282,7 @@ void CefRequestImpl::Get(net::URLRequest* request) {
} }
} }
void CefRequestImpl::Set(const WebKit::WebURLRequest& request) { void CefRequestImpl::Set(const blink::WebURLRequest& request) {
DCHECK(!request.isNull()); DCHECK(!request.isNull());
AutoLock lock_scope(this); AutoLock lock_scope(this);
@ -291,7 +291,7 @@ void CefRequestImpl::Set(const WebKit::WebURLRequest& request) {
url_ = request.url().spec().utf16(); url_ = request.url().spec().utf16();
method_ = request.httpMethod(); method_ = request.httpMethod();
const WebKit::WebHTTPBody& body = request.httpBody(); const blink::WebHTTPBody& body = request.httpBody();
if (!body.isNull()) { if (!body.isNull()) {
postdata_ = new CefPostDataImpl(); postdata_ = new CefPostDataImpl();
static_cast<CefPostDataImpl*>(postdata_.get())->Set(body); static_cast<CefPostDataImpl*>(postdata_.get())->Set(body);
@ -303,7 +303,7 @@ void CefRequestImpl::Set(const WebKit::WebURLRequest& request) {
GetHeaderMap(request, headermap_); GetHeaderMap(request, headermap_);
flags_ = UR_FLAG_NONE; flags_ = UR_FLAG_NONE;
if (request.cachePolicy() == WebKit::WebURLRequest::ReloadIgnoringCacheData) if (request.cachePolicy() == blink::WebURLRequest::ReloadIgnoringCacheData)
flags_ |= UR_FLAG_SKIP_CACHE; flags_ |= UR_FLAG_SKIP_CACHE;
if (request.allowStoredCredentials()) if (request.allowStoredCredentials())
flags_ |= UR_FLAG_ALLOW_CACHED_CREDENTIALS; flags_ |= UR_FLAG_ALLOW_CACHED_CREDENTIALS;
@ -322,18 +322,18 @@ void CefRequestImpl::Set(const WebKit::WebURLRequest& request) {
::ResourceType::FromTargetType(request.targetType())); ::ResourceType::FromTargetType(request.targetType()));
} }
void CefRequestImpl::Get(WebKit::WebURLRequest& request) { void CefRequestImpl::Get(blink::WebURLRequest& request) {
request.initialize(); request.initialize();
AutoLock lock_scope(this); AutoLock lock_scope(this);
GURL gurl = GURL(url_.ToString()); GURL gurl = GURL(url_.ToString());
request.setURL(WebKit::WebURL(gurl)); request.setURL(blink::WebURL(gurl));
std::string method(method_); std::string method(method_);
request.setHTTPMethod(WebKit::WebString::fromUTF8(method.c_str())); request.setHTTPMethod(blink::WebString::fromUTF8(method.c_str()));
request.setTargetType(WebKit::WebURLRequest::TargetIsMainFrame); request.setTargetType(blink::WebURLRequest::TargetIsMainFrame);
WebKit::WebHTTPBody body; blink::WebHTTPBody body;
if (postdata_.get()) { if (postdata_.get()) {
body.initialize(); body.initialize();
static_cast<CefPostDataImpl*>(postdata_.get())->Get(body); static_cast<CefPostDataImpl*>(postdata_.get())->Get(body);
@ -343,8 +343,8 @@ void CefRequestImpl::Get(WebKit::WebURLRequest& request) {
SetHeaderMap(headermap_, request); SetHeaderMap(headermap_, request);
request.setCachePolicy((flags_ & UR_FLAG_SKIP_CACHE) ? request.setCachePolicy((flags_ & UR_FLAG_SKIP_CACHE) ?
WebKit::WebURLRequest::ReloadIgnoringCacheData : blink::WebURLRequest::ReloadIgnoringCacheData :
WebKit::WebURLRequest::UseProtocolCachePolicy); blink::WebURLRequest::UseProtocolCachePolicy);
#define SETBOOLFLAG(obj, flags, method, FLAG) \ #define SETBOOLFLAG(obj, flags, method, FLAG) \
obj.method((flags & (FLAG)) == (FLAG)) obj.method((flags & (FLAG)) == (FLAG))
@ -362,7 +362,7 @@ void CefRequestImpl::Get(WebKit::WebURLRequest& request) {
if (!first_party_for_cookies_.empty()) { if (!first_party_for_cookies_.empty()) {
GURL gurl = GURL(first_party_for_cookies_.ToString()); GURL gurl = GURL(first_party_for_cookies_.ToString());
request.setFirstPartyForCookies(WebKit::WebURL(gurl)); request.setFirstPartyForCookies(blink::WebURL(gurl));
} }
} }
@ -391,14 +391,14 @@ void CefRequestImpl::GetHeaderMap(const net::HttpRequestHeaders& headers,
// static // static
void CefRequestImpl::GetHeaderMap(const WebKit::WebURLRequest& request, void CefRequestImpl::GetHeaderMap(const blink::WebURLRequest& request,
HeaderMap& map) { HeaderMap& map) {
class HeaderVisitor : public WebKit::WebHTTPHeaderVisitor { class HeaderVisitor : public blink::WebHTTPHeaderVisitor {
public: public:
explicit HeaderVisitor(HeaderMap* map) : map_(map) {} explicit HeaderVisitor(HeaderMap* map) : map_(map) {}
virtual void visitHeader(const WebKit::WebString& name, virtual void visitHeader(const blink::WebString& name,
const WebKit::WebString& value) { const blink::WebString& value) {
map_->insert(std::make_pair(string16(name), string16(value))); map_->insert(std::make_pair(string16(name), string16(value)));
} }
@ -412,7 +412,7 @@ void CefRequestImpl::GetHeaderMap(const WebKit::WebURLRequest& request,
// static // static
void CefRequestImpl::SetHeaderMap(const HeaderMap& map, void CefRequestImpl::SetHeaderMap(const HeaderMap& map,
WebKit::WebURLRequest& request) { blink::WebURLRequest& request) {
HeaderMap::const_iterator it = map.begin(); HeaderMap::const_iterator it = map.begin();
for (; it != map.end(); ++it) for (; it != map.end(); ++it)
request.setHTTPHeaderField(string16(it->first), string16(it->second)); request.setHTTPHeaderField(string16(it->first), string16(it->second));
@ -547,12 +547,12 @@ net::UploadDataStream* CefPostDataImpl::Get() {
return new net::UploadDataStream(element_readers.Pass(), 0); return new net::UploadDataStream(element_readers.Pass(), 0);
} }
void CefPostDataImpl::Set(const WebKit::WebHTTPBody& data) { void CefPostDataImpl::Set(const blink::WebHTTPBody& data) {
AutoLock lock_scope(this); AutoLock lock_scope(this);
CHECK_READONLY_RETURN_VOID(); CHECK_READONLY_RETURN_VOID();
CefRefPtr<CefPostDataElement> postelem; CefRefPtr<CefPostDataElement> postelem;
WebKit::WebHTTPBody::Element element; blink::WebHTTPBody::Element element;
size_t size = data.elementCount(); size_t size = data.elementCount();
for (size_t i = 0; i < size; ++i) { for (size_t i = 0; i < size; ++i) {
if (data.elementAt(i, element)) { if (data.elementAt(i, element)) {
@ -563,16 +563,16 @@ void CefPostDataImpl::Set(const WebKit::WebHTTPBody& data) {
} }
} }
void CefPostDataImpl::Get(WebKit::WebHTTPBody& data) { void CefPostDataImpl::Get(blink::WebHTTPBody& data) {
AutoLock lock_scope(this); AutoLock lock_scope(this);
WebKit::WebHTTPBody::Element element; blink::WebHTTPBody::Element element;
ElementVector::iterator it = elements_.begin(); ElementVector::iterator it = elements_.begin();
for (; it != elements_.end(); ++it) { for (; it != elements_.end(); ++it) {
static_cast<CefPostDataElementImpl*>(it->get())->Get(element); static_cast<CefPostDataElementImpl*>(it->get())->Get(element);
if (element.type == WebKit::WebHTTPBody::Element::TypeData) { if (element.type == blink::WebHTTPBody::Element::TypeData) {
data.appendData(element.data); data.appendData(element.data);
} else if (element.type == WebKit::WebHTTPBody::Element::TypeFile) { } else if (element.type == blink::WebHTTPBody::Element::TypeFile) {
data.appendFile(element.filePath); data.appendFile(element.filePath);
} else { } else {
NOTREACHED(); NOTREACHED();
@ -759,29 +759,29 @@ net::UploadElementReader* CefPostDataElementImpl::Get() {
} }
} }
void CefPostDataElementImpl::Set(const WebKit::WebHTTPBody::Element& element) { void CefPostDataElementImpl::Set(const blink::WebHTTPBody::Element& element) {
AutoLock lock_scope(this); AutoLock lock_scope(this);
CHECK_READONLY_RETURN_VOID(); CHECK_READONLY_RETURN_VOID();
if (element.type == WebKit::WebHTTPBody::Element::TypeData) { if (element.type == blink::WebHTTPBody::Element::TypeData) {
SetToBytes(element.data.size(), SetToBytes(element.data.size(),
static_cast<const void*>(element.data.data())); static_cast<const void*>(element.data.data()));
} else if (element.type == WebKit::WebHTTPBody::Element::TypeFile) { } else if (element.type == blink::WebHTTPBody::Element::TypeFile) {
SetToFile(string16(element.filePath)); SetToFile(string16(element.filePath));
} else { } else {
NOTREACHED(); NOTREACHED();
} }
} }
void CefPostDataElementImpl::Get(WebKit::WebHTTPBody::Element& element) { void CefPostDataElementImpl::Get(blink::WebHTTPBody::Element& element) {
AutoLock lock_scope(this); AutoLock lock_scope(this);
if (type_ == PDE_TYPE_BYTES) { if (type_ == PDE_TYPE_BYTES) {
element.type = WebKit::WebHTTPBody::Element::TypeData; element.type = blink::WebHTTPBody::Element::TypeData;
element.data.assign( element.data.assign(
static_cast<char*>(data_.bytes.bytes), data_.bytes.size); static_cast<char*>(data_.bytes.bytes), data_.bytes.size);
} else if (type_ == PDE_TYPE_FILE) { } else if (type_ == PDE_TYPE_FILE) {
element.type = WebKit::WebHTTPBody::Element::TypeFile; element.type = blink::WebHTTPBody::Element::TypeFile;
element.filePath.assign(string16(CefString(&data_.filename))); element.filePath.assign(string16(CefString(&data_.filename)));
} else { } else {
NOTREACHED(); NOTREACHED();

View File

@ -18,7 +18,7 @@ class UploadElementReader;
class URLRequest; class URLRequest;
}; };
namespace WebKit { namespace blink {
class WebURLRequest; class WebURLRequest;
} }
@ -55,19 +55,19 @@ class CefRequestImpl : public CefRequest {
void Get(net::URLRequest* request); void Get(net::URLRequest* request);
// Populate this object from a WebURLRequest object. // Populate this object from a WebURLRequest object.
void Set(const WebKit::WebURLRequest& request); void Set(const blink::WebURLRequest& request);
// Populate the WebURLRequest object from this object. // Populate the WebURLRequest object from this object.
void Get(WebKit::WebURLRequest& request); void Get(blink::WebURLRequest& request);
void SetReadOnly(bool read_only); void SetReadOnly(bool read_only);
static void GetHeaderMap(const net::HttpRequestHeaders& headers, static void GetHeaderMap(const net::HttpRequestHeaders& headers,
HeaderMap& map); HeaderMap& map);
static void GetHeaderMap(const WebKit::WebURLRequest& request, static void GetHeaderMap(const blink::WebURLRequest& request,
HeaderMap& map); HeaderMap& map);
static void SetHeaderMap(const HeaderMap& map, static void SetHeaderMap(const HeaderMap& map,
WebKit::WebURLRequest& request); blink::WebURLRequest& request);
protected: protected:
CefString url_; CefString url_;
@ -105,8 +105,8 @@ class CefPostDataImpl : public CefPostData {
void Set(const net::UploadDataStream& data_stream); void Set(const net::UploadDataStream& data_stream);
void Get(net::UploadData& data); void Get(net::UploadData& data);
net::UploadDataStream* Get(); net::UploadDataStream* Get();
void Set(const WebKit::WebHTTPBody& data); void Set(const blink::WebHTTPBody& data);
void Get(WebKit::WebHTTPBody& data); void Get(blink::WebHTTPBody& data);
void SetReadOnly(bool read_only); void SetReadOnly(bool read_only);
@ -141,8 +141,8 @@ class CefPostDataElementImpl : public CefPostDataElement {
void Set(const net::UploadElementReader& element_reader); void Set(const net::UploadElementReader& element_reader);
void Get(net::UploadElement& element); void Get(net::UploadElement& element);
net::UploadElementReader* Get(); net::UploadElementReader* Get();
void Set(const WebKit::WebHTTPBody::Element& element); void Set(const blink::WebHTTPBody::Element& element);
void Get(WebKit::WebHTTPBody::Element& element); void Get(blink::WebHTTPBody::Element& element);
void SetReadOnly(bool read_only); void SetReadOnly(bool read_only);

View File

@ -168,25 +168,25 @@ void CefResponseImpl::SetResponseHeaders(
mime_type_ = mime_type; mime_type_ = mime_type;
} }
void CefResponseImpl::Set(const WebKit::WebURLResponse& response) { void CefResponseImpl::Set(const blink::WebURLResponse& response) {
DCHECK(!response.isNull()); DCHECK(!response.isNull());
AutoLock lock_scope(this); AutoLock lock_scope(this);
CHECK_READONLY_RETURN_VOID(); CHECK_READONLY_RETURN_VOID();
WebKit::WebString str; blink::WebString str;
status_code_ = response.httpStatusCode(); status_code_ = response.httpStatusCode();
str = response.httpStatusText(); str = response.httpStatusText();
status_text_ = CefString(str); status_text_ = CefString(str);
str = response.mimeType(); str = response.mimeType();
mime_type_ = CefString(str); mime_type_ = CefString(str);
class HeaderVisitor : public WebKit::WebHTTPHeaderVisitor { class HeaderVisitor : public blink::WebHTTPHeaderVisitor {
public: public:
explicit HeaderVisitor(HeaderMap* map) : map_(map) {} explicit HeaderVisitor(HeaderMap* map) : map_(map) {}
virtual void visitHeader(const WebKit::WebString& name, virtual void visitHeader(const blink::WebString& name,
const WebKit::WebString& value) { const blink::WebString& value) {
map_->insert(std::make_pair(string16(name), string16(value))); map_->insert(std::make_pair(string16(name), string16(value)));
} }

View File

@ -12,7 +12,7 @@ namespace net {
class HttpResponseHeaders; class HttpResponseHeaders;
} }
namespace WebKit { namespace blink {
class WebURLResponse; class WebURLResponse;
} }
@ -37,7 +37,7 @@ class CefResponseImpl : public CefResponse {
net::HttpResponseHeaders* GetResponseHeaders(); net::HttpResponseHeaders* GetResponseHeaders();
void SetResponseHeaders(const net::HttpResponseHeaders& headers); void SetResponseHeaders(const net::HttpResponseHeaders& headers);
void Set(const WebKit::WebURLResponse& response); void Set(const blink::WebURLResponse& response);
void SetReadOnly(bool read_only); void SetReadOnly(bool read_only);

View File

@ -39,17 +39,17 @@
#include "third_party/WebKit/public/web/WebView.h" #include "third_party/WebKit/public/web/WebView.h"
#include "webkit/glue/webkit_glue.h" #include "webkit/glue/webkit_glue.h"
using WebKit::WebFrame; using blink::WebFrame;
using WebKit::WebScriptSource; using blink::WebScriptSource;
using WebKit::WebString; using blink::WebString;
using WebKit::WebURL; using blink::WebURL;
using WebKit::WebView; using blink::WebView;
namespace { namespace {
const int64 kInvalidFrameId = -1; const int64 kInvalidFrameId = -1;
WebKit::WebString FilePathStringToWebString( blink::WebString FilePathStringToWebString(
const base::FilePath::StringType& str) { const base::FilePath::StringType& str) {
#if defined(OS_POSIX) #if defined(OS_POSIX)
return WideToUTF16Hack(base::SysNativeMBToWide(str)); return WideToUTF16Hack(base::SysNativeMBToWide(str));
@ -72,7 +72,7 @@ CefRefPtr<CefBrowserImpl> CefBrowserImpl::GetBrowserForView(
// static // static
CefRefPtr<CefBrowserImpl> CefBrowserImpl::GetBrowserForMainFrame( CefRefPtr<CefBrowserImpl> CefBrowserImpl::GetBrowserForMainFrame(
WebKit::WebFrame* frame) { blink::WebFrame* frame) {
return CefContentRendererClient::Get()->GetBrowserForMainFrame(frame); return CefContentRendererClient::Get()->GetBrowserForMainFrame(frame);
} }
@ -290,7 +290,7 @@ void CefBrowserImpl::LoadRequest(const CefMsg_LoadRequest_Params& params) {
WebFrame* web_frame = framePtr->web_frame(); WebFrame* web_frame = framePtr->web_frame();
WebKit::WebURLRequest request(params.url); blink::WebURLRequest request(params.url);
// DidCreateDataSource checks for this value. // DidCreateDataSource checks for this value.
request.setRequestorID(-1); request.setRequestorID(-1);
@ -299,8 +299,8 @@ void CefBrowserImpl::LoadRequest(const CefMsg_LoadRequest_Params& params) {
request.setHTTPMethod(ASCIIToUTF16(params.method)); request.setHTTPMethod(ASCIIToUTF16(params.method));
if (params.referrer.is_valid()) { if (params.referrer.is_valid()) {
WebString referrer = WebKit::WebSecurityPolicy::generateReferrerHeader( WebString referrer = blink::WebSecurityPolicy::generateReferrerHeader(
static_cast<WebKit::WebReferrerPolicy>(params.referrer_policy), static_cast<blink::WebReferrerPolicy>(params.referrer_policy),
params.url, params.url,
WebString::fromUTF8(params.referrer.spec())); WebString::fromUTF8(params.referrer.spec()));
if (!referrer.isEmpty()) if (!referrer.isEmpty())
@ -330,7 +330,7 @@ void CefBrowserImpl::LoadRequest(const CefMsg_LoadRequest_Params& params) {
ASCIIToUTF16("application/x-www-form-urlencoded")); ASCIIToUTF16("application/x-www-form-urlencoded"));
} }
WebKit::WebHTTPBody body; blink::WebHTTPBody body;
body.initialize(); body.initialize();
const ScopedVector<net::UploadElement>& elements = const ScopedVector<net::UploadElement>& elements =
@ -340,7 +340,7 @@ void CefBrowserImpl::LoadRequest(const CefMsg_LoadRequest_Params& params) {
for (; it != elements.end(); ++it) { for (; it != elements.end(); ++it) {
const net::UploadElement& element = **it; const net::UploadElement& element = **it;
if (element.type() == net::UploadElement::TYPE_BYTES) { if (element.type() == net::UploadElement::TYPE_BYTES) {
WebKit::WebData data; blink::WebData data;
data.assign(element.bytes(), element.bytes_length()); data.assign(element.bytes(), element.bytes_length());
body.appendData(data); body.appendData(data);
} else if (element.type() == net::UploadElement::TYPE_FILE) { } else if (element.type() == net::UploadElement::TYPE_FILE) {
@ -376,7 +376,7 @@ bool CefBrowserImpl::SendProcessMessage(CefProcessId target_process,
} }
CefRefPtr<CefFrameImpl> CefBrowserImpl::GetWebFrameImpl( CefRefPtr<CefFrameImpl> CefBrowserImpl::GetWebFrameImpl(
WebKit::WebFrame* frame) { blink::WebFrame* frame) {
DCHECK(frame); DCHECK(frame);
int64 frame_id = frame->identifier(); int64 frame_id = frame->identifier();
@ -478,14 +478,14 @@ void CefBrowserImpl::DidStopLoading() {
} }
void CefBrowserImpl::DidFailLoad( void CefBrowserImpl::DidFailLoad(
WebKit::WebFrame* frame, blink::WebFrame* frame,
const WebKit::WebURLError& error) { const blink::WebURLError& error) {
OnLoadError(frame, error); OnLoadError(frame, error);
OnLoadEnd(frame); OnLoadEnd(frame);
} }
void CefBrowserImpl::DidFinishLoad(WebKit::WebFrame* frame) { void CefBrowserImpl::DidFinishLoad(blink::WebFrame* frame) {
WebKit::WebDataSource* ds = frame->dataSource(); blink::WebDataSource* ds = frame->dataSource();
Send(new CefHostMsg_DidFinishLoad(routing_id(), Send(new CefHostMsg_DidFinishLoad(routing_id(),
frame->identifier(), frame->identifier(),
ds->request().url(), ds->request().url(),
@ -494,18 +494,18 @@ void CefBrowserImpl::DidFinishLoad(WebKit::WebFrame* frame) {
OnLoadEnd(frame); OnLoadEnd(frame);
} }
void CefBrowserImpl::DidStartProvisionalLoad(WebKit::WebFrame* frame) { void CefBrowserImpl::DidStartProvisionalLoad(blink::WebFrame* frame) {
// Send the frame creation notification if necessary. // Send the frame creation notification if necessary.
GetWebFrameImpl(frame); GetWebFrameImpl(frame);
} }
void CefBrowserImpl::DidFailProvisionalLoad( void CefBrowserImpl::DidFailProvisionalLoad(
WebKit::WebFrame* frame, blink::WebFrame* frame,
const WebKit::WebURLError& error) { const blink::WebURLError& error) {
OnLoadError(frame, error); OnLoadError(frame, error);
} }
void CefBrowserImpl::DidCommitProvisionalLoad(WebKit::WebFrame* frame, void CefBrowserImpl::DidCommitProvisionalLoad(blink::WebFrame* frame,
bool is_new_navigation) { bool is_new_navigation) {
OnLoadStart(frame); OnLoadStart(frame);
} }
@ -533,7 +533,7 @@ void CefBrowserImpl::FrameDetached(WebFrame* frame) {
Send(new CefHostMsg_FrameDetached(routing_id(), frame_id)); Send(new CefHostMsg_FrameDetached(routing_id(), frame_id));
} }
void CefBrowserImpl::FocusedNodeChanged(const WebKit::WebNode& node) { void CefBrowserImpl::FocusedNodeChanged(const blink::WebNode& node) {
// Notify the handler. // Notify the handler.
CefRefPtr<CefApp> app = CefContentClient::Get()->application(); CefRefPtr<CefApp> app = CefContentClient::Get()->application();
if (app.get()) { if (app.get()) {
@ -543,9 +543,9 @@ void CefBrowserImpl::FocusedNodeChanged(const WebKit::WebNode& node) {
if (node.isNull()) { if (node.isNull()) {
handler->OnFocusedNodeChanged(this, GetFocusedFrame(), NULL); handler->OnFocusedNodeChanged(this, GetFocusedFrame(), NULL);
} else { } else {
const WebKit::WebDocument& document = node.document(); const blink::WebDocument& document = node.document();
if (!document.isNull()) { if (!document.isNull()) {
WebKit::WebFrame* frame = document.frame(); blink::WebFrame* frame = document.frame();
CefRefPtr<CefDOMDocumentImpl> documentImpl = CefRefPtr<CefDOMDocumentImpl> documentImpl =
new CefDOMDocumentImpl(this, frame); new CefDOMDocumentImpl(this, frame);
handler->OnFocusedNodeChanged(this, handler->OnFocusedNodeChanged(this,
@ -565,7 +565,7 @@ void CefBrowserImpl::FocusedNodeChanged(const WebKit::WebNode& node) {
// Try to identify the focused frame from the node. // Try to identify the focused frame from the node.
if (!node.isNull()) { if (!node.isNull()) {
const WebKit::WebDocument& document = node.document(); const blink::WebDocument& document = node.document();
if (!document.isNull()) if (!document.isNull())
focused_frame = document.frame(); focused_frame = document.frame();
} }
@ -587,9 +587,9 @@ void CefBrowserImpl::FocusedNodeChanged(const WebKit::WebNode& node) {
Send(new CefHostMsg_FrameFocusChange(routing_id(), frame_id)); Send(new CefHostMsg_FrameFocusChange(routing_id(), frame_id));
} }
void CefBrowserImpl::DidCreateDataSource(WebKit::WebFrame* frame, void CefBrowserImpl::DidCreateDataSource(blink::WebFrame* frame,
WebKit::WebDataSource* ds) { blink::WebDataSource* ds) {
const WebKit::WebURLRequest& request = ds->request(); const blink::WebURLRequest& request = ds->request();
if (request.requestorID() == -1) { if (request.requestorID() == -1) {
// Mark the request as browser-initiated so // Mark the request as browser-initiated so
// RenderViewImpl::decidePolicyForNavigation won't attempt to fork it. // RenderViewImpl::decidePolicyForNavigation won't attempt to fork it.
@ -770,7 +770,7 @@ void CefBrowserImpl::OnLoadingStateChange(bool isLoading) {
} }
} }
void CefBrowserImpl::OnLoadStart(WebKit::WebFrame* frame) { void CefBrowserImpl::OnLoadStart(blink::WebFrame* frame) {
if (is_swapped_out()) if (is_swapped_out())
return; return;
@ -788,7 +788,7 @@ void CefBrowserImpl::OnLoadStart(WebKit::WebFrame* frame) {
} }
} }
void CefBrowserImpl::OnLoadEnd(WebKit::WebFrame* frame) { void CefBrowserImpl::OnLoadEnd(blink::WebFrame* frame) {
if (is_swapped_out()) if (is_swapped_out())
return; return;
@ -807,8 +807,8 @@ void CefBrowserImpl::OnLoadEnd(WebKit::WebFrame* frame) {
} }
} }
void CefBrowserImpl::OnLoadError(WebKit::WebFrame* frame, void CefBrowserImpl::OnLoadError(blink::WebFrame* frame,
const WebKit::WebURLError& error) { const blink::WebURLError& error) {
if (is_swapped_out()) if (is_swapped_out())
return; return;

View File

@ -30,7 +30,7 @@ namespace base {
class ListValue; class ListValue;
} }
namespace WebKit { namespace blink {
class WebFrame; class WebFrame;
} }
@ -50,7 +50,7 @@ class CefBrowserImpl : public CefBrowser,
static CefRefPtr<CefBrowserImpl> GetBrowserForView(content::RenderView* view); static CefRefPtr<CefBrowserImpl> GetBrowserForView(content::RenderView* view);
// Returns the browser associated with the specified main WebFrame. // Returns the browser associated with the specified main WebFrame.
static CefRefPtr<CefBrowserImpl> GetBrowserForMainFrame( static CefRefPtr<CefBrowserImpl> GetBrowserForMainFrame(
WebKit::WebFrame* frame); blink::WebFrame* frame);
// CefBrowser methods. // CefBrowser methods.
virtual CefRefPtr<CefBrowserHost> GetHost() OVERRIDE; virtual CefRefPtr<CefBrowserHost> GetHost() OVERRIDE;
@ -92,7 +92,7 @@ class CefBrowserImpl : public CefBrowser,
bool user_initiated); bool user_initiated);
// Returns the matching CefFrameImpl reference or creates a new one. // Returns the matching CefFrameImpl reference or creates a new one.
CefRefPtr<CefFrameImpl> GetWebFrameImpl(WebKit::WebFrame* frame); CefRefPtr<CefFrameImpl> GetWebFrameImpl(blink::WebFrame* frame);
CefRefPtr<CefFrameImpl> GetWebFrameImpl(int64 frame_id); CefRefPtr<CefFrameImpl> GetWebFrameImpl(int64 frame_id);
// Frame objects will be deleted immediately before the frame is closed. // Frame objects will be deleted immediately before the frame is closed.
@ -114,19 +114,19 @@ class CefBrowserImpl : public CefBrowser,
virtual void OnDestruct() OVERRIDE; virtual void OnDestruct() OVERRIDE;
virtual void DidStartLoading() OVERRIDE; virtual void DidStartLoading() OVERRIDE;
virtual void DidStopLoading() OVERRIDE; virtual void DidStopLoading() OVERRIDE;
virtual void DidFailLoad(WebKit::WebFrame* frame, virtual void DidFailLoad(blink::WebFrame* frame,
const WebKit::WebURLError& error) OVERRIDE; const blink::WebURLError& error) OVERRIDE;
virtual void DidFinishLoad(WebKit::WebFrame* frame) OVERRIDE; virtual void DidFinishLoad(blink::WebFrame* frame) OVERRIDE;
virtual void DidStartProvisionalLoad(WebKit::WebFrame* frame) OVERRIDE; virtual void DidStartProvisionalLoad(blink::WebFrame* frame) OVERRIDE;
virtual void DidFailProvisionalLoad( virtual void DidFailProvisionalLoad(
WebKit::WebFrame* frame, blink::WebFrame* frame,
const WebKit::WebURLError& error) OVERRIDE; const blink::WebURLError& error) OVERRIDE;
virtual void DidCommitProvisionalLoad(WebKit::WebFrame* frame, virtual void DidCommitProvisionalLoad(blink::WebFrame* frame,
bool is_new_navigation) OVERRIDE; bool is_new_navigation) OVERRIDE;
virtual void FrameDetached(WebKit::WebFrame* frame) OVERRIDE; virtual void FrameDetached(blink::WebFrame* frame) OVERRIDE;
virtual void FocusedNodeChanged(const WebKit::WebNode& node) OVERRIDE; virtual void FocusedNodeChanged(const blink::WebNode& node) OVERRIDE;
virtual void DidCreateDataSource(WebKit::WebFrame* frame, virtual void DidCreateDataSource(blink::WebFrame* frame,
WebKit::WebDataSource* ds) OVERRIDE; blink::WebDataSource* ds) OVERRIDE;
virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
// RenderViewObserver::OnMessageReceived message handlers. // RenderViewObserver::OnMessageReceived message handlers.
@ -135,9 +135,9 @@ class CefBrowserImpl : public CefBrowser,
void OnResponseAck(int request_id); void OnResponseAck(int request_id);
void OnLoadingStateChange(bool isLoading); void OnLoadingStateChange(bool isLoading);
void OnLoadStart(WebKit::WebFrame* frame); void OnLoadStart(blink::WebFrame* frame);
void OnLoadEnd(WebKit::WebFrame* frame); void OnLoadEnd(blink::WebFrame* frame);
void OnLoadError(WebKit::WebFrame* frame, const WebKit::WebURLError& error); void OnLoadError(blink::WebFrame* frame, const blink::WebURLError& error);
// ID of the browser that this RenderView is associated with. During loading // ID of the browser that this RenderView is associated with. During loading
// of cross-origin requests multiple RenderViews may be associated with the // of cross-origin requests multiple RenderViews may be associated with the

View File

@ -60,20 +60,20 @@ MSVC_POP_WARNING();
namespace { namespace {
// Stub implementation of WebKit::WebPrerenderingSupport. // Stub implementation of blink::WebPrerenderingSupport.
class CefPrerenderingSupport : public WebKit::WebPrerenderingSupport { class CefPrerenderingSupport : public blink::WebPrerenderingSupport {
public: public:
virtual ~CefPrerenderingSupport() {} virtual ~CefPrerenderingSupport() {}
private: private:
virtual void add(const WebKit::WebPrerender& prerender) OVERRIDE {} virtual void add(const blink::WebPrerender& prerender) OVERRIDE {}
virtual void cancel(const WebKit::WebPrerender& prerender) OVERRIDE {} virtual void cancel(const blink::WebPrerender& prerender) OVERRIDE {}
virtual void abandon(const WebKit::WebPrerender& prerender) OVERRIDE {} virtual void abandon(const blink::WebPrerender& prerender) OVERRIDE {}
}; };
// Stub implementation of WebKit::WebPrerendererClient. // Stub implementation of blink::WebPrerendererClient.
class CefPrerendererClient : public content::RenderViewObserver, class CefPrerendererClient : public content::RenderViewObserver,
public WebKit::WebPrerendererClient { public blink::WebPrerendererClient {
public: public:
explicit CefPrerendererClient(content::RenderView* render_view) explicit CefPrerendererClient(content::RenderView* render_view)
: content::RenderViewObserver(render_view) { : content::RenderViewObserver(render_view) {
@ -84,7 +84,7 @@ class CefPrerendererClient : public content::RenderViewObserver,
private: private:
virtual ~CefPrerendererClient() {} virtual ~CefPrerendererClient() {}
virtual void willAddPrerender(WebKit::WebPrerender* prerender) OVERRIDE {} virtual void willAddPrerender(blink::WebPrerender* prerender) OVERRIDE {}
}; };
// Implementation of SequencedTaskRunner for WebWorker threads. // Implementation of SequencedTaskRunner for WebWorker threads.
@ -163,7 +163,7 @@ CefRefPtr<CefBrowserImpl> CefContentRendererClient::GetBrowserForView(
} }
CefRefPtr<CefBrowserImpl> CefContentRendererClient::GetBrowserForMainFrame( CefRefPtr<CefBrowserImpl> CefContentRendererClient::GetBrowserForMainFrame(
WebKit::WebFrame* frame) { blink::WebFrame* frame) {
CEF_REQUIRE_RT_RETURN(NULL); CEF_REQUIRE_RT_RETURN(NULL);
BrowserMap::const_iterator it = browsers_.begin(); BrowserMap::const_iterator it = browsers_.begin();
@ -194,15 +194,15 @@ void CefContentRendererClient::OnBrowserDestroyed(CefBrowserImpl* browser) {
void CefContentRendererClient::WebKitInitialized() { void CefContentRendererClient::WebKitInitialized() {
const CommandLine& command_line = *CommandLine::ForCurrentProcess(); const CommandLine& command_line = *CommandLine::ForCurrentProcess();
WebKit::WebRuntimeFeatures::enableMediaPlayer( blink::WebRuntimeFeatures::enableMediaPlayer(
media::IsMediaLibraryInitialized()); media::IsMediaLibraryInitialized());
// TODO(cef): Enable these once the implementation supports it. // TODO(cef): Enable these once the implementation supports it.
WebKit::WebRuntimeFeatures::enableNotifications(false); blink::WebRuntimeFeatures::enableNotifications(false);
WebKit::WebRuntimeFeatures::enableSpeechInput( blink::WebRuntimeFeatures::enableSpeechInput(
command_line.HasSwitch(switches::kEnableSpeechInput)); command_line.HasSwitch(switches::kEnableSpeechInput));
WebKit::WebRuntimeFeatures::enableMediaStream( blink::WebRuntimeFeatures::enableMediaStream(
command_line.HasSwitch(switches::kEnableMediaStream)); command_line.HasSwitch(switches::kEnableMediaStream));
const CefContentClient::SchemeInfoList* schemes = const CefContentClient::SchemeInfoList* schemes =
@ -212,17 +212,17 @@ void CefContentRendererClient::WebKitInitialized() {
CefContentClient::SchemeInfoList::const_iterator it = schemes->begin(); CefContentClient::SchemeInfoList::const_iterator it = schemes->begin();
for (; it != schemes->end(); ++it) { for (; it != schemes->end(); ++it) {
const CefContentClient::SchemeInfo& info = *it; const CefContentClient::SchemeInfo& info = *it;
const WebKit::WebString& scheme = const blink::WebString& scheme =
WebKit::WebString::fromUTF8(info.scheme_name); blink::WebString::fromUTF8(info.scheme_name);
if (info.is_standard) { if (info.is_standard) {
// Standard schemes must also be registered as CORS enabled to support // Standard schemes must also be registered as CORS enabled to support
// CORS-restricted requests (for example, XMLHttpRequest redirects). // CORS-restricted requests (for example, XMLHttpRequest redirects).
WebKit::WebSecurityPolicy::registerURLSchemeAsCORSEnabled(scheme); blink::WebSecurityPolicy::registerURLSchemeAsCORSEnabled(scheme);
} }
if (info.is_local) if (info.is_local)
WebKit::WebSecurityPolicy::registerURLSchemeAsLocal(scheme); blink::WebSecurityPolicy::registerURLSchemeAsLocal(scheme);
if (info.is_display_isolated) if (info.is_display_isolated)
WebKit::WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(scheme); blink::WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(scheme);
} }
} }
@ -232,10 +232,10 @@ void CefContentRendererClient::WebKitInitialized() {
const Cef_CrossOriginWhiteListEntry_Params& entry = const Cef_CrossOriginWhiteListEntry_Params& entry =
cross_origin_whitelist_entries_[i]; cross_origin_whitelist_entries_[i];
GURL gurl = GURL(entry.source_origin); GURL gurl = GURL(entry.source_origin);
WebKit::WebSecurityPolicy::addOriginAccessWhitelistEntry( blink::WebSecurityPolicy::addOriginAccessWhitelistEntry(
gurl, gurl,
WebKit::WebString::fromUTF8(entry.target_protocol), blink::WebString::fromUTF8(entry.target_protocol),
WebKit::WebString::fromUTF8(entry.target_domain), blink::WebString::fromUTF8(entry.target_domain),
entry.allow_target_subdomains); entry.allow_target_subdomains);
} }
cross_origin_whitelist_entries_.clear(); cross_origin_whitelist_entries_.clear();
@ -394,7 +394,7 @@ void CefContentRendererClient::RenderThreadStarted() {
if (!media_path.empty()) if (!media_path.empty())
media::InitializeMediaLibrary(media_path); media::InitializeMediaLibrary(media_path);
WebKit::WebPrerenderingSupport::initialize(new CefPrerenderingSupport()); blink::WebPrerenderingSupport::initialize(new CefPrerenderingSupport());
// Create global objects associated with the default Isolate. // Create global objects associated with the default Isolate.
CefV8IsolateCreated(); CefV8IsolateCreated();
@ -458,9 +458,9 @@ void CefContentRendererClient::RenderViewCreated(
bool CefContentRendererClient::OverrideCreatePlugin( bool CefContentRendererClient::OverrideCreatePlugin(
content::RenderView* render_view, content::RenderView* render_view,
WebKit::WebFrame* frame, blink::WebFrame* frame,
const WebKit::WebPluginParams& params, const blink::WebPluginParams& params,
WebKit::WebPlugin** plugin) { blink::WebPlugin** plugin) {
CefRefPtr<CefBrowserImpl> browser = CefRefPtr<CefBrowserImpl> browser =
CefBrowserImpl::GetBrowserForMainFrame(frame->top()); CefBrowserImpl::GetBrowserForMainFrame(frame->top());
if (!browser || !browser->is_window_rendering_disabled()) if (!browser || !browser->is_window_rendering_disabled())
@ -504,11 +504,11 @@ bool CefContentRendererClient::OverrideCreatePlugin(
if (flash || silverlight) { if (flash || silverlight) {
// Force Flash and Silverlight plugins to use windowless mode. // Force Flash and Silverlight plugins to use windowless mode.
WebKit::WebPluginParams params_to_use = params; blink::WebPluginParams params_to_use = params;
params_to_use.mimeType = WebKit::WebString::fromUTF8(mime_type); params_to_use.mimeType = blink::WebString::fromUTF8(mime_type);
size_t size = params.attributeNames.size(); size_t size = params.attributeNames.size();
WebKit::WebVector<WebKit::WebString> new_names(size+1), blink::WebVector<blink::WebString> new_names(size+1),
new_values(size+1); new_values(size+1);
for (size_t i = 0; i < size; ++i) { for (size_t i = 0; i < size; ++i) {
@ -536,7 +536,7 @@ bool CefContentRendererClient::OverrideCreatePlugin(
} }
void CefContentRendererClient::DidCreateScriptContext( void CefContentRendererClient::DidCreateScriptContext(
WebKit::WebFrame* frame, v8::Handle<v8::Context> context, blink::WebFrame* frame, v8::Handle<v8::Context> context,
int extension_group, int world_id) { int extension_group, int world_id) {
CefRefPtr<CefBrowserImpl> browserPtr = CefRefPtr<CefBrowserImpl> browserPtr =
CefBrowserImpl::GetBrowserForMainFrame(frame->top()); CefBrowserImpl::GetBrowserForMainFrame(frame->top());
@ -566,7 +566,7 @@ void CefContentRendererClient::DidCreateScriptContext(
} }
void CefContentRendererClient::WillReleaseScriptContext( void CefContentRendererClient::WillReleaseScriptContext(
WebKit::WebFrame* frame, v8::Handle<v8::Context> context, int world_id) { blink::WebFrame* frame, v8::Handle<v8::Context> context, int world_id) {
// Notify the render process handler. // Notify the render process handler.
CefRefPtr<CefApp> application = CefContentClient::Get()->application(); CefRefPtr<CefApp> application = CefContentClient::Get()->application();
if (application.get()) { if (application.get()) {

View File

@ -36,7 +36,7 @@ class CefContentRendererClient : public content::ContentRendererClient,
CefRefPtr<CefBrowserImpl> GetBrowserForView(content::RenderView* view); CefRefPtr<CefBrowserImpl> GetBrowserForView(content::RenderView* view);
// Returns the browser associated with the specified main WebFrame. // Returns the browser associated with the specified main WebFrame.
CefRefPtr<CefBrowserImpl> GetBrowserForMainFrame(WebKit::WebFrame* frame); CefRefPtr<CefBrowserImpl> GetBrowserForMainFrame(blink::WebFrame* frame);
// Called from CefBrowserImpl::OnDestruct(). // Called from CefBrowserImpl::OnDestruct().
void OnBrowserDestroyed(CefBrowserImpl* browser); void OnBrowserDestroyed(CefBrowserImpl* browser);
@ -78,14 +78,14 @@ class CefContentRendererClient : public content::ContentRendererClient,
virtual void RenderViewCreated(content::RenderView* render_view) OVERRIDE; virtual void RenderViewCreated(content::RenderView* render_view) OVERRIDE;
virtual bool OverrideCreatePlugin( virtual bool OverrideCreatePlugin(
content::RenderView* render_view, content::RenderView* render_view,
WebKit::WebFrame* frame, blink::WebFrame* frame,
const WebKit::WebPluginParams& params, const blink::WebPluginParams& params,
WebKit::WebPlugin** plugin) OVERRIDE; blink::WebPlugin** plugin) OVERRIDE;
virtual void DidCreateScriptContext(WebKit::WebFrame* frame, virtual void DidCreateScriptContext(blink::WebFrame* frame,
v8::Handle<v8::Context> context, v8::Handle<v8::Context> context,
int extension_group, int extension_group,
int world_id) OVERRIDE; int world_id) OVERRIDE;
virtual void WillReleaseScriptContext(WebKit::WebFrame* frame, virtual void WillReleaseScriptContext(blink::WebFrame* frame,
v8::Handle<v8::Context> context, v8::Handle<v8::Context> context,
int world_id) OVERRIDE; int world_id) OVERRIDE;

View File

@ -15,13 +15,13 @@
#include "third_party/WebKit/public/web/WebNode.h" #include "third_party/WebKit/public/web/WebNode.h"
#include "third_party/WebKit/public/web/WebRange.h" #include "third_party/WebKit/public/web/WebRange.h"
using WebKit::WebDocument; using blink::WebDocument;
using WebKit::WebElement; using blink::WebElement;
using WebKit::WebFrame; using blink::WebFrame;
using WebKit::WebNode; using blink::WebNode;
using WebKit::WebRange; using blink::WebRange;
using WebKit::WebString; using blink::WebString;
using WebKit::WebURL; using blink::WebURL;
CefDOMDocumentImpl::CefDOMDocumentImpl(CefBrowserImpl* browser, CefDOMDocumentImpl::CefDOMDocumentImpl(CefBrowserImpl* browser,
@ -199,7 +199,7 @@ CefString CefDOMDocumentImpl::GetCompleteURL(const CefString& partialURL) {
} }
CefRefPtr<CefDOMNode> CefDOMDocumentImpl::GetOrCreateNode( CefRefPtr<CefDOMNode> CefDOMDocumentImpl::GetOrCreateNode(
const WebKit::WebNode& node) { const blink::WebNode& node) {
if (!VerifyContext()) if (!VerifyContext())
return NULL; return NULL;
@ -220,7 +220,7 @@ CefRefPtr<CefDOMNode> CefDOMDocumentImpl::GetOrCreateNode(
return nodeImpl; return nodeImpl;
} }
void CefDOMDocumentImpl::RemoveNode(const WebKit::WebNode& node) { void CefDOMDocumentImpl::RemoveNode(const blink::WebNode& node) {
if (!VerifyContext()) if (!VerifyContext())
return; return;

View File

@ -9,7 +9,7 @@
#include <map> #include <map>
#include "include/cef_dom.h" #include "include/cef_dom.h"
namespace WebKit { namespace blink {
class WebFrame; class WebFrame;
class WebNode; class WebNode;
}; };
@ -19,7 +19,7 @@ class CefBrowserImpl;
class CefDOMDocumentImpl : public CefDOMDocument { class CefDOMDocumentImpl : public CefDOMDocument {
public: public:
CefDOMDocumentImpl(CefBrowserImpl* browser, CefDOMDocumentImpl(CefBrowserImpl* browser,
WebKit::WebFrame* frame); blink::WebFrame* frame);
virtual ~CefDOMDocumentImpl(); virtual ~CefDOMDocumentImpl();
// CefDOMDocument methods. // CefDOMDocument methods.
@ -41,11 +41,11 @@ class CefDOMDocumentImpl : public CefDOMDocument {
virtual CefString GetCompleteURL(const CefString& partialURL) OVERRIDE; virtual CefString GetCompleteURL(const CefString& partialURL) OVERRIDE;
CefBrowserImpl* GetBrowser() { return browser_; } CefBrowserImpl* GetBrowser() { return browser_; }
WebKit::WebFrame* GetFrame() { return frame_; } blink::WebFrame* GetFrame() { return frame_; }
// The document maintains a map of all existing node objects. // The document maintains a map of all existing node objects.
CefRefPtr<CefDOMNode> GetOrCreateNode(const WebKit::WebNode& node); CefRefPtr<CefDOMNode> GetOrCreateNode(const blink::WebNode& node);
void RemoveNode(const WebKit::WebNode& node); void RemoveNode(const blink::WebNode& node);
// Must be called before the object is destroyed. // Must be called before the object is destroyed.
void Detach(); void Detach();
@ -55,9 +55,9 @@ class CefDOMDocumentImpl : public CefDOMDocument {
protected: protected:
CefBrowserImpl* browser_; CefBrowserImpl* browser_;
WebKit::WebFrame* frame_; blink::WebFrame* frame_;
typedef std::map<WebKit::WebNode, CefDOMNode*> NodeMap; typedef std::map<blink::WebNode, CefDOMNode*> NodeMap;
NodeMap node_map_; NodeMap node_map_;
IMPLEMENT_REFCOUNTING(CefDOMDocumentImpl); IMPLEMENT_REFCOUNTING(CefDOMDocumentImpl);

View File

@ -10,12 +10,12 @@
#include "third_party/WebKit/public/platform/WebString.h" #include "third_party/WebKit/public/platform/WebString.h"
#include "third_party/WebKit/public/web/WebDOMEvent.h" #include "third_party/WebKit/public/web/WebDOMEvent.h"
using WebKit::WebDOMEvent; using blink::WebDOMEvent;
using WebKit::WebString; using blink::WebString;
CefDOMEventImpl::CefDOMEventImpl(CefRefPtr<CefDOMDocumentImpl> document, CefDOMEventImpl::CefDOMEventImpl(CefRefPtr<CefDOMDocumentImpl> document,
const WebKit::WebDOMEvent& event) const blink::WebDOMEvent& event)
: document_(document), : document_(document),
event_(event) { event_(event) {
DCHECK(!event_.isNull()); DCHECK(!event_.isNull());

View File

@ -14,7 +14,7 @@ class CefDOMDocumentImpl;
class CefDOMEventImpl : public CefDOMEvent { class CefDOMEventImpl : public CefDOMEvent {
public: public:
CefDOMEventImpl(CefRefPtr<CefDOMDocumentImpl> document, CefDOMEventImpl(CefRefPtr<CefDOMDocumentImpl> document,
const WebKit::WebDOMEvent& event); const blink::WebDOMEvent& event);
virtual ~CefDOMEventImpl(); virtual ~CefDOMEventImpl();
// CefDOMEvent methods. // CefDOMEvent methods.
@ -35,7 +35,7 @@ class CefDOMEventImpl : public CefDOMEvent {
protected: protected:
CefRefPtr<CefDOMDocumentImpl> document_; CefRefPtr<CefDOMDocumentImpl> document_;
WebKit::WebDOMEvent event_; blink::WebDOMEvent event_;
IMPLEMENT_REFCOUNTING(CefDOMEventImpl); IMPLEMENT_REFCOUNTING(CefDOMEventImpl);
}; };

View File

@ -24,16 +24,16 @@
#include "third_party/WebKit/public/web/WebNode.h" #include "third_party/WebKit/public/web/WebNode.h"
#include "third_party/WebKit/public/web/WebSelectElement.h" #include "third_party/WebKit/public/web/WebSelectElement.h"
using WebKit::WebDocument; using blink::WebDocument;
using WebKit::WebDOMEvent; using blink::WebDOMEvent;
using WebKit::WebDOMEventListener; using blink::WebDOMEventListener;
using WebKit::WebElement; using blink::WebElement;
using WebKit::WebFrame; using blink::WebFrame;
using WebKit::WebFormControlElement; using blink::WebFormControlElement;
using WebKit::WebInputElement; using blink::WebInputElement;
using WebKit::WebNode; using blink::WebNode;
using WebKit::WebSelectElement; using blink::WebSelectElement;
using WebKit::WebString; using blink::WebString;
namespace { namespace {
@ -85,7 +85,7 @@ class CefDOMEventListenerWrapper : public WebDOMEventListener,
CefDOMNodeImpl::CefDOMNodeImpl(CefRefPtr<CefDOMDocumentImpl> document, CefDOMNodeImpl::CefDOMNodeImpl(CefRefPtr<CefDOMDocumentImpl> document,
const WebKit::WebNode& node) const blink::WebNode& node)
: document_(document), : document_(document),
node_(node) { node_(node) {
} }
@ -359,7 +359,7 @@ CefString CefDOMNodeImpl::GetElementTagName() {
return str; return str;
} }
const WebElement& element = node_.toConst<WebKit::WebElement>(); const WebElement& element = node_.toConst<blink::WebElement>();
const WebString& tagname = element.tagName(); const WebString& tagname = element.tagName();
if (!tagname.isNull()) if (!tagname.isNull())
str = tagname; str = tagname;
@ -376,7 +376,7 @@ bool CefDOMNodeImpl::HasElementAttributes() {
return false; return false;
} }
const WebElement& element = node_.toConst<WebKit::WebElement>(); const WebElement& element = node_.toConst<blink::WebElement>();
return (element.attributeCount() > 0); return (element.attributeCount() > 0);
} }
@ -389,7 +389,7 @@ bool CefDOMNodeImpl::HasElementAttribute(const CefString& attrName) {
return false; return false;
} }
const WebElement& element = node_.toConst<WebKit::WebElement>(); const WebElement& element = node_.toConst<blink::WebElement>();
return element.hasAttribute(string16(attrName)); return element.hasAttribute(string16(attrName));
} }
@ -403,7 +403,7 @@ CefString CefDOMNodeImpl::GetElementAttribute(const CefString& attrName) {
return str; return str;
} }
const WebElement& element = node_.toConst<WebKit::WebElement>(); const WebElement& element = node_.toConst<blink::WebElement>();
const WebString& attr = element.getAttribute(string16(attrName)); const WebString& attr = element.getAttribute(string16(attrName));
if (!attr.isNull()) if (!attr.isNull())
str = attr; str = attr;
@ -420,7 +420,7 @@ void CefDOMNodeImpl::GetElementAttributes(AttributeMap& attrMap) {
return; return;
} }
const WebElement& element = node_.toConst<WebKit::WebElement>(); const WebElement& element = node_.toConst<blink::WebElement>();
unsigned int len = element.attributeCount(); unsigned int len = element.attributeCount();
if (len == 0) if (len == 0)
return; return;
@ -442,7 +442,7 @@ bool CefDOMNodeImpl::SetElementAttribute(const CefString& attrName,
return false; return false;
} }
WebElement element = node_.to<WebKit::WebElement>(); WebElement element = node_.to<blink::WebElement>();
return element.setAttribute(string16(attrName), string16(value)); return element.setAttribute(string16(attrName), string16(value));
} }
@ -456,7 +456,7 @@ CefString CefDOMNodeImpl::GetElementInnerText() {
return str; return str;
} }
WebElement element = node_.to<WebKit::WebElement>(); WebElement element = node_.to<blink::WebElement>();
const WebString& text = element.innerText(); const WebString& text = element.innerText();
if (!text.isNull()) if (!text.isNull())
str = text; str = text;

View File

@ -14,7 +14,7 @@ class CefDOMDocumentImpl;
class CefDOMNodeImpl : public CefDOMNode { class CefDOMNodeImpl : public CefDOMNode {
public: public:
CefDOMNodeImpl(CefRefPtr<CefDOMDocumentImpl> document, CefDOMNodeImpl(CefRefPtr<CefDOMDocumentImpl> document,
const WebKit::WebNode& node); const blink::WebNode& node);
virtual ~CefDOMNodeImpl(); virtual ~CefDOMNodeImpl();
// CefDOMNode methods. // CefDOMNode methods.
@ -56,7 +56,7 @@ class CefDOMNodeImpl : public CefDOMNode {
protected: protected:
CefRefPtr<CefDOMDocumentImpl> document_; CefRefPtr<CefDOMDocumentImpl> document_;
WebKit::WebNode node_; blink::WebNode node_;
IMPLEMENT_REFCOUNTING(CefDOMNodeImpl); IMPLEMENT_REFCOUNTING(CefDOMNodeImpl);
}; };

View File

@ -21,10 +21,10 @@
#include "third_party/WebKit/public/web/WebView.h" #include "third_party/WebKit/public/web/WebView.h"
#include "third_party/WebKit/public/web/WebScriptSource.h" #include "third_party/WebKit/public/web/WebScriptSource.h"
using WebKit::WebString; using blink::WebString;
CefFrameImpl::CefFrameImpl(CefBrowserImpl* browser, CefFrameImpl::CefFrameImpl(CefBrowserImpl* browser,
WebKit::WebFrame* frame) blink::WebFrame* frame)
: browser_(browser), : browser_(browser),
frame_(frame), frame_(frame),
frame_id_(frame->identifier()) { frame_id_(frame->identifier()) {
@ -170,7 +170,7 @@ void CefFrameImpl::ExecuteJavaScript(const CefString& jsCode,
if (frame_) { if (frame_) {
GURL gurl = GURL(scriptUrl.ToString()); GURL gurl = GURL(scriptUrl.ToString());
frame_->executeScript( frame_->executeScript(
WebKit::WebScriptSource(jsCode.ToString16(), gurl, startLine)); blink::WebScriptSource(jsCode.ToString16(), gurl, startLine));
} }
} }
@ -209,7 +209,7 @@ CefRefPtr<CefFrame> CefFrameImpl::GetParent() {
CEF_REQUIRE_RT_RETURN(NULL); CEF_REQUIRE_RT_RETURN(NULL);
if (frame_) { if (frame_) {
WebKit::WebFrame* parent = frame_->parent(); blink::WebFrame* parent = frame_->parent();
if (parent) if (parent)
return browser_->GetWebFrameImpl(parent).get(); return browser_->GetWebFrameImpl(parent).get();
} }
@ -254,7 +254,7 @@ void CefFrameImpl::VisitDOM(CefRefPtr<CefDOMVisitor> visitor) {
// Create a CefDOMDocumentImpl object that is valid only for the scope of this // Create a CefDOMDocumentImpl object that is valid only for the scope of this
// method. // method.
CefRefPtr<CefDOMDocumentImpl> documentImpl; CefRefPtr<CefDOMDocumentImpl> documentImpl;
const WebKit::WebDocument& document = frame_->document(); const blink::WebDocument& document = frame_->document();
if (!document.isNull()) if (!document.isNull())
documentImpl = new CefDOMDocumentImpl(browser_, frame_); documentImpl = new CefDOMDocumentImpl(browser_, frame_);

View File

@ -12,7 +12,7 @@
class CefBrowserImpl; class CefBrowserImpl;
namespace WebKit { namespace blink {
class WebFrame; class WebFrame;
} }
@ -22,7 +22,7 @@ class WebFrame;
class CefFrameImpl : public CefFrame { class CefFrameImpl : public CefFrame {
public: public:
CefFrameImpl(CefBrowserImpl* browser, CefFrameImpl(CefBrowserImpl* browser,
WebKit::WebFrame* frame); blink::WebFrame* frame);
virtual ~CefFrameImpl(); virtual ~CefFrameImpl();
// CefFrame implementation. // CefFrame implementation.
@ -56,11 +56,11 @@ class CefFrameImpl : public CefFrame {
void Detach(); void Detach();
WebKit::WebFrame* web_frame() const { return frame_; } blink::WebFrame* web_frame() const { return frame_; }
protected: protected:
CefBrowserImpl* browser_; CefBrowserImpl* browser_;
WebKit::WebFrame* frame_; blink::WebFrame* frame_;
int64 frame_id_; int64 frame_id_;
IMPLEMENT_REFCOUNTING(CefFrameImpl); IMPLEMENT_REFCOUNTING(CefFrameImpl);

View File

@ -46,20 +46,20 @@ void CefRenderProcessObserver::OnModifyCrossOriginWhitelistEntry(
const Cef_CrossOriginWhiteListEntry_Params& params) { const Cef_CrossOriginWhiteListEntry_Params& params) {
GURL gurl = GURL(params.source_origin); GURL gurl = GURL(params.source_origin);
if (add) { if (add) {
WebKit::WebSecurityPolicy::addOriginAccessWhitelistEntry( blink::WebSecurityPolicy::addOriginAccessWhitelistEntry(
gurl, gurl,
WebKit::WebString::fromUTF8(params.target_protocol), blink::WebString::fromUTF8(params.target_protocol),
WebKit::WebString::fromUTF8(params.target_domain), blink::WebString::fromUTF8(params.target_domain),
params.allow_target_subdomains); params.allow_target_subdomains);
} else { } else {
WebKit::WebSecurityPolicy::removeOriginAccessWhitelistEntry( blink::WebSecurityPolicy::removeOriginAccessWhitelistEntry(
gurl, gurl,
WebKit::WebString::fromUTF8(params.target_protocol), blink::WebString::fromUTF8(params.target_protocol),
WebKit::WebString::fromUTF8(params.target_domain), blink::WebString::fromUTF8(params.target_domain),
params.allow_target_subdomains); params.allow_target_subdomains);
} }
} }
void CefRenderProcessObserver::OnClearCrossOriginWhitelist() { void CefRenderProcessObserver::OnClearCrossOriginWhitelist() {
WebKit::WebSecurityPolicy::resetOriginAccessWhitelists(); blink::WebSecurityPolicy::resetOriginAccessWhitelists();
} }

View File

@ -17,23 +17,23 @@
#include "third_party/WebKit/public/platform/WebURLRequest.h" #include "third_party/WebKit/public/platform/WebURLRequest.h"
#include "third_party/WebKit/public/platform/WebURLResponse.h" #include "third_party/WebKit/public/platform/WebURLResponse.h"
using WebKit::WebString; using blink::WebString;
using WebKit::WebURL; using blink::WebURL;
using WebKit::WebURLError; using blink::WebURLError;
using WebKit::WebURLLoader; using blink::WebURLLoader;
using WebKit::WebURLRequest; using blink::WebURLRequest;
using WebKit::WebURLResponse; using blink::WebURLResponse;
namespace { namespace {
class CefWebURLLoaderClient : public WebKit::WebURLLoaderClient { class CefWebURLLoaderClient : public blink::WebURLLoaderClient {
public: public:
CefWebURLLoaderClient(CefRenderURLRequest::Context* context, CefWebURLLoaderClient(CefRenderURLRequest::Context* context,
int request_flags); int request_flags);
virtual ~CefWebURLLoaderClient(); virtual ~CefWebURLLoaderClient();
// WebKit::WebURLLoaderClient methods. // blink::WebURLLoaderClient methods.
virtual void willSendRequest( virtual void willSendRequest(
WebURLLoader* loader, WebURLLoader* loader,
WebURLRequest& newRequest, WebURLRequest& newRequest,
@ -105,7 +105,7 @@ class CefRenderURLRequest::Context
if (!url.is_valid()) if (!url.is_valid())
return false; return false;
loader_.reset(WebKit::Platform::current()->createURLLoader()); loader_.reset(blink::Platform::current()->createURLLoader());
url_client_.reset(new CefWebURLLoaderClient(this, request_->GetFlags())); url_client_.reset(new CefWebURLLoaderClient(this, request_->GetFlags()));
WebURLRequest urlRequest; WebURLRequest urlRequest;
@ -235,7 +235,7 @@ class CefRenderURLRequest::Context
CefURLRequest::Status status_; CefURLRequest::Status status_;
CefURLRequest::ErrorCode error_code_; CefURLRequest::ErrorCode error_code_;
CefRefPtr<CefResponse> response_; CefRefPtr<CefResponse> response_;
scoped_ptr<WebKit::WebURLLoader> loader_; scoped_ptr<blink::WebURLLoader> loader_;
scoped_ptr<CefWebURLLoaderClient> url_client_; scoped_ptr<CefWebURLLoaderClient> url_client_;
int64 upload_data_size_; int64 upload_data_size_;
bool got_upload_progress_complete_; bool got_upload_progress_complete_;

View File

@ -872,7 +872,7 @@ CefRefPtr<CefBrowser> CefV8ContextImpl::GetBrowser() {
if (!CEF_CURRENTLY_ON_RT()) if (!CEF_CURRENTLY_ON_RT())
return browser; return browser;
WebKit::WebFrame* webframe = GetWebFrame(); blink::WebFrame* webframe = GetWebFrame();
if (webframe) if (webframe)
browser = CefBrowserImpl::GetBrowserForMainFrame(webframe->top()); browser = CefBrowserImpl::GetBrowserForMainFrame(webframe->top());
@ -887,7 +887,7 @@ CefRefPtr<CefFrame> CefV8ContextImpl::GetFrame() {
if (!CEF_CURRENTLY_ON_RT()) if (!CEF_CURRENTLY_ON_RT())
return frame; return frame;
WebKit::WebFrame* webframe = GetWebFrame(); blink::WebFrame* webframe = GetWebFrame();
if (webframe) { if (webframe) {
CefRefPtr<CefBrowserImpl> browser = CefRefPtr<CefBrowserImpl> browser =
CefBrowserImpl::GetBrowserForMainFrame(webframe->top()); CefBrowserImpl::GetBrowserForMainFrame(webframe->top());
@ -989,11 +989,11 @@ v8::Handle<v8::Context> CefV8ContextImpl::GetV8Context() {
return handle_->GetNewV8Handle(); return handle_->GetNewV8Handle();
} }
WebKit::WebFrame* CefV8ContextImpl::GetWebFrame() { blink::WebFrame* CefV8ContextImpl::GetWebFrame() {
CEF_REQUIRE_RT(); CEF_REQUIRE_RT();
v8::HandleScope handle_scope(handle_->isolate()); v8::HandleScope handle_scope(handle_->isolate());
v8::Context::Scope context_scope(GetV8Context()); v8::Context::Scope context_scope(GetV8Context());
WebKit::WebFrame* frame = WebKit::WebFrame::frameForCurrentContext(); blink::WebFrame* frame = blink::WebFrame::frameForCurrentContext();
return frame; return frame;
} }

View File

@ -20,7 +20,7 @@
class CefTrackNode; class CefTrackNode;
class GURL; class GURL;
namespace WebKit { namespace blink {
class WebFrame; class WebFrame;
}; };
@ -175,7 +175,7 @@ class CefV8ContextImpl : public CefV8Context {
CefRefPtr<CefV8Exception>& exception) OVERRIDE; CefRefPtr<CefV8Exception>& exception) OVERRIDE;
v8::Handle<v8::Context> GetV8Context(); v8::Handle<v8::Context> GetV8Context();
WebKit::WebFrame* GetWebFrame(); blink::WebFrame* GetWebFrame();
protected: protected:
typedef CefV8Handle<v8::Context> Handle; typedef CefV8Handle<v8::Context> Handle;

View File

@ -37,57 +37,57 @@ MSVC_POP_WARNING();
namespace webkit_glue { namespace webkit_glue {
bool CanGoBack(WebKit::WebView* view) { bool CanGoBack(blink::WebView* view) {
if (!view) if (!view)
return false; return false;
WebKit::WebViewImpl* impl = reinterpret_cast<WebKit::WebViewImpl*>(view); blink::WebViewImpl* impl = reinterpret_cast<blink::WebViewImpl*>(view);
return (impl->client()->historyBackListCount() > 0); return (impl->client()->historyBackListCount() > 0);
} }
bool CanGoForward(WebKit::WebView* view) { bool CanGoForward(blink::WebView* view) {
if (!view) if (!view)
return false; return false;
WebKit::WebViewImpl* impl = reinterpret_cast<WebKit::WebViewImpl*>(view); blink::WebViewImpl* impl = reinterpret_cast<blink::WebViewImpl*>(view);
return (impl->client()->historyForwardListCount() > 0); return (impl->client()->historyForwardListCount() > 0);
} }
void GoBack(WebKit::WebView* view) { void GoBack(blink::WebView* view) {
if (!view) if (!view)
return; return;
WebKit::WebViewImpl* impl = reinterpret_cast<WebKit::WebViewImpl*>(view); blink::WebViewImpl* impl = reinterpret_cast<blink::WebViewImpl*>(view);
if (impl->client()->historyBackListCount() > 0) if (impl->client()->historyBackListCount() > 0)
impl->client()->navigateBackForwardSoon(-1); impl->client()->navigateBackForwardSoon(-1);
} }
void GoForward(WebKit::WebView* view) { void GoForward(blink::WebView* view) {
if (!view) if (!view)
return; return;
WebKit::WebViewImpl* impl = reinterpret_cast<WebKit::WebViewImpl*>(view); blink::WebViewImpl* impl = reinterpret_cast<blink::WebViewImpl*>(view);
if (impl->client()->historyForwardListCount() > 0) if (impl->client()->historyForwardListCount() > 0)
impl->client()->navigateBackForwardSoon(1); impl->client()->navigateBackForwardSoon(1);
} }
v8::Isolate* GetV8Isolate(WebKit::WebFrame* frame) { v8::Isolate* GetV8Isolate(blink::WebFrame* frame) {
WebKit::WebFrameImpl* impl = static_cast<WebKit::WebFrameImpl*>(frame); blink::WebFrameImpl* impl = static_cast<blink::WebFrameImpl*>(frame);
return WebCore::toIsolate(impl->frame()); return WebCore::toIsolate(impl->frame());
} }
v8::Handle<v8::Context> GetV8Context(WebKit::WebFrame* frame) { v8::Handle<v8::Context> GetV8Context(blink::WebFrame* frame) {
WebKit::WebFrameImpl* impl = static_cast<WebKit::WebFrameImpl*>(frame); blink::WebFrameImpl* impl = static_cast<blink::WebFrameImpl*>(frame);
return WebCore::ScriptController::mainWorldContext(impl->frame()); return WebCore::ScriptController::mainWorldContext(impl->frame());
} }
std::string DumpDocumentText(WebKit::WebFrame* frame) { std::string DumpDocumentText(blink::WebFrame* frame) {
// We use the document element's text instead of the body text here because // We use the document element's text instead of the body text here because
// not all documents have a body, such as XML documents. // not all documents have a body, such as XML documents.
WebKit::WebElement document_element = frame->document().documentElement(); blink::WebElement document_element = frame->document().documentElement();
if (document_element.isNull()) if (document_element.isNull())
return std::string(); return std::string();
return document_element.innerText().utf8(); return document_element.innerText().utf8();
} }
bool SetNodeValue(WebKit::WebNode& node, const WebKit::WebString& value) { bool SetNodeValue(blink::WebNode& node, const blink::WebString& value) {
WebCore::Node* web_node = node.unwrap<WebCore::Node>(); WebCore::Node* web_node = node.unwrap<WebCore::Node>();
web_node->setNodeValue(value); web_node->setNodeValue(value);
return true; return true;

View File

@ -14,7 +14,7 @@ template <class T> class Handle;
class Isolate; class Isolate;
} }
namespace WebKit { namespace blink {
class WebFrame; class WebFrame;
class WebNode; class WebNode;
class WebString; class WebString;
@ -23,21 +23,21 @@ class WebView;
namespace webkit_glue { namespace webkit_glue {
bool CanGoBack(WebKit::WebView* view); bool CanGoBack(blink::WebView* view);
bool CanGoForward(WebKit::WebView* view); bool CanGoForward(blink::WebView* view);
void GoBack(WebKit::WebView* view); void GoBack(blink::WebView* view);
void GoForward(WebKit::WebView* view); void GoForward(blink::WebView* view);
// Retrieve the V8 isolate associated with the frame. // Retrieve the V8 isolate associated with the frame.
v8::Isolate* GetV8Isolate(WebKit::WebFrame* frame); v8::Isolate* GetV8Isolate(blink::WebFrame* frame);
// Retrieve the V8 context associated with the frame. // Retrieve the V8 context associated with the frame.
v8::Handle<v8::Context> GetV8Context(WebKit::WebFrame* frame); v8::Handle<v8::Context> GetV8Context(blink::WebFrame* frame);
// Returns the text of the document element. // Returns the text of the document element.
std::string DumpDocumentText(WebKit::WebFrame* frame); std::string DumpDocumentText(blink::WebFrame* frame);
bool SetNodeValue(WebKit::WebNode& node, const WebKit::WebString& value); bool SetNodeValue(blink::WebNode& node, const blink::WebString& value);
} // webkit_glue } // webkit_glue

View File

@ -1,8 +1,8 @@
Index: message_loop.cc Index: message_loop.cc
=================================================================== ===================================================================
--- message_loop.cc (revision 224845) --- message_loop.cc (revision 233896)
+++ message_loop.cc (working copy) +++ message_loop.cc (working copy)
@@ -201,7 +201,7 @@ @@ -208,7 +208,7 @@
MessageLoop::~MessageLoop() { MessageLoop::~MessageLoop() {
DCHECK_EQ(this, current()); DCHECK_EQ(this, current());

View File

@ -1,8 +1,8 @@
Index: frame/FrameView.cpp Index: frame/FrameView.cpp
=================================================================== ===================================================================
--- frame/FrameView.cpp (revision 160715) --- frame/FrameView.cpp (revision 161588)
+++ frame/FrameView.cpp (working copy) +++ frame/FrameView.cpp (working copy)
@@ -200,8 +200,10 @@ @@ -201,8 +201,10 @@
if (!isMainFrame()) if (!isMainFrame())
return; return;
@ -15,7 +15,7 @@ Index: frame/FrameView.cpp
PassRefPtr<FrameView> FrameView::create(Frame* frame) PassRefPtr<FrameView> FrameView::create(Frame* frame)
Index: platform/mac/NSScrollerImpDetails.mm Index: platform/mac/NSScrollerImpDetails.mm
=================================================================== ===================================================================
--- platform/mac/NSScrollerImpDetails.mm (revision 160715) --- platform/mac/NSScrollerImpDetails.mm (revision 161588)
+++ platform/mac/NSScrollerImpDetails.mm (working copy) +++ platform/mac/NSScrollerImpDetails.mm (working copy)
@@ -73,10 +73,14 @@ @@ -73,10 +73,14 @@

View File

@ -1,8 +1,8 @@
Index: public/web/WebView.h Index: public/web/WebView.h
=================================================================== ===================================================================
--- public/web/WebView.h (revision 160715) --- public/web/WebView.h (revision 161588)
+++ public/web/WebView.h (working copy) +++ public/web/WebView.h (working copy)
@@ -441,6 +441,7 @@ @@ -443,6 +443,7 @@
// Sets whether select popup menus should be rendered by the browser. // Sets whether select popup menus should be rendered by the browser.
BLINK_EXPORT static void setUseExternalPopupMenus(bool); BLINK_EXPORT static void setUseExternalPopupMenus(bool);
@ -12,7 +12,7 @@ Index: public/web/WebView.h
// Visited link state -------------------------------------------------- // Visited link state --------------------------------------------------
Index: Source/web/ChromeClientImpl.cpp Index: Source/web/ChromeClientImpl.cpp
=================================================================== ===================================================================
--- Source/web/ChromeClientImpl.cpp (revision 160715) --- Source/web/ChromeClientImpl.cpp (revision 161588)
+++ Source/web/ChromeClientImpl.cpp (working copy) +++ Source/web/ChromeClientImpl.cpp (working copy)
@@ -871,7 +871,7 @@ @@ -871,7 +871,7 @@
@ -25,9 +25,9 @@ Index: Source/web/ChromeClientImpl.cpp
return adoptRef(new PopupMenuChromium(frame, client)); return adoptRef(new PopupMenuChromium(frame, client));
Index: Source/web/WebViewImpl.cpp Index: Source/web/WebViewImpl.cpp
=================================================================== ===================================================================
--- Source/web/WebViewImpl.cpp (revision 160715) --- Source/web/WebViewImpl.cpp (revision 161588)
+++ Source/web/WebViewImpl.cpp (working copy) +++ Source/web/WebViewImpl.cpp (working copy)
@@ -402,6 +402,7 @@ @@ -403,6 +403,7 @@
, m_fakePageScaleAnimationPageScaleFactor(0) , m_fakePageScaleAnimationPageScaleFactor(0)
, m_fakePageScaleAnimationUseAnchor(false) , m_fakePageScaleAnimationUseAnchor(false)
, m_contextMenuAllowed(false) , m_contextMenuAllowed(false)
@ -35,7 +35,7 @@ Index: Source/web/WebViewImpl.cpp
, m_doingDragAndDrop(false) , m_doingDragAndDrop(false)
, m_ignoreInputEvents(false) , m_ignoreInputEvents(false)
, m_compositorDeviceScaleFactorOverride(0) , m_compositorDeviceScaleFactorOverride(0)
@@ -3643,9 +3644,14 @@ @@ -3714,9 +3715,14 @@
updateLayerTreeViewport(); updateLayerTreeViewport();
} }
@ -53,9 +53,9 @@ Index: Source/web/WebViewImpl.cpp
void WebViewImpl::startDragging(Frame* frame, void WebViewImpl::startDragging(Frame* frame,
Index: Source/web/WebViewImpl.h Index: Source/web/WebViewImpl.h
=================================================================== ===================================================================
--- Source/web/WebViewImpl.h (revision 160715) --- Source/web/WebViewImpl.h (revision 161588)
+++ Source/web/WebViewImpl.h (working copy) +++ Source/web/WebViewImpl.h (working copy)
@@ -409,7 +409,8 @@ @@ -414,7 +414,8 @@
// Returns true if popup menus should be rendered by the browser, false if // Returns true if popup menus should be rendered by the browser, false if
// they should be rendered by WebKit (which is the default). // they should be rendered by WebKit (which is the default).
@ -65,7 +65,7 @@ Index: Source/web/WebViewImpl.h
bool contextMenuAllowed() const bool contextMenuAllowed() const
{ {
@@ -702,6 +703,8 @@ @@ -710,6 +711,8 @@
bool m_contextMenuAllowed; bool m_contextMenuAllowed;

18
tools/gyp_cef.py Normal file
View File

@ -0,0 +1,18 @@
# Copyright (c) 2013 The Chromium Embedded Framework Authors.
# Portions copyright 2012 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.
# This file is (possibly, depending on python version) imported by gyp_cef
# when it creates sub-processes through the multiprocessing library.
# Importing in Python 2.6 (fixed in 2.7) on Windows doesn't search for
# imports that don't end in .py (and aren't directories with an
# __init__.py). This wrapper makes "import gyp_cef" work with those old
# versions and makes it possible to execute gyp_cef.py directly on Windows
# where the extension is useful.
import os
path = os.path.abspath(os.path.split(__file__)[0])
execfile(os.path.join(path, 'gyp_cef'))