summaryrefslogtreecommitdiffstats
path: root/webkit/tools/test_shell/mac
diff options
context:
space:
mode:
authoravi@google.com <avi@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-16 16:42:57 +0000
committeravi@google.com <avi@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-16 16:42:57 +0000
commitf4fe0c4f4b2a0172bb30a4f9d5bf567beca2412d (patch)
tree6e3a4bdc2b739aa64f13858c987c5611c8abcc8d /webkit/tools/test_shell/mac
parent0a834f0fcc61d47efbeebad65c050c26afbf477c (diff)
downloadchromium_src-f4fe0c4f4b2a0172bb30a4f9d5bf567beca2412d.zip
chromium_src-f4fe0c4f4b2a0172bb30a4f9d5bf567beca2412d.tar.gz
chromium_src-f4fe0c4f4b2a0172bb30a4f9d5bf567beca2412d.tar.bz2
Add one more function; tweak since "HWND" isn't really a window...
Review URL: http://codereview.chromium.org/2894 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2263 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/tools/test_shell/mac')
-rw-r--r--webkit/tools/test_shell/mac/test_webview_delegate.mm11
1 files changed, 10 insertions, 1 deletions
diff --git a/webkit/tools/test_shell/mac/test_webview_delegate.mm b/webkit/tools/test_shell/mac/test_webview_delegate.mm
index 746835e..6c8dc75 100644
--- a/webkit/tools/test_shell/mac/test_webview_delegate.mm
+++ b/webkit/tools/test_shell/mac/test_webview_delegate.mm
@@ -679,7 +679,7 @@ void TestWebViewDelegate::GetWindowRect(WebWidget* webwidget,
DCHECK(out_rect);
if (WebWidgetHost* host = GetHostForWidget(webwidget)) {
NSView *view = host->window_handle();
- NSRect rect = [[[view window] contentView] frame];
+ NSRect rect = [view frame];
*out_rect = gfx::Rect(NSRectToCGRect(rect));
}
}
@@ -695,6 +695,15 @@ void TestWebViewDelegate::SetWindowRect(WebWidget* webwidget,
}
}
+void TestWebViewDelegate::GetRootWindowRect(WebWidget* webwidget,
+ gfx::Rect* out_rect) {
+ if (WebWidgetHost* host = GetHostForWidget(webwidget)) {
+ NSView *view = host->window_handle();
+ NSRect rect = [[[view window] contentView] frame];
+ *out_rect = gfx::Rect(NSRectToCGRect(rect));
+ }
+}
+
void TestWebViewDelegate::DidMove(WebWidget* webwidget,
const WebPluginGeometry& move) {
// TODO: uncomment when Mac plugins are working