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/renderer/render_view_impl.h" | 5 #include "content/renderer/render_view_impl.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <cmath> | 8 #include <cmath> |
9 | 9 |
10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
(...skipping 759 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
770 OnEnableAutoResize(params.min_size, params.max_size); | 770 OnEnableAutoResize(params.min_size, params.max_size); |
771 } | 771 } |
772 | 772 |
773 new MHTMLGenerator(this); | 773 new MHTMLGenerator(this); |
774 #if defined(OS_MACOSX) | 774 #if defined(OS_MACOSX) |
775 new TextInputClientObserver(this); | 775 new TextInputClientObserver(this); |
776 #endif // defined(OS_MACOSX) | 776 #endif // defined(OS_MACOSX) |
777 | 777 |
778 // The next group of objects all implement RenderViewObserver, so are deleted | 778 // The next group of objects all implement RenderViewObserver, so are deleted |
779 // along with the RenderView automatically. | 779 // along with the RenderView automatically. |
780 devtools_agent_ = new DevToolsAgent(main_render_frame_.get()); | 780 if (!proxy) |
781 if (RenderWidgetCompositor* rwc = compositor()) { | 781 devtools_agent_ = new DevToolsAgent(main_render_frame_.get()); |
782 webview()->devToolsAgent()->setLayerTreeId(rwc->GetLayerTreeId()); | 782 if (webview()->devToolsAgent()) { |
pfeldman
2015/03/23 12:49:44
Place to under the if above.
dgozman
2015/03/23 13:28:26
Done.
| |
783 if (RenderWidgetCompositor* rwc = compositor()) | |
784 webview()->devToolsAgent()->setLayerTreeId(rwc->GetLayerTreeId()); | |
783 } | 785 } |
786 | |
784 mouse_lock_dispatcher_ = new RenderViewMouseLockDispatcher(this); | 787 mouse_lock_dispatcher_ = new RenderViewMouseLockDispatcher(this); |
785 | 788 |
786 history_controller_.reset(new HistoryController(this)); | 789 history_controller_.reset(new HistoryController(this)); |
787 | 790 |
788 new IdleUserDetector(this); | 791 new IdleUserDetector(this); |
789 | 792 |
790 if (command_line.HasSwitch(switches::kDomAutomationController)) | 793 if (command_line.HasSwitch(switches::kDomAutomationController)) |
791 enabled_bindings_ |= BINDINGS_POLICY_DOM_AUTOMATION; | 794 enabled_bindings_ |= BINDINGS_POLICY_DOM_AUTOMATION; |
792 if (command_line.HasSwitch(switches::kStatsCollectionController)) | 795 if (command_line.HasSwitch(switches::kStatsCollectionController)) |
793 enabled_bindings_ |= BINDINGS_POLICY_STATS_COLLECTION; | 796 enabled_bindings_ |= BINDINGS_POLICY_STATS_COLLECTION; |
(...skipping 3167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
3961 std::vector<gfx::Size> sizes; | 3964 std::vector<gfx::Size> sizes; |
3962 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); | 3965 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); |
3963 if (!url.isEmpty()) | 3966 if (!url.isEmpty()) |
3964 urls.push_back( | 3967 urls.push_back( |
3965 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); | 3968 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); |
3966 } | 3969 } |
3967 SendUpdateFaviconURL(urls); | 3970 SendUpdateFaviconURL(urls); |
3968 } | 3971 } |
3969 | 3972 |
3970 } // namespace content | 3973 } // namespace content |
OLD | NEW |