| 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 "chrome/browser/media_galleries/media_file_system_registry.h" | 5 #include "chrome/browser/media_galleries/media_file_system_registry.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 177 : content::WebContentsObserver(web_contents), | 177 : content::WebContentsObserver(web_contents), |
| 178 manager_(manager) { | 178 manager_(manager) { |
| 179 } | 179 } |
| 180 | 180 |
| 181 void RPHReferenceManager::RPHWebContentsObserver::WebContentsDestroyed() { | 181 void RPHReferenceManager::RPHWebContentsObserver::WebContentsDestroyed() { |
| 182 manager_->OnWebContentsDestroyedOrNavigated(web_contents()); | 182 manager_->OnWebContentsDestroyedOrNavigated(web_contents()); |
| 183 } | 183 } |
| 184 | 184 |
| 185 void RPHReferenceManager::RPHWebContentsObserver::NavigationEntryCommitted( | 185 void RPHReferenceManager::RPHWebContentsObserver::NavigationEntryCommitted( |
| 186 const content::LoadCommittedDetails& load_details) { | 186 const content::LoadCommittedDetails& load_details) { |
| 187 if (load_details.is_in_page) | 187 if (load_details.is_same_document) |
| 188 return; | 188 return; |
| 189 | 189 |
| 190 manager_->OnWebContentsDestroyedOrNavigated(web_contents()); | 190 manager_->OnWebContentsDestroyedOrNavigated(web_contents()); |
| 191 } | 191 } |
| 192 | 192 |
| 193 RPHReferenceManager::RPHObserver::RPHObserver( | 193 RPHReferenceManager::RPHObserver::RPHObserver( |
| 194 RPHReferenceManager* manager, RenderProcessHost* host) | 194 RPHReferenceManager* manager, RenderProcessHost* host) |
| 195 : manager_(manager), | 195 : manager_(manager), |
| 196 host_(host) { | 196 host_(host) { |
| 197 host->AddObserver(this); | 197 host->AddObserver(this); |
| (...skipping 670 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 868 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 868 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| 869 | 869 |
| 870 auto extension_hosts_it = extension_hosts_map_.find(profile); | 870 auto extension_hosts_it = extension_hosts_map_.find(profile); |
| 871 DCHECK(extension_hosts_it != extension_hosts_map_.end()); | 871 DCHECK(extension_hosts_it != extension_hosts_map_.end()); |
| 872 extension_hosts_map_.erase(extension_hosts_it); | 872 extension_hosts_map_.erase(extension_hosts_it); |
| 873 | 873 |
| 874 auto profile_subscription_it = profile_subscription_map_.find(profile); | 874 auto profile_subscription_it = profile_subscription_map_.find(profile); |
| 875 DCHECK(profile_subscription_it != profile_subscription_map_.end()); | 875 DCHECK(profile_subscription_it != profile_subscription_map_.end()); |
| 876 profile_subscription_map_.erase(profile_subscription_it); | 876 profile_subscription_map_.erase(profile_subscription_it); |
| 877 } | 877 } |
| OLD | NEW |