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 3655 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3666 // linux. See crbug.com/83941. | 3666 // linux. See crbug.com/83941. |
3667 if (rwh_view) { | 3667 if (rwh_view) { |
3668 if (RenderWidgetHost* render_widget_host = rwh_view->GetRenderWidgetHost()) | 3668 if (RenderWidgetHost* render_widget_host = rwh_view->GetRenderWidgetHost()) |
3669 render_widget_host->WasResized(); | 3669 render_widget_host->WasResized(); |
3670 } | 3670 } |
3671 #endif | 3671 #endif |
3672 | 3672 |
3673 return true; | 3673 return true; |
3674 } | 3674 } |
3675 | 3675 |
| 3676 #if defined(OS_ANDROID) |
| 3677 bool WebContentsImpl::CreateRenderViewForInitialEmptyDocument() { |
| 3678 return CreateRenderViewForRenderManager(GetRenderViewHost(), |
| 3679 MSG_ROUTING_NONE); |
| 3680 } |
| 3681 #endif |
| 3682 |
3676 void WebContentsImpl::OnDialogClosed(RenderViewHost* rvh, | 3683 void WebContentsImpl::OnDialogClosed(RenderViewHost* rvh, |
3677 IPC::Message* reply_msg, | 3684 IPC::Message* reply_msg, |
3678 bool success, | 3685 bool success, |
3679 const string16& user_input) { | 3686 const string16& user_input) { |
3680 if (is_showing_before_unload_dialog_ && !success) { | 3687 if (is_showing_before_unload_dialog_ && !success) { |
3681 // If a beforeunload dialog is canceled, we need to stop the throbber from | 3688 // If a beforeunload dialog is canceled, we need to stop the throbber from |
3682 // spinning, since we forced it to start spinning in Navigate. | 3689 // spinning, since we forced it to start spinning in Navigate. |
3683 DidStopLoading(rvh); | 3690 DidStopLoading(rvh); |
3684 controller_.DiscardNonCommittedEntries(); | 3691 controller_.DiscardNonCommittedEntries(); |
3685 | 3692 |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3738 } | 3745 } |
3739 | 3746 |
3740 void WebContentsImpl::ClearAllPowerSaveBlockers() { | 3747 void WebContentsImpl::ClearAllPowerSaveBlockers() { |
3741 for (PowerSaveBlockerMap::iterator i(power_save_blockers_.begin()); | 3748 for (PowerSaveBlockerMap::iterator i(power_save_blockers_.begin()); |
3742 i != power_save_blockers_.end(); ++i) | 3749 i != power_save_blockers_.end(); ++i) |
3743 STLDeleteValues(&power_save_blockers_[i->first]); | 3750 STLDeleteValues(&power_save_blockers_[i->first]); |
3744 power_save_blockers_.clear(); | 3751 power_save_blockers_.clear(); |
3745 } | 3752 } |
3746 | 3753 |
3747 } // namespace content | 3754 } // namespace content |
OLD | NEW |