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/web_contents/web_contents_impl.h" | 5 #include "content/browser/web_contents/web_contents_impl.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 #include "net/http/http_cache.h" | 97 #include "net/http/http_cache.h" |
98 #include "net/http/http_transaction_factory.h" | 98 #include "net/http/http_transaction_factory.h" |
99 #include "net/url_request/url_request_context.h" | 99 #include "net/url_request/url_request_context.h" |
100 #include "net/url_request/url_request_context_getter.h" | 100 #include "net/url_request/url_request_context_getter.h" |
101 #include "ui/base/layout.h" | 101 #include "ui/base/layout.h" |
102 #include "ui/gfx/display.h" | 102 #include "ui/gfx/display.h" |
103 #include "ui/gfx/screen.h" | 103 #include "ui/gfx/screen.h" |
104 #include "ui/gl/gl_switches.h" | 104 #include "ui/gl/gl_switches.h" |
105 | 105 |
106 #if defined(OS_ANDROID) | 106 #if defined(OS_ANDROID) |
107 #include "content/browser/android/content_view_core_impl.h" | |
108 #include "content/browser/android/date_time_chooser_android.h" | 107 #include "content/browser/android/date_time_chooser_android.h" |
109 #include "content/browser/media/android/browser_media_player_manager.h" | 108 #include "content/browser/media/android/browser_media_player_manager.h" |
110 #include "content/browser/web_contents/web_contents_android.h" | 109 #include "content/browser/web_contents/web_contents_android.h" |
111 #include "content/public/browser/android/content_view_core.h" | |
112 #endif | 110 #endif |
113 | 111 |
114 #if defined(OS_MACOSX) | 112 #if defined(OS_MACOSX) |
115 #include "base/mac/foundation_util.h" | 113 #include "base/mac/foundation_util.h" |
116 #endif | 114 #endif |
117 | 115 |
118 namespace content { | 116 namespace content { |
119 namespace { | 117 namespace { |
120 | 118 |
121 const int kMinimumDelayBetweenLoadingUpdatesMS = 100; | 119 const int kMinimumDelayBetweenLoadingUpdatesMS = 100; |
(...skipping 2736 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2858 void WebContentsImpl::OnFindMatchRectsReply( | 2856 void WebContentsImpl::OnFindMatchRectsReply( |
2859 int version, | 2857 int version, |
2860 const std::vector<gfx::RectF>& rects, | 2858 const std::vector<gfx::RectF>& rects, |
2861 const gfx::RectF& active_rect) { | 2859 const gfx::RectF& active_rect) { |
2862 if (delegate_) | 2860 if (delegate_) |
2863 delegate_->FindMatchRectsReply(this, version, rects, active_rect); | 2861 delegate_->FindMatchRectsReply(this, version, rects, active_rect); |
2864 } | 2862 } |
2865 | 2863 |
2866 void WebContentsImpl::OnOpenDateTimeDialog( | 2864 void WebContentsImpl::OnOpenDateTimeDialog( |
2867 const ViewHostMsg_DateTimeDialogValue_Params& value) { | 2865 const ViewHostMsg_DateTimeDialogValue_Params& value) { |
2868 date_time_chooser_->ShowDialog(ContentViewCore::FromWebContents(this), | 2866 date_time_chooser_->ShowDialog(GetTopLevelNativeWindow(), |
2869 GetRenderViewHost(), | 2867 GetRenderViewHost(), |
2870 value.dialog_type, | 2868 value.dialog_type, |
2871 value.dialog_value, | 2869 value.dialog_value, |
2872 value.minimum, | 2870 value.minimum, |
2873 value.maximum, | 2871 value.maximum, |
2874 value.step, | 2872 value.step, |
2875 value.suggestions); | 2873 value.suggestions); |
2876 } | 2874 } |
2877 | 2875 |
2878 #endif | 2876 #endif |
(...skipping 1439 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4318 node->render_manager()->ResumeResponseDeferredAtStart(); | 4316 node->render_manager()->ResumeResponseDeferredAtStart(); |
4319 } | 4317 } |
4320 | 4318 |
4321 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) { | 4319 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) { |
4322 force_disable_overscroll_content_ = force_disable; | 4320 force_disable_overscroll_content_ = force_disable; |
4323 if (view_) | 4321 if (view_) |
4324 view_->SetOverscrollControllerEnabled(CanOverscrollContent()); | 4322 view_->SetOverscrollControllerEnabled(CanOverscrollContent()); |
4325 } | 4323 } |
4326 | 4324 |
4327 } // namespace content | 4325 } // namespace content |
OLD | NEW |