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

Unified Diff: ui/views/controls/native/native_view_host_win.cc

Issue 30993004: Reland: Implement features in NativeViewHostAura for scroll end effect (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing compile failure on the bots Created 7 years, 2 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
Index: ui/views/controls/native/native_view_host_win.cc
diff --git a/ui/views/controls/native/native_view_host_win.cc b/ui/views/controls/native/native_view_host_win.cc
index e7b74c3c7a1671709d7e26dede7d58db05cfec53..45de684f71d5df3c18157ca44d4586a66761d770 100644
--- a/ui/views/controls/native/native_view_host_win.cc
+++ b/ui/views/controls/native/native_view_host_win.cc
@@ -32,10 +32,14 @@ NativeViewHostWin::~NativeViewHostWin() {
////////////////////////////////////////////////////////////////////////////////
// NativeViewHostWin, NativeViewHostWrapper implementation:
-void NativeViewHostWin::NativeViewWillAttach() {
+void NativeViewHostWin::AttachNativeView() {
// First hide the new window. We don't want anything to draw (like sub-hwnd
- // borders), when NativeViewHost changes the parent.
+ // borders), when the parent changes.
ShowWindow(host_->native_view(), SW_HIDE);
+
+ Widget::ReparentNativeView(host_->native_view(),
+ host_->GetWidget()->GetNativeView());
+
}
void NativeViewHostWin::NativeViewDetaching(bool destroyed) {
« no previous file with comments | « ui/views/controls/native/native_view_host_win.h ('k') | ui/views/controls/native/native_view_host_wrapper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698