diff options
author | oshima@chromium.org <oshima@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-19 19:17:04 +0000 |
---|---|---|
committer | oshima@chromium.org <oshima@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-19 19:17:04 +0000 |
commit | e2f64d101a1e624bf300f598fea6c336db64f4a2 (patch) | |
tree | 9cd0c6a963f1152e2a1ec0667df1242a38fb627b /content | |
parent | 7f1a51c32f9c8c5a44118483c1255328d7983fce (diff) | |
download | chromium_src-e2f64d101a1e624bf300f598fea6c336db64f4a2.zip chromium_src-e2f64d101a1e624bf300f598fea6c336db64f4a2.tar.gz chromium_src-e2f64d101a1e624bf300f598fea6c336db64f4a2.tar.bz2 |
Rename bounds accessors to be intuitive and consistent
GetClientAreaScreenBounds -> GetClientAreaBoundsInScreen
Get/Set ParentBounds -> Get/Set BoundsInParent
GetWorkAreaScreenBounds -> GetWorkAreaBoundsInScreen
GetClientAreaScreenBounds -> GetClientAreaBoundsInScreen
GetWindowScreenBounds -> GetWindowBoundsInScreen
GetScreenBounds -> GetBoundsInScreen
GetRootWindowBounds -> GetBoundsInRootWindow
BUG=none
TEST=none
Review URL: https://chromiumcodereview.appspot.com/10795013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@147499 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
13 files changed, 18 insertions, 18 deletions
diff --git a/content/browser/renderer_host/render_widget_host_impl.cc b/content/browser/renderer_host/render_widget_host_impl.cc index c9aa3ce..5ddb42d 100644 --- a/content/browser/renderer_host/render_widget_host_impl.cc +++ b/content/browser/renderer_host/render_widget_host_impl.cc @@ -1629,9 +1629,9 @@ void RenderWidgetHostImpl::OnMsgGetWindowRect(gfx::NativeViewId window_id, } void RenderWidgetHostImpl::OnMsgGetRootWindowRect(gfx::NativeViewId window_id, - gfx::Rect* results) { + gfx::Rect* results) { if (view_) - *results = view_->GetRootWindowBounds(); + *results = view_->GetBoundsInRootWindow(); } #endif diff --git a/content/browser/renderer_host/render_widget_host_view_android.cc b/content/browser/renderer_host/render_widget_host_view_android.cc index 4a89189..960dfda 100644 --- a/content/browser/renderer_host/render_widget_host_view_android.cc +++ b/content/browser/renderer_host/render_widget_host_view_android.cc @@ -296,7 +296,7 @@ void RenderWidgetHostViewAndroid::GetScreenInfo(WebKit::WebScreenInfo* result) { // TODO(jrg): Find out the implications and answer correctly here, // as we are returning the WebView and not root window bounds. -gfx::Rect RenderWidgetHostViewAndroid::GetRootWindowBounds() { +gfx::Rect RenderWidgetHostViewAndroid::GetBoundsInRootWindow() { return GetViewBounds(); } diff --git a/content/browser/renderer_host/render_widget_host_view_android.h b/content/browser/renderer_host/render_widget_host_view_android.h index d3fbfc5..0d1fd41 100644 --- a/content/browser/renderer_host/render_widget_host_view_android.h +++ b/content/browser/renderer_host/render_widget_host_view_android.h @@ -89,7 +89,7 @@ class RenderWidgetHostViewAndroid : public RenderWidgetHostViewBase { virtual BackingStore* AllocBackingStore(const gfx::Size& size) OVERRIDE; virtual gfx::GLSurfaceHandle GetCompositingSurface() OVERRIDE; virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE; - virtual gfx::Rect GetRootWindowBounds() OVERRIDE; + virtual gfx::Rect GetBoundsInRootWindow() OVERRIDE; virtual void UnhandledWheelEvent( const WebKit::WebMouseWheelEvent& event) OVERRIDE; virtual void ProcessTouchAck(WebKit::WebInputEvent::Type type, diff --git a/content/browser/renderer_host/render_widget_host_view_aura.cc b/content/browser/renderer_host/render_widget_host_view_aura.cc index 40b2e96..141a759 100644 --- a/content/browser/renderer_host/render_widget_host_view_aura.cc +++ b/content/browser/renderer_host/render_widget_host_view_aura.cc @@ -343,7 +343,7 @@ bool RenderWidgetHostViewAura::IsShowing() { } gfx::Rect RenderWidgetHostViewAura::GetViewBounds() const { - return window_->GetRootWindowBounds(); + return window_->GetBoundsInRootWindow(); } void RenderWidgetHostViewAura::UpdateCursor(const WebCursor& cursor) { @@ -703,8 +703,8 @@ void RenderWidgetHostViewAura::GetScreenInfo(WebKit::WebScreenInfo* results) { GetScreenInfoForWindow(results, window_); } -gfx::Rect RenderWidgetHostViewAura::GetRootWindowBounds() { - return window_->GetToplevelWindow()->bounds(); +gfx::Rect RenderWidgetHostViewAura::GetBoundsInRootWindow() { + return window_->GetToplevelWindow()->GetBoundsInRootWindow(); } void RenderWidgetHostViewAura::ProcessTouchAck( diff --git a/content/browser/renderer_host/render_widget_host_view_aura.h b/content/browser/renderer_host/render_widget_host_view_aura.h index ab76b06..2aea3b5 100644 --- a/content/browser/renderer_host/render_widget_host_view_aura.h +++ b/content/browser/renderer_host/render_widget_host_view_aura.h @@ -116,7 +116,7 @@ class RenderWidgetHostViewAura uint64 surface_id) OVERRIDE; virtual void AcceleratedSurfaceRelease(uint64 surface_id) OVERRIDE; virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE; - virtual gfx::Rect GetRootWindowBounds() OVERRIDE; + virtual gfx::Rect GetBoundsInRootWindow() OVERRIDE; virtual void ProcessTouchAck(WebKit::WebInputEvent::Type type, bool processed) OVERRIDE; virtual void SetHasHorizontalScrollbar( diff --git a/content/browser/renderer_host/render_widget_host_view_gtk.cc b/content/browser/renderer_host/render_widget_host_view_gtk.cc index d32bf0e..91763dd 100644 --- a/content/browser/renderer_host/render_widget_host_view_gtk.cc +++ b/content/browser/renderer_host/render_widget_host_view_gtk.cc @@ -1274,7 +1274,7 @@ void RenderWidgetHostViewGtk::GetScreenInfo(WebKit::WebScreenInfo* results) { content::GetScreenInfoFromNativeWindow(gdk_window, results); } -gfx::Rect RenderWidgetHostViewGtk::GetRootWindowBounds() { +gfx::Rect RenderWidgetHostViewGtk::GetBoundsInRootWindow() { GtkWidget* toplevel = gtk_widget_get_toplevel(view_.get()); if (!toplevel) return gfx::Rect(); diff --git a/content/browser/renderer_host/render_widget_host_view_gtk.h b/content/browser/renderer_host/render_widget_host_view_gtk.h index 8d2b357..e41af81 100644 --- a/content/browser/renderer_host/render_widget_host_view_gtk.h +++ b/content/browser/renderer_host/render_widget_host_view_gtk.h @@ -120,7 +120,7 @@ class CONTENT_EXPORT RenderWidgetHostViewGtk virtual void SetScrollOffsetPinning( bool is_pinned_to_left, bool is_pinned_to_right) OVERRIDE; virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE; - virtual gfx::Rect GetRootWindowBounds() OVERRIDE; + virtual gfx::Rect GetBoundsInRootWindow() OVERRIDE; virtual gfx::GLSurfaceHandle GetCompositingSurface() OVERRIDE; virtual bool LockMouse() OVERRIDE; virtual void UnlockMouse() OVERRIDE; diff --git a/content/browser/renderer_host/render_widget_host_view_mac.h b/content/browser/renderer_host/render_widget_host_view_mac.h index a47e848..3598480 100644 --- a/content/browser/renderer_host/render_widget_host_view_mac.h +++ b/content/browser/renderer_host/render_widget_host_view_mac.h @@ -288,7 +288,7 @@ class RenderWidgetHostViewMac : public content::RenderWidgetHostViewBase { virtual bool HasAcceleratedSurface(const gfx::Size& desired_size) OVERRIDE; virtual void AboutToWaitForBackingStoreMsg() OVERRIDE; virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE; - virtual gfx::Rect GetRootWindowBounds() OVERRIDE; + virtual gfx::Rect GetBoundsInRootWindow() OVERRIDE; virtual gfx::GLSurfaceHandle GetCompositingSurface() OVERRIDE; void DrawAcceleratedSurfaceInstance( diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm index 4492222..60b5def 100644 --- a/content/browser/renderer_host/render_widget_host_view_mac.mm +++ b/content/browser/renderer_host/render_widget_host_view_mac.mm @@ -1111,7 +1111,7 @@ void RenderWidgetHostViewMac::GetScreenInfo(WebKit::WebScreenInfo* results) { *results = WebKit::WebScreenInfoFactory::screenInfo(GetNativeView()); } -gfx::Rect RenderWidgetHostViewMac::GetRootWindowBounds() { +gfx::Rect RenderWidgetHostViewMac::GetBoundsInRootWindow() { // TODO(shess): In case of !window, the view has been removed from // the view hierarchy because the tab isn't main. Could retrieve // the information from the main tab for our window. @@ -1257,7 +1257,7 @@ void RenderWidgetHostViewMac::SetWindowVisibility(bool visible) { void RenderWidgetHostViewMac::WindowFrameChanged() { if (render_widget_host_) { render_widget_host_->Send(new ViewMsg_WindowFrameChanged( - render_widget_host_->GetRoutingID(), GetRootWindowBounds(), + render_widget_host_->GetRoutingID(), GetBoundsInRootWindow(), GetViewBounds())); } } diff --git a/content/browser/renderer_host/test_render_view_host.cc b/content/browser/renderer_host/test_render_view_host.cc index 047b153..7c2165f 100644 --- a/content/browser/renderer_host/test_render_view_host.cc +++ b/content/browser/renderer_host/test_render_view_host.cc @@ -183,7 +183,7 @@ void TestRenderWidgetHostView::StartContentIntent(const GURL&) {} #endif #if defined(OS_POSIX) || defined(USE_AURA) -gfx::Rect TestRenderWidgetHostView::GetRootWindowBounds() { +gfx::Rect TestRenderWidgetHostView::GetBoundsInRootWindow() { return gfx::Rect(); } #endif diff --git a/content/browser/renderer_host/test_render_view_host.h b/content/browser/renderer_host/test_render_view_host.h index 444a834..e851d3d 100644 --- a/content/browser/renderer_host/test_render_view_host.h +++ b/content/browser/renderer_host/test_render_view_host.h @@ -137,7 +137,7 @@ class TestRenderWidgetHostView : public RenderWidgetHostViewBase { #endif #if defined(OS_POSIX) || defined(USE_AURA) virtual void GetScreenInfo(WebKit::WebScreenInfo* results) OVERRIDE {} - virtual gfx::Rect GetRootWindowBounds() OVERRIDE; + virtual gfx::Rect GetBoundsInRootWindow() OVERRIDE; #endif virtual void ProcessTouchAck(WebKit::WebInputEvent::Type type, bool processed) OVERRIDE { } diff --git a/content/browser/web_contents/web_contents_view_aura.cc b/content/browser/web_contents/web_contents_view_aura.cc index 21b82af..072c00c 100644 --- a/content/browser/web_contents/web_contents_view_aura.cc +++ b/content/browser/web_contents/web_contents_view_aura.cc @@ -304,7 +304,7 @@ gfx::NativeWindow WebContentsViewAura::GetTopLevelNativeWindow() const { } void WebContentsViewAura::GetContainerBounds(gfx::Rect *out) const { - *out = window_->GetScreenBounds(); + *out = window_->GetBoundsInScreen(); } void WebContentsViewAura::SetPageTitle(const string16& title) { @@ -398,7 +398,7 @@ void WebContentsViewAura::CloseTabAfterEventTracking() { } gfx::Rect WebContentsViewAura::GetViewBounds() const { - return window_->GetRootWindowBounds(); + return window_->GetBoundsInRootWindow(); } //////////////////////////////////////////////////////////////////////////////// diff --git a/content/port/browser/render_widget_host_view_port.h b/content/port/browser/render_widget_host_view_port.h index da4b7c4..12fc721 100644 --- a/content/port/browser/render_widget_host_view_port.h +++ b/content/port/browser/render_widget_host_view_port.h @@ -237,7 +237,7 @@ class CONTENT_EXPORT RenderWidgetHostViewPort : public RenderWidgetHostView { static void GetDefaultScreenInfo( WebKit::WebScreenInfo* results); virtual void GetScreenInfo(WebKit::WebScreenInfo* results) = 0; - virtual gfx::Rect GetRootWindowBounds() = 0; + virtual gfx::Rect GetBoundsInRootWindow() = 0; #endif virtual gfx::GLSurfaceHandle GetCompositingSurface() = 0; |