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/public/browser/web_contents_delegate.h" | 5 #include "content/public/browser/web_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/public/browser/navigation_controller.h" | |
11 #include "content/public/browser/navigation_entry.h" | |
Charlie Reis
2012/05/17 22:18:57
You don't need these.
mkosiba (inactive)
2012/05/18 12:33:01
Done.
| |
10 #include "content/public/browser/render_view_host.h" | 12 #include "content/public/browser/render_view_host.h" |
11 #include "content/public/browser/web_contents.h" | 13 #include "content/public/browser/web_contents.h" |
12 #include "content/public/browser/web_intents_dispatcher.h" | 14 #include "content/public/browser/web_intents_dispatcher.h" |
13 #include "content/public/common/url_constants.h" | 15 #include "content/public/common/url_constants.h" |
14 #include "ui/gfx/rect.h" | 16 #include "ui/gfx/rect.h" |
15 #include "webkit/glue/web_intent_data.h" | 17 #include "webkit/glue/web_intent_data.h" |
16 | 18 |
17 namespace content { | 19 namespace content { |
18 | 20 |
19 WebContentsDelegate::WebContentsDelegate() { | 21 WebContentsDelegate::WebContentsDelegate() { |
20 } | 22 } |
21 | 23 |
22 WebContents* WebContentsDelegate::OpenURLFromTab(WebContents* source, | 24 WebContents* WebContentsDelegate::OpenURLFromTab(WebContents* source, |
23 const OpenURLParams& params) { | 25 const OpenURLParams& params) { |
24 return NULL; | 26 return NULL; |
25 } | 27 } |
26 | 28 |
29 bool WebContentsDelegate::ShouldIgnoreNavigation( | |
30 WebContents* source, | |
31 const GURL& url, | |
32 const content::Referrer& referrer, | |
33 bool is_content_initiated) { | |
34 return false; | |
35 } | |
36 | |
27 bool WebContentsDelegate::IsPopupOrPanel(const WebContents* source) const { | 37 bool WebContentsDelegate::IsPopupOrPanel(const WebContents* source) const { |
28 return false; | 38 return false; |
29 } | 39 } |
30 | 40 |
31 bool WebContentsDelegate::IsApplication() const { return false; } | 41 bool WebContentsDelegate::IsApplication() const { return false; } |
32 | 42 |
33 bool WebContentsDelegate::CanLoadDataURLsInWebUI() const { return false; } | 43 bool WebContentsDelegate::CanLoadDataURLsInWebUI() const { return false; } |
34 | 44 |
35 bool WebContentsDelegate::CanReloadContents(WebContents* source) const { | 45 bool WebContentsDelegate::CanReloadContents(WebContents* source) const { |
36 return true; | 46 return true; |
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
165 DCHECK(attached_contents_.find(web_contents) == attached_contents_.end()); | 175 DCHECK(attached_contents_.find(web_contents) == attached_contents_.end()); |
166 attached_contents_.insert(web_contents); | 176 attached_contents_.insert(web_contents); |
167 } | 177 } |
168 | 178 |
169 void WebContentsDelegate::Detach(WebContents* web_contents) { | 179 void WebContentsDelegate::Detach(WebContents* web_contents) { |
170 DCHECK(attached_contents_.find(web_contents) != attached_contents_.end()); | 180 DCHECK(attached_contents_.find(web_contents) != attached_contents_.end()); |
171 attached_contents_.erase(web_contents); | 181 attached_contents_.erase(web_contents); |
172 } | 182 } |
173 | 183 |
174 } // namespace content | 184 } // namespace content |
OLD | NEW |