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 2689 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
2700 | 2700 |
2701 void WebContentsImpl::ShowContextMenu(RenderFrameHost* render_frame_host, | 2701 void WebContentsImpl::ShowContextMenu(RenderFrameHost* render_frame_host, |
2702 const ContextMenuParams& params) { | 2702 const ContextMenuParams& params) { |
2703 // Allow WebContentsDelegates to handle the context menu operation first. | 2703 // Allow WebContentsDelegates to handle the context menu operation first. |
2704 if (delegate_ && delegate_->HandleContextMenu(params)) | 2704 if (delegate_ && delegate_->HandleContextMenu(params)) |
2705 return; | 2705 return; |
2706 | 2706 |
2707 render_view_host_delegate_view_->ShowContextMenu(render_frame_host, params); | 2707 render_view_host_delegate_view_->ShowContextMenu(render_frame_host, params); |
2708 } | 2708 } |
2709 | 2709 |
2710 void WebContentsImpl::OnDomOperationResponse( | |
2711 const DomOperationNotificationDetails& details) { | |
nasko
2014/02/11 17:32:33
style: only 4 spaces for indent.
mkosiba (inactive)
2014/02/14 15:04:41
Done.
| |
2712 NotificationService::current()->Notify( | |
2713 NOTIFICATION_DOM_OPERATION_RESPONSE, | |
2714 Source<WebContents>(this), | |
2715 Details<const DomOperationNotificationDetails>(&details)); | |
2716 } | |
2717 | |
2710 WebContents* WebContentsImpl::GetAsWebContents() { | 2718 WebContents* WebContentsImpl::GetAsWebContents() { |
2711 return this; | 2719 return this; |
2712 } | 2720 } |
2713 | 2721 |
2714 RenderViewHostDelegateView* WebContentsImpl::GetDelegateView() { | 2722 RenderViewHostDelegateView* WebContentsImpl::GetDelegateView() { |
2715 return render_view_host_delegate_view_; | 2723 return render_view_host_delegate_view_; |
2716 } | 2724 } |
2717 | 2725 |
2718 RenderViewHostDelegate::RendererManagement* | 2726 RenderViewHostDelegate::RendererManagement* |
2719 WebContentsImpl::GetRendererManagementDelegate() { | 2727 WebContentsImpl::GetRendererManagementDelegate() { |
(...skipping 1041 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
3761 | 3769 |
3762 void WebContentsImpl::OnPreferredSizeChanged(const gfx::Size& old_size) { | 3770 void WebContentsImpl::OnPreferredSizeChanged(const gfx::Size& old_size) { |
3763 if (!delegate_) | 3771 if (!delegate_) |
3764 return; | 3772 return; |
3765 const gfx::Size new_size = GetPreferredSize(); | 3773 const gfx::Size new_size = GetPreferredSize(); |
3766 if (new_size != old_size) | 3774 if (new_size != old_size) |
3767 delegate_->UpdatePreferredSize(this, new_size); | 3775 delegate_->UpdatePreferredSize(this, new_size); |
3768 } | 3776 } |
3769 | 3777 |
3770 } // namespace content | 3778 } // namespace content |
OLD | NEW |