Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(69)

Unified Diff: chrome/browser/views/hwnd_html_view.cc

Issue 99042: Fix several painting glitches for toolstrips. (Closed)
Patch Set: Review responses Created 11 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/views/hwnd_html_view.h ('k') | webkit/glue/webview_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/views/hwnd_html_view.cc
diff --git a/chrome/browser/views/hwnd_html_view.cc b/chrome/browser/views/hwnd_html_view.cc
index a0174d6f04e619049909189d584f31cdcfb1c52d..d51c259b8d12d5673c76b69bfed392dccb95aa4b 100644
--- a/chrome/browser/views/hwnd_html_view.cc
+++ b/chrome/browser/views/hwnd_html_view.cc
@@ -32,6 +32,27 @@ HWNDHtmlView::~HWNDHtmlView() {
}
}
+void HWNDHtmlView::SetVisible(bool is_visible) {
+ HWNDView::SetVisible(is_visible);
+
+ // Also tell RenderWidgetHostView the new visibility. Despite its name, it is
+ // not part of the View heirarchy and does not know about the change unless we
+ // tell it.
+ if (render_view_host() && render_view_host()->view()) {
+ if (is_visible)
+ render_view_host()->view()->Show();
+ else
+ render_view_host()->view()->Hide();
+ }
+}
+
+void HWNDHtmlView::DidChangeBounds(const gfx::Rect& previous,
+ const gfx::Rect& current) {
+ // Propagate the new size to RenderWidgetHostView.
+ if (render_view_host() && render_view_host()->view() && !current.IsEmpty())
Erik does not do reviews 2009/04/27 19:47:30 I still think this isn't the correct final fix (bu
+ render_view_host()->view()->SetSize(gfx::Size(width(), height()));
+}
+
void HWNDHtmlView::SetBackground(const SkBitmap& background) {
if (initialized_) {
DCHECK(render_view_host_);
« no previous file with comments | « chrome/browser/views/hwnd_html_view.h ('k') | webkit/glue/webview_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698