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

Unified Diff: content/browser/renderer_host/legacy_render_widget_host_win.cc

Issue 1295683003: Remove the CHECK from the DirectManipulationHelper::Activate function as it is firing in Canary on … (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address sky review comments Created 5 years, 4 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 | « content/browser/renderer_host/legacy_render_widget_host_win.h ('k') | ui/gfx/win/direct_manipulation.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/legacy_render_widget_host_win.cc
diff --git a/content/browser/renderer_host/legacy_render_widget_host_win.cc b/content/browser/renderer_host/legacy_render_widget_host_win.cc
index 8dcdaf63c98cd899bbae46fbbcb7a77e848774ce..c04d108b9218e6191a6cb6d4126efd63a4589a97 100644
--- a/content/browser/renderer_host/legacy_render_widget_host_win.cc
+++ b/content/browser/renderer_host/legacy_render_widget_host_win.cc
@@ -76,8 +76,6 @@ HWND LegacyRenderWidgetHostHWND::GetParent() {
void LegacyRenderWidgetHostHWND::Show() {
::ShowWindow(hwnd(), SW_SHOW);
- if (direct_manipulation_helper_)
- direct_manipulation_helper_->Activate(hwnd());
}
void LegacyRenderWidgetHostHWND::Hide() {
@@ -397,4 +395,18 @@ LRESULT LegacyRenderWidgetHostHWND::OnSize(UINT message,
return 0;
}
+LRESULT LegacyRenderWidgetHostHWND::OnWindowPosChanged(UINT message,
+ WPARAM w_param,
+ LPARAM l_param) {
+ WINDOWPOS* window_pos = reinterpret_cast<WINDOWPOS*>(l_param);
+ if (direct_manipulation_helper_) {
+ if (window_pos->flags & SWP_SHOWWINDOW) {
+ direct_manipulation_helper_->Activate(hwnd());
+ } else if (window_pos->flags & SWP_HIDEWINDOW) {
+ direct_manipulation_helper_->Deactivate(hwnd());
+ }
+ }
+ return 0;
sky 2015/08/14 20:56:37 Do you need the SetMsgHandled(FALSE); ?
ananta 2015/08/14 21:04:30 Done.
+}
+
} // namespace content
« no previous file with comments | « content/browser/renderer_host/legacy_render_widget_host_win.h ('k') | ui/gfx/win/direct_manipulation.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698