OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "content/browser/renderer_host/render_widget_host_impl.h" | 5 #include "content/browser/renderer_host/render_widget_host_impl.h" |
6 | 6 |
7 #include <math.h> | 7 #include <math.h> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
192 } | 192 } |
193 | 193 |
194 is_threaded_compositing_enabled_ = IsThreadedCompositingEnabled(); | 194 is_threaded_compositing_enabled_ = IsThreadedCompositingEnabled(); |
195 | 195 |
196 process_->Attach(this, routing_id_); | 196 process_->Attach(this, routing_id_); |
197 // Because the widget initializes as is_hidden_ == false, | 197 // Because the widget initializes as is_hidden_ == false, |
198 // tell the process host that we're alive. | 198 // tell the process host that we're alive. |
199 process_->WidgetRestored(); | 199 process_->WidgetRestored(); |
200 | 200 |
201 #if defined(USE_AURA) | 201 #if defined(USE_AURA) |
202 bool overscroll_enabled = !CommandLine::ForCurrentProcess()-> | 202 bool overscroll_enabled = CommandLine::ForCurrentProcess()-> |
203 HasSwitch(switches::kDisableOverscrollHistoryNavigation); | 203 HasSwitch(switches::kEnableOverscrollHistoryNavigation); |
204 if (overscroll_enabled) | 204 if (overscroll_enabled) |
205 InitializeOverscrollController(); | 205 InitializeOverscrollController(); |
206 #endif | 206 #endif |
207 } | 207 } |
208 | 208 |
209 RenderWidgetHostImpl::~RenderWidgetHostImpl() { | 209 RenderWidgetHostImpl::~RenderWidgetHostImpl() { |
210 SetView(NULL); | 210 SetView(NULL); |
211 | 211 |
212 // Clear our current or cached backing store if either remains. | 212 // Clear our current or cached backing store if either remains. |
213 BackingStoreManager::RemoveBackingStore(this); | 213 BackingStoreManager::RemoveBackingStore(this); |
(...skipping 2177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2391 return; | 2391 return; |
2392 | 2392 |
2393 OnRenderAutoResized(new_size); | 2393 OnRenderAutoResized(new_size); |
2394 } | 2394 } |
2395 | 2395 |
2396 void RenderWidgetHostImpl::DetachDelegate() { | 2396 void RenderWidgetHostImpl::DetachDelegate() { |
2397 delegate_ = NULL; | 2397 delegate_ = NULL; |
2398 } | 2398 } |
2399 | 2399 |
2400 } // namespace content | 2400 } // namespace content |
OLD | NEW |