| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "extensions/browser/extension_host.h" | 5 #include "extensions/browser/extension_host.h" |
| 6 | 6 |
| 7 #include <list> | 7 #include <list> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 delegate_->OnRenderViewCreatedForBackgroundPage(this); | 193 delegate_->OnRenderViewCreatedForBackgroundPage(this); |
| 194 } | 194 } |
| 195 } | 195 } |
| 196 | 196 |
| 197 const GURL& ExtensionHost::GetURL() const { | 197 const GURL& ExtensionHost::GetURL() const { |
| 198 return host_contents()->GetURL(); | 198 return host_contents()->GetURL(); |
| 199 } | 199 } |
| 200 | 200 |
| 201 void ExtensionHost::LoadInitialURL() { | 201 void ExtensionHost::LoadInitialURL() { |
| 202 host_contents_->GetController().LoadURL( | 202 host_contents_->GetController().LoadURL( |
| 203 initial_url_, content::Referrer(), content::PAGE_TRANSITION_LINK, | 203 initial_url_, content::Referrer(), ui::PAGE_TRANSITION_LINK, |
| 204 std::string()); | 204 std::string()); |
| 205 } | 205 } |
| 206 | 206 |
| 207 bool ExtensionHost::IsBackgroundPage() const { | 207 bool ExtensionHost::IsBackgroundPage() const { |
| 208 DCHECK(extension_host_type_ == VIEW_TYPE_EXTENSION_BACKGROUND_PAGE); | 208 DCHECK(extension_host_type_ == VIEW_TYPE_EXTENSION_BACKGROUND_PAGE); |
| 209 return true; | 209 return true; |
| 210 } | 210 } |
| 211 | 211 |
| 212 void ExtensionHost::Close() { | 212 void ExtensionHost::Close() { |
| 213 content::NotificationService::current()->Notify( | 213 content::NotificationService::current()->Notify( |
| (...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 435 return delegate_->CheckMediaAccessPermission( | 435 return delegate_->CheckMediaAccessPermission( |
| 436 web_contents, security_origin, type, extension()); | 436 web_contents, security_origin, type, extension()); |
| 437 } | 437 } |
| 438 | 438 |
| 439 bool ExtensionHost::IsNeverVisible(content::WebContents* web_contents) { | 439 bool ExtensionHost::IsNeverVisible(content::WebContents* web_contents) { |
| 440 ViewType view_type = extensions::GetViewType(web_contents); | 440 ViewType view_type = extensions::GetViewType(web_contents); |
| 441 return view_type == extensions::VIEW_TYPE_EXTENSION_BACKGROUND_PAGE; | 441 return view_type == extensions::VIEW_TYPE_EXTENSION_BACKGROUND_PAGE; |
| 442 } | 442 } |
| 443 | 443 |
| 444 } // namespace extensions | 444 } // namespace extensions |
| OLD | NEW |