OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/tab_contents/tab_contents_delegate.h" | 5 #include "content/browser/tab_contents/tab_contents_delegate.h" |
6 | 6 |
7 #include "base/compiler_specific.h" | 7 #include "base/compiler_specific.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/memory/singleton.h" | 9 #include "base/memory/singleton.h" |
10 #include "content/browser/javascript_dialogs.h" | 10 #include "content/browser/javascript_dialogs.h" |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 TabContents* contents, bool blocked) { | 120 TabContents* contents, bool blocked) { |
121 } | 121 } |
122 | 122 |
123 void TabContentsDelegate::TabContentsFocused(TabContents* tab_content) { | 123 void TabContentsDelegate::TabContentsFocused(TabContents* tab_content) { |
124 } | 124 } |
125 | 125 |
126 int TabContentsDelegate::GetExtraRenderViewHeight() const { | 126 int TabContentsDelegate::GetExtraRenderViewHeight() const { |
127 return 0; | 127 return 0; |
128 } | 128 } |
129 | 129 |
| 130 bool TabContentsDelegate::CanDownload(TabContents* source, int request_id) { |
| 131 return true; |
| 132 } |
| 133 |
| 134 void TabContentsDelegate::OnStartDownload(TabContents* source, |
| 135 DownloadItem* download) { |
| 136 } |
| 137 |
130 bool TabContentsDelegate::HandleContextMenu(const ContextMenuParams& params) { | 138 bool TabContentsDelegate::HandleContextMenu(const ContextMenuParams& params) { |
131 return false; | 139 return false; |
132 } | 140 } |
133 | 141 |
134 bool TabContentsDelegate::ExecuteContextMenuCommand(int command) { | 142 bool TabContentsDelegate::ExecuteContextMenuCommand(int command) { |
135 return false; | 143 return false; |
136 } | 144 } |
137 | 145 |
138 void TabContentsDelegate::ShowPageInfo(Profile* profile, | 146 void TabContentsDelegate::ShowPageInfo(Profile* profile, |
139 const GURL& url, | 147 const GURL& url, |
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
274 | 282 |
275 void TabContentsDelegate::Attach(TabContents* tab_contents) { | 283 void TabContentsDelegate::Attach(TabContents* tab_contents) { |
276 DCHECK(attached_contents_.find(tab_contents) == attached_contents_.end()); | 284 DCHECK(attached_contents_.find(tab_contents) == attached_contents_.end()); |
277 attached_contents_.insert(tab_contents); | 285 attached_contents_.insert(tab_contents); |
278 } | 286 } |
279 | 287 |
280 void TabContentsDelegate::Detach(TabContents* tab_contents) { | 288 void TabContentsDelegate::Detach(TabContents* tab_contents) { |
281 DCHECK(attached_contents_.find(tab_contents) != attached_contents_.end()); | 289 DCHECK(attached_contents_.find(tab_contents) != attached_contents_.end()); |
282 attached_contents_.erase(tab_contents); | 290 attached_contents_.erase(tab_contents); |
283 } | 291 } |
OLD | NEW |