summaryrefslogtreecommitdiffstats
path: root/chrome/renderer/render_widget.cc
diff options
context:
space:
mode:
authorerg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-08-28 18:36:37 +0000
committererg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-08-28 18:36:37 +0000
commitd454745055f7ec8c6b5fc158c61f66452d39aabf (patch)
tree73395f7721bd5a23886a30afcab4ece31d88d866 /chrome/renderer/render_widget.cc
parent917543feedad73ad36a410413f9a5edc8b2e2c27 (diff)
downloadchromium_src-d454745055f7ec8c6b5fc158c61f66452d39aabf.zip
chromium_src-d454745055f7ec8c6b5fc158c61f66452d39aabf.tar.gz
chromium_src-d454745055f7ec8c6b5fc158c61f66452d39aabf.tar.bz2
The GetWindowRect must return the rect of the container HWND; not the actual window rect. The usage of GetWindowRect in the ChromeClientImpl::windowRect() function is erroneous, and my modification of GetWindowRect to return the HWND's root ancestor rect broke drop down combo boxes and other embeded controls.
So instead, add a GetRootWindowRect which gets the root anncestor of the HWND's rect and use it in ChromeClientImpl::windowRect(). BUG=1344367,1186573,1334505 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1496 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer/render_widget.cc')
-rw-r--r--chrome/renderer/render_widget.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/chrome/renderer/render_widget.cc b/chrome/renderer/render_widget.cc
index c25b9be..95b1050 100644
--- a/chrome/renderer/render_widget.cc
+++ b/chrome/renderer/render_widget.cc
@@ -639,6 +639,10 @@ void RenderWidget::SetWindowRect(WebWidget* webwidget, const gfx::Rect& pos) {
}
}
+void RenderWidget::GetRootWindowRect(WebWidget* webwidget, gfx::Rect* rect) {
+ Send(new ViewHostMsg_GetRootWindowRect(routing_id_, host_window_, rect));
+}
+
void RenderWidget::OnImeSetInputMode(bool is_active) {
// A renderer process may move its input focus and the caret position
// while a browser process stop receiving IPC messages.
@@ -749,4 +753,3 @@ void RenderWidget::DidMove(WebWidget* webwidget,
if (i == plugin_window_moves_.size())
plugin_window_moves_.push_back(move);
}
-