diff options
27 files changed, 101 insertions, 94 deletions
diff --git a/base/android/application_status_listener.cc b/base/android/application_status_listener.cc index f487072..02178c4 100644 --- a/base/android/application_status_listener.cc +++ b/base/android/application_status_listener.cc @@ -60,7 +60,8 @@ bool ApplicationStatusListener::RegisterBindings(JNIEnv* env) { // static void ApplicationStatusListener::NotifyApplicationStateChange( ApplicationState state) { - g_observers.Get().Notify(&ApplicationStatusListener::Notify, state); + g_observers.Get().Notify(FROM_HERE, &ApplicationStatusListener::Notify, + state); } static void OnApplicationStateChange(JNIEnv* env, diff --git a/base/memory/memory_pressure_listener.cc b/base/memory/memory_pressure_listener.cc index d808502..6a8ed21 100644 --- a/base/memory/memory_pressure_listener.cc +++ b/base/memory/memory_pressure_listener.cc @@ -54,7 +54,7 @@ void MemoryPressureListener::NotifyMemoryPressure( DCHECK_NE(memory_pressure_level, MEMORY_PRESSURE_LEVEL_NONE); TRACE_EVENT1("memory", "MemoryPressureListener::NotifyMemoryPressure", "level", memory_pressure_level); - g_observers.Get().Notify(&MemoryPressureListener::Notify, + g_observers.Get().Notify(FROM_HERE, &MemoryPressureListener::Notify, memory_pressure_level); } diff --git a/base/metrics/field_trial.cc b/base/metrics/field_trial.cc index e03c94c..639f6d3 100644 --- a/base/metrics/field_trial.cc +++ b/base/metrics/field_trial.cc @@ -547,9 +547,8 @@ void FieldTrialList::NotifyFieldTrialGroupSelection(FieldTrial* field_trial) { return; global_->observer_list_->Notify( - &FieldTrialList::Observer::OnFieldTrialGroupFinalized, - field_trial->trial_name(), - field_trial->group_name_internal()); + FROM_HERE, &FieldTrialList::Observer::OnFieldTrialGroupFinalized, + field_trial->trial_name(), field_trial->group_name_internal()); } // static diff --git a/base/observer_list_threadsafe.h b/base/observer_list_threadsafe.h index b951a71..1a66333 100644 --- a/base/observer_list_threadsafe.h +++ b/base/observer_list_threadsafe.h @@ -168,7 +168,9 @@ class ObserverListThreadSafe // that at the completion of the Notify call that all Observers have // been Notified. The notification may still be pending delivery. template <class Method, class... Params> - void Notify(Method m, const Params&... params) { + void Notify(const tracked_objects::Location& from_here, + Method m, + const Params&... params) { UnboundMethod<ObserverType, Method, Tuple<Params...>> method( m, MakeTuple(params...)); @@ -176,7 +178,7 @@ class ObserverListThreadSafe for (const auto& entry : observer_lists_) { ObserverListContext* context = entry.second; context->loop->PostTask( - FROM_HERE, + from_here, base::Bind( &ObserverListThreadSafe<ObserverType>::template NotifyWrapper< Method, Tuple<Params...>>, diff --git a/base/observer_list_unittest.cc b/base/observer_list_unittest.cc index 65ef934..636aa83 100644 --- a/base/observer_list_unittest.cc +++ b/base/observer_list_unittest.cc @@ -134,7 +134,7 @@ class AddRemoveThread : public PlatformThread::Delegate, } if (do_notifies_) { - list_->Notify(&Foo::Observe, 10); + list_->Notify(FROM_HERE, &Foo::Observe, 10); } loop_->PostTask( @@ -217,14 +217,14 @@ TEST(ObserverListThreadSafeTest, BasicTest) { observer_list->AddObserver(&a); observer_list->AddObserver(&b); - observer_list->Notify(&Foo::Observe, 10); + observer_list->Notify(FROM_HERE, &Foo::Observe, 10); RunLoop().RunUntilIdle(); observer_list->AddObserver(&evil); observer_list->AddObserver(&c); observer_list->AddObserver(&d); - observer_list->Notify(&Foo::Observe, 10); + observer_list->Notify(FROM_HERE, &Foo::Observe, 10); RunLoop().RunUntilIdle(); EXPECT_EQ(20, a.total); @@ -247,7 +247,7 @@ TEST(ObserverListThreadSafeTest, RemoveObserver) { observer_list->RemoveObserver(&a); observer_list->RemoveObserver(&b); - observer_list->Notify(&Foo::Observe, 10); + observer_list->Notify(FROM_HERE, &Foo::Observe, 10); RunLoop().RunUntilIdle(); EXPECT_EQ(0, a.total); @@ -258,7 +258,7 @@ TEST(ObserverListThreadSafeTest, RemoveObserver) { // Should also do nothing. observer_list->RemoveObserver(&b); - observer_list->Notify(&Foo::Observe, 10); + observer_list->Notify(FROM_HERE, &Foo::Observe, 10); RunLoop().RunUntilIdle(); EXPECT_EQ(10, a.total); @@ -280,7 +280,7 @@ TEST(ObserverListThreadSafeTest, WithoutMessageLoop) { MessageLoop loop; observer_list->AddObserver(&c); - observer_list->Notify(&Foo::Observe, 10); + observer_list->Notify(FROM_HERE, &Foo::Observe, 10); RunLoop().RunUntilIdle(); EXPECT_EQ(0, a.total); @@ -294,7 +294,7 @@ TEST(ObserverListThreadSafeTest, WithoutMessageLoop) { observer_list->RemoveObserver(&c); // Notify again. - observer_list->Notify(&Foo::Observe, 20); + observer_list->Notify(FROM_HERE, &Foo::Observe, 20); RunLoop().RunUntilIdle(); EXPECT_EQ(20, a.total); @@ -308,7 +308,7 @@ TEST(ObserverListThreadSafeTest, WithoutMessageLoop) { // Notifying should not fail but should also be a no-op. MessageLoop loop; observer_list->AddObserver(&b); - observer_list->Notify(&Foo::Observe, 30); + observer_list->Notify(FROM_HERE, &Foo::Observe, 30); RunLoop().RunUntilIdle(); EXPECT_EQ(20, a.total); @@ -353,7 +353,7 @@ TEST(ObserverListThreadSafeTest, RemoveMultipleObservers) { a.AddFooToRemove(&a); a.AddFooToRemove(&b); - observer_list->Notify(&Foo::Observe, 1); + observer_list->Notify(FROM_HERE, &Foo::Observe, 1); RunLoop().RunUntilIdle(); } @@ -392,7 +392,7 @@ static void ThreadSafeObserverHarness(int num_threads, if ((Time::Now() - start).InMilliseconds() > kThreadRunTime) break; - observer_list->Notify(&Foo::Observe, 10); + observer_list->Notify(FROM_HERE, &Foo::Observe, 10); RunLoop().RunUntilIdle(); } @@ -424,7 +424,7 @@ TEST(ObserverListThreadSafeTest, OutlivesMessageLoop) { observer_list->AddObserver(&a); delete loop; // Test passes if we don't crash here. - observer_list->Notify(&Foo::Observe, 1); + observer_list->Notify(FROM_HERE, &Foo::Observe, 1); } TEST(ObserverListTest, Existing) { @@ -458,7 +458,7 @@ TEST(ObserverListThreadSafeTest, Existing) { observer_list->AddObserver(&a); observer_list->AddObserver(&b); - observer_list->Notify(&Foo::Observe, 1); + observer_list->Notify(FROM_HERE, &Foo::Observe, 1); RunLoop().RunUntilIdle(); EXPECT_TRUE(b.added); @@ -467,7 +467,7 @@ TEST(ObserverListThreadSafeTest, Existing) { EXPECT_EQ(0, b.adder.total); // Notify again to make sure b's adder is notified. - observer_list->Notify(&Foo::Observe, 1); + observer_list->Notify(FROM_HERE, &Foo::Observe, 1); RunLoop().RunUntilIdle(); EXPECT_EQ(1, b.adder.total); } diff --git a/base/power_monitor/power_monitor.cc b/base/power_monitor/power_monitor.cc index 14dc4b5..98c9c68 100644 --- a/base/power_monitor/power_monitor.cc +++ b/base/power_monitor/power_monitor.cc @@ -45,17 +45,18 @@ bool PowerMonitor::IsOnBatteryPower() { void PowerMonitor::NotifyPowerStateChange(bool battery_in_use) { DVLOG(1) << "PowerStateChange: " << (battery_in_use ? "On" : "Off") << " battery"; - observers_->Notify(&PowerObserver::OnPowerStateChange, battery_in_use); + observers_->Notify(FROM_HERE, &PowerObserver::OnPowerStateChange, + battery_in_use); } void PowerMonitor::NotifySuspend() { DVLOG(1) << "Power Suspending"; - observers_->Notify(&PowerObserver::OnSuspend); + observers_->Notify(FROM_HERE, &PowerObserver::OnSuspend); } void PowerMonitor::NotifyResume() { DVLOG(1) << "Power Resuming"; - observers_->Notify(&PowerObserver::OnResume); + observers_->Notify(FROM_HERE, &PowerObserver::OnResume); } } // namespace base diff --git a/base/system_monitor/system_monitor.cc b/base/system_monitor/system_monitor.cc index 11dd000..99152ab 100644 --- a/base/system_monitor/system_monitor.cc +++ b/base/system_monitor/system_monitor.cc @@ -46,7 +46,7 @@ void SystemMonitor::RemoveDevicesChangedObserver(DevicesChangedObserver* obs) { void SystemMonitor::NotifyDevicesChanged(DeviceType device_type) { DVLOG(1) << "DevicesChanged with device type " << device_type; devices_changed_observer_list_->Notify( - &DevicesChangedObserver::OnDevicesChanged, device_type); + FROM_HERE, &DevicesChangedObserver::OnDevicesChanged, device_type); } } // namespace base diff --git a/chrome/browser/extensions/activity_log/activity_log.cc b/chrome/browser/extensions/activity_log/activity_log.cc index 509393f..1fad43a 100644 --- a/chrome/browser/extensions/activity_log/activity_log.cc +++ b/chrome/browser/extensions/activity_log/activity_log.cc @@ -545,7 +545,7 @@ void ActivityLog::LogAction(scoped_refptr<Action> action) { if (IsDatabaseEnabled() && database_policy_) database_policy_->ProcessAction(action); if (IsWatchdogAppActive()) - observers_->Notify(&Observer::OnExtensionActivity, action); + observers_->Notify(FROM_HERE, &Observer::OnExtensionActivity, action); if (testing_mode_) VLOG(1) << action->PrintForDebug(); } diff --git a/chrome/browser/extensions/api/storage/policy_value_store.cc b/chrome/browser/extensions/api/storage/policy_value_store.cc index 900b7c7..cb40641 100644 --- a/chrome/browser/extensions/api/storage/policy_value_store.cc +++ b/chrome/browser/extensions/api/storage/policy_value_store.cc @@ -105,11 +105,9 @@ void PolicyValueStore::SetCurrentPolicy(const policy::PolicyMap& policy) { } if (!changes.empty()) { - observers_->Notify( - &SettingsObserver::OnSettingsChanged, - extension_id_, - settings_namespace::MANAGED, - ValueStoreChange::ToJson(changes)); + observers_->Notify(FROM_HERE, &SettingsObserver::OnSettingsChanged, + extension_id_, settings_namespace::MANAGED, + ValueStoreChange::ToJson(changes)); } } diff --git a/chrome/browser/extensions/api/storage/syncable_settings_storage.cc b/chrome/browser/extensions/api/storage/syncable_settings_storage.cc index 95d95ec..d25bd17 100644 --- a/chrome/browser/extensions/api/storage/syncable_settings_storage.cc +++ b/chrome/browser/extensions/api/storage/syncable_settings_storage.cc @@ -356,11 +356,9 @@ syncer::SyncError SyncableSettingsStorage::ProcessSyncChanges( sync_processor_->NotifyChanges(changes); - observers_->Notify( - &SettingsObserver::OnSettingsChanged, - extension_id_, - settings_namespace::SYNC, - ValueStoreChange::ToJson(changes)); + observers_->Notify(FROM_HERE, &SettingsObserver::OnSettingsChanged, + extension_id_, settings_namespace::SYNC, + ValueStoreChange::ToJson(changes)); // TODO(kalman): Something sensible with multiple errors. return errors.empty() ? syncer::SyncError() : errors[0]; diff --git a/chrome/browser/sync_file_system/local/canned_syncable_file_system.cc b/chrome/browser/sync_file_system/local/canned_syncable_file_system.cc index 2e6f1fc..039f9da 100644 --- a/chrome/browser/sync_file_system/local/canned_syncable_file_system.cc +++ b/chrome/browser/sync_file_system/local/canned_syncable_file_system.cc @@ -550,13 +550,13 @@ FileSystemOperationRunner* CannedSyncableFileSystem::operation_runner() { } void CannedSyncableFileSystem::OnSyncEnabled(const FileSystemURL& url) { - sync_status_observers_->Notify(&LocalFileSyncStatus::Observer::OnSyncEnabled, - url); + sync_status_observers_->Notify( + FROM_HERE, &LocalFileSyncStatus::Observer::OnSyncEnabled, url); } void CannedSyncableFileSystem::OnWriteEnabled(const FileSystemURL& url) { - sync_status_observers_->Notify(&LocalFileSyncStatus::Observer::OnWriteEnabled, - url); + sync_status_observers_->Notify( + FROM_HERE, &LocalFileSyncStatus::Observer::OnWriteEnabled, url); } void CannedSyncableFileSystem::DoOpenFileSystem( diff --git a/components/password_manager/core/browser/password_store.cc b/components/password_manager/core/browser/password_store.cc index ebdeb83..0934321 100644 --- a/components/password_manager/core/browser/password_store.cc +++ b/components/password_manager/core/browser/password_store.cc @@ -225,7 +225,7 @@ void PasswordStore::NotifyLoginsChanged( const PasswordStoreChangeList& changes) { DCHECK(GetBackgroundTaskRunner()->BelongsToCurrentThread()); if (!changes.empty()) { - observers_->Notify(&Observer::OnLoginsChanged, changes); + observers_->Notify(FROM_HERE, &Observer::OnLoginsChanged, changes); #if defined(PASSWORD_MANAGER_ENABLE_SYNC) if (syncable_service_) syncable_service_->ActOnPasswordStoreChanges(changes); diff --git a/components/storage_monitor/storage_monitor.cc b/components/storage_monitor/storage_monitor.cc index f82995d..0f1f6cc 100644 --- a/components/storage_monitor/storage_monitor.cc +++ b/components/storage_monitor/storage_monitor.cc @@ -172,7 +172,7 @@ void StorageMonitor::ProcessAttach(const StorageInfo& info) { DVLOG(1) << "StorageAttached id " << info.device_id(); if (StorageInfo::IsRemovableDevice(info.device_id())) { observer_list_->Notify( - &RemovableStorageObserver::OnRemovableStorageAttached, info); + FROM_HERE, &RemovableStorageObserver::OnRemovableStorageAttached, info); } } @@ -190,7 +190,7 @@ void StorageMonitor::ProcessDetach(const std::string& id) { DVLOG(1) << "StorageDetached for id " << id; if (StorageInfo::IsRemovableDevice(info.device_id())) { observer_list_->Notify( - &RemovableStorageObserver::OnRemovableStorageDetached, info); + FROM_HERE, &RemovableStorageObserver::OnRemovableStorageDetached, info); } } diff --git a/content/browser/gpu/gpu_data_manager_impl_private.cc b/content/browser/gpu/gpu_data_manager_impl_private.cc index 76bfd57..06d083b 100644 --- a/content/browser/gpu/gpu_data_manager_impl_private.cc +++ b/content/browser/gpu/gpu_data_manager_impl_private.cc @@ -584,7 +584,8 @@ void GpuDataManagerImplPrivate::UpdateGpuInfo(const gpu::GPUInfo& gpu_info) { void GpuDataManagerImplPrivate::UpdateVideoMemoryUsageStats( const GPUVideoMemoryUsageStats& video_memory_usage_stats) { GpuDataManagerImpl::UnlockedSession session(owner_); - observer_list_->Notify(&GpuDataManagerObserver::OnVideoMemoryUsageStatsUpdate, + observer_list_->Notify(FROM_HERE, + &GpuDataManagerObserver::OnVideoMemoryUsageStatsUpdate, video_memory_usage_stats); } @@ -795,7 +796,7 @@ void GpuDataManagerImplPrivate::ProcessCrashed( gpu_info_.process_crash_count = GpuProcessHost::gpu_crash_count(); GpuDataManagerImpl::UnlockedSession session(owner_); observer_list_->Notify( - &GpuDataManagerObserver::OnGpuProcessCrashed, exit_code); + FROM_HERE, &GpuDataManagerObserver::OnGpuProcessCrashed, exit_code); } } @@ -998,7 +999,7 @@ void GpuDataManagerImplPrivate::UpdateGpuSwitchingManager( } void GpuDataManagerImplPrivate::NotifyGpuInfoUpdate() { - observer_list_->Notify(&GpuDataManagerObserver::OnGpuInfoUpdate); + observer_list_->Notify(FROM_HERE, &GpuDataManagerObserver::OnGpuInfoUpdate); } void GpuDataManagerImplPrivate::EnableSwiftShaderIfNecessary() { @@ -1131,7 +1132,7 @@ void GpuDataManagerImplPrivate::Notify3DAPIBlocked(const GURL& url, int render_view_id, ThreeDAPIType requester) { GpuDataManagerImpl::UnlockedSession session(owner_); - observer_list_->Notify(&GpuDataManagerObserver::DidBlock3DAPIs, + observer_list_->Notify(FROM_HERE, &GpuDataManagerObserver::DidBlock3DAPIs, url, render_process_id, render_view_id, requester); } diff --git a/content/browser/service_worker/service_worker_context_core.cc b/content/browser/service_worker/service_worker_context_core.cc index 5c34692..9203870 100644 --- a/content/browser/service_worker/service_worker_context_core.cc +++ b/content/browser/service_worker/service_worker_context_core.cc @@ -303,7 +303,8 @@ void ServiceWorkerContextCore::RegistrationComplete( DCHECK(registration); callback.Run(status, status_message, registration->id()); if (observer_list_.get()) { - observer_list_->Notify(&ServiceWorkerContextObserver::OnRegistrationStored, + observer_list_->Notify(FROM_HERE, + &ServiceWorkerContextObserver::OnRegistrationStored, pattern); } } @@ -315,7 +316,8 @@ void ServiceWorkerContextCore::UnregistrationComplete( ServiceWorkerStatusCode status) { callback.Run(status); if (observer_list_.get()) { - observer_list_->Notify(&ServiceWorkerContextObserver::OnRegistrationDeleted, + observer_list_->Notify(FROM_HERE, + &ServiceWorkerContextObserver::OnRegistrationDeleted, registration_id, pattern); } } @@ -439,26 +441,27 @@ void ServiceWorkerContextCore::TransferProviderHostIn( void ServiceWorkerContextCore::OnWorkerStarted(ServiceWorkerVersion* version) { if (!observer_list_.get()) return; - observer_list_->Notify(&ServiceWorkerContextObserver::OnWorkerStarted, - version->version_id(), - version->embedded_worker()->process_id(), - version->embedded_worker()->thread_id()); + observer_list_->Notify( + FROM_HERE, &ServiceWorkerContextObserver::OnWorkerStarted, + version->version_id(), version->embedded_worker()->process_id(), + version->embedded_worker()->thread_id()); } void ServiceWorkerContextCore::OnWorkerStopped(ServiceWorkerVersion* version) { if (!observer_list_.get()) return; - observer_list_->Notify(&ServiceWorkerContextObserver::OnWorkerStopped, - version->version_id(), - version->embedded_worker()->process_id(), - version->embedded_worker()->thread_id()); + observer_list_->Notify( + FROM_HERE, &ServiceWorkerContextObserver::OnWorkerStopped, + version->version_id(), version->embedded_worker()->process_id(), + version->embedded_worker()->thread_id()); } void ServiceWorkerContextCore::OnVersionStateChanged( ServiceWorkerVersion* version) { if (!observer_list_.get()) return; - observer_list_->Notify(&ServiceWorkerContextObserver::OnVersionStateChanged, + observer_list_->Notify(FROM_HERE, + &ServiceWorkerContextObserver::OnVersionStateChanged, version->version_id()); } @@ -471,12 +474,11 @@ void ServiceWorkerContextCore::OnErrorReported( if (!observer_list_.get()) return; observer_list_->Notify( - &ServiceWorkerContextObserver::OnErrorReported, - version->version_id(), - version->embedded_worker()->process_id(), + FROM_HERE, &ServiceWorkerContextObserver::OnErrorReported, + version->version_id(), version->embedded_worker()->process_id(), version->embedded_worker()->thread_id(), - ServiceWorkerContextObserver::ErrorInfo( - error_message, line_number, column_number, source_url)); + ServiceWorkerContextObserver::ErrorInfo(error_message, line_number, + column_number, source_url)); } void ServiceWorkerContextCore::OnReportConsoleMessage( @@ -489,9 +491,8 @@ void ServiceWorkerContextCore::OnReportConsoleMessage( if (!observer_list_.get()) return; observer_list_->Notify( - &ServiceWorkerContextObserver::OnReportConsoleMessage, - version->version_id(), - version->embedded_worker()->process_id(), + FROM_HERE, &ServiceWorkerContextObserver::OnReportConsoleMessage, + version->version_id(), version->embedded_worker()->process_id(), version->embedded_worker()->thread_id(), ServiceWorkerContextObserver::ConsoleMessage( source_identifier, message_level, message, line_number, source_url)); diff --git a/content/browser/service_worker/service_worker_context_wrapper.cc b/content/browser/service_worker/service_worker_context_wrapper.cc index d66de44..5faa7d0 100644 --- a/content/browser/service_worker/service_worker_context_wrapper.cc +++ b/content/browser/service_worker/service_worker_context_wrapper.cc @@ -428,7 +428,8 @@ void ServiceWorkerContextWrapper::DidDeleteAndStartOver( context_core_.reset(new ServiceWorkerContextCore(context_core_.get(), this)); DVLOG(1) << "Restarted ServiceWorkerContextCore successfully."; - observer_list_->Notify(&ServiceWorkerContextObserver::OnStorageWiped); + observer_list_->Notify(FROM_HERE, + &ServiceWorkerContextObserver::OnStorageWiped); } } // namespace content diff --git a/content/renderer/p2p/socket_dispatcher.cc b/content/renderer/p2p/socket_dispatcher.cc index 714d443..06f6b1e 100644 --- a/content/renderer/p2p/socket_dispatcher.cc +++ b/content/renderer/p2p/socket_dispatcher.cc @@ -123,7 +123,7 @@ void P2PSocketDispatcher::UnregisterHostAddressRequest(int id) { void P2PSocketDispatcher::OnNetworkListChanged( const net::NetworkInterfaceList& networks) { network_list_observers_->Notify( - &NetworkListObserver::OnNetworkListChanged, networks); + FROM_HERE, &NetworkListObserver::OnNetworkListChanged, networks); } void P2PSocketDispatcher::OnGetHostAddressResult( diff --git a/extensions/browser/api/storage/storage_api.cc b/extensions/browser/api/storage/storage_api.cc index 38c8e71..da02e87 100644 --- a/extensions/browser/api/storage/storage_api.cc +++ b/extensions/browser/api/storage/storage_api.cc @@ -88,11 +88,9 @@ ExtensionFunction::ResponseValue SettingsFunction::UseWriteResult( return HandleError(result->error(), storage); if (!result->changes().empty()) { - observers_->Notify( - &SettingsObserver::OnSettingsChanged, - extension_id(), - settings_namespace_, - ValueStoreChange::ToJson(result->changes())); + observers_->Notify(FROM_HERE, &SettingsObserver::OnSettingsChanged, + extension_id(), settings_namespace_, + ValueStoreChange::ToJson(result->changes())); } return NoArguments(); diff --git a/media/base/user_input_monitor_linux.cc b/media/base/user_input_monitor_linux.cc index 961a9c8..55675ec 100644 --- a/media/base/user_input_monitor_linux.cc +++ b/media/base/user_input_monitor_linux.cc @@ -294,7 +294,8 @@ void UserInputMonitorLinuxCore::ProcessXEvent(xEvent* event) { SkIPoint position(SkIPoint::Make(event->u.keyButtonPointer.rootX, event->u.keyButtonPointer.rootY)); mouse_listeners_->Notify( - &UserInputMonitor::MouseEventListener::OnMouseMoved, position); + FROM_HERE, &UserInputMonitor::MouseEventListener::OnMouseMoved, + position); } else { ui::EventType type; if (event->u.u.type == KeyPress) { diff --git a/media/base/user_input_monitor_win.cc b/media/base/user_input_monitor_win.cc index 6ac3ad8..d06b824 100644 --- a/media/base/user_input_monitor_win.cc +++ b/media/base/user_input_monitor_win.cc @@ -205,7 +205,7 @@ LRESULT UserInputMonitorWinCore::OnInput(HRAWINPUT input_handle) { position.y = 0; } mouse_listeners_->Notify( - &UserInputMonitor::MouseEventListener::OnMouseMoved, + FROM_HERE, &UserInputMonitor::MouseEventListener::OnMouseMoved, SkIPoint::Make(position.x, position.y)); } else if (input->header.dwType == RIM_TYPEKEYBOARD && input->header.hDevice != NULL) { diff --git a/net/android/network_change_notifier_delegate_android.cc b/net/android/network_change_notifier_delegate_android.cc index 99a6cc2..f623b14 100644 --- a/net/android/network_change_notifier_delegate_android.cc +++ b/net/android/network_change_notifier_delegate_android.cc @@ -97,7 +97,7 @@ void NetworkChangeNotifierDelegateAndroid::NotifyConnectionTypeChanged( const ConnectionType actual_connection_type = ConvertConnectionType( new_connection_type); SetCurrentConnectionType(actual_connection_type); - observers_->Notify(&Observer::OnConnectionTypeChanged); + observers_->Notify(FROM_HERE, &Observer::OnConnectionTypeChanged); } jint NetworkChangeNotifierDelegateAndroid::GetConnectionType(JNIEnv*, @@ -113,7 +113,8 @@ void NetworkChangeNotifierDelegateAndroid::NotifyMaxBandwidthChanged( DCHECK(thread_checker_.CalledOnValidThread()); DCHECK(new_max_bandwidth != GetCurrentMaxBandwidth()); SetCurrentMaxBandwidth(new_max_bandwidth); - observers_->Notify(&Observer::OnMaxBandwidthChanged, new_max_bandwidth); + observers_->Notify(FROM_HERE, &Observer::OnMaxBandwidthChanged, + new_max_bandwidth); } void NetworkChangeNotifierDelegateAndroid::AddObserver( diff --git a/net/base/network_change_notifier.cc b/net/base/network_change_notifier.cc index ec45a4e..3ec6369 100644 --- a/net/base/network_change_notifier.cc +++ b/net/base/network_change_notifier.cc @@ -949,29 +949,31 @@ void NetworkChangeNotifier::SetDnsConfig(const DnsConfig& config) { } void NetworkChangeNotifier::NotifyObserversOfIPAddressChangeImpl() { - ip_address_observer_list_->Notify(&IPAddressObserver::OnIPAddressChanged); + ip_address_observer_list_->Notify(FROM_HERE, + &IPAddressObserver::OnIPAddressChanged); } void NetworkChangeNotifier::NotifyObserversOfConnectionTypeChangeImpl( ConnectionType type) { connection_type_observer_list_->Notify( - &ConnectionTypeObserver::OnConnectionTypeChanged, type); + FROM_HERE, &ConnectionTypeObserver::OnConnectionTypeChanged, type); } void NetworkChangeNotifier::NotifyObserversOfNetworkChangeImpl( ConnectionType type) { network_change_observer_list_->Notify( - &NetworkChangeObserver::OnNetworkChanged, type); + FROM_HERE, &NetworkChangeObserver::OnNetworkChanged, type); } void NetworkChangeNotifier::NotifyObserversOfDNSChangeImpl() { - resolver_state_observer_list_->Notify(&DNSObserver::OnDNSChanged); + resolver_state_observer_list_->Notify(FROM_HERE, &DNSObserver::OnDNSChanged); } void NetworkChangeNotifier::NotifyObserversOfMaxBandwidthChangeImpl( double max_bandwidth_mbps) { max_bandwidth_observer_list_->Notify( - &MaxBandwidthObserver::OnMaxBandwidthChanged, max_bandwidth_mbps); + FROM_HERE, &MaxBandwidthObserver::OnMaxBandwidthChanged, + max_bandwidth_mbps); } NetworkChangeNotifier::DisableForTest::DisableForTest() diff --git a/net/cert/cert_database.cc b/net/cert/cert_database.cc index d6a9b1b..8591122 100644 --- a/net/cert/cert_database.cc +++ b/net/cert/cert_database.cc @@ -25,17 +25,19 @@ void CertDatabase::RemoveObserver(Observer* observer) { } void CertDatabase::NotifyObserversOfCertAdded(const X509Certificate* cert) { - observer_list_->Notify(&Observer::OnCertAdded, make_scoped_refptr(cert)); + observer_list_->Notify(FROM_HERE, &Observer::OnCertAdded, + make_scoped_refptr(cert)); } void CertDatabase::NotifyObserversOfCertRemoved(const X509Certificate* cert) { - observer_list_->Notify(&Observer::OnCertRemoved, make_scoped_refptr(cert)); + observer_list_->Notify(FROM_HERE, &Observer::OnCertRemoved, + make_scoped_refptr(cert)); } void CertDatabase::NotifyObserversOfCACertChanged( const X509Certificate* cert) { - observer_list_->Notify( - &Observer::OnCACertChanged, make_scoped_refptr(cert)); + observer_list_->Notify(FROM_HERE, &Observer::OnCACertChanged, + make_scoped_refptr(cert)); } } // namespace net diff --git a/net/cert/cert_database_android.cc b/net/cert/cert_database_android.cc index 6eb964d..144b9a1 100644 --- a/net/cert/cert_database_android.cc +++ b/net/cert/cert_database_android.cc @@ -48,7 +48,7 @@ void CertDatabase::OnAndroidKeyStoreChanged() { } void CertDatabase::OnAndroidKeyChainChanged() { - observer_list_->Notify(&Observer::OnCACertChanged, + observer_list_->Notify(FROM_HERE, &Observer::OnCACertChanged, scoped_refptr<X509Certificate>()); } diff --git a/net/cert/nss_cert_database.cc b/net/cert/nss_cert_database.cc index 8e9c692d..e1b3198 100644 --- a/net/cert/nss_cert_database.cc +++ b/net/cert/nss_cert_database.cc @@ -438,18 +438,20 @@ void NSSCertDatabase::NotifyCertRemovalAndCallBack( } void NSSCertDatabase::NotifyObserversOfCertAdded(const X509Certificate* cert) { - observer_list_->Notify(&Observer::OnCertAdded, make_scoped_refptr(cert)); + observer_list_->Notify(FROM_HERE, &Observer::OnCertAdded, + make_scoped_refptr(cert)); } void NSSCertDatabase::NotifyObserversOfCertRemoved( const X509Certificate* cert) { - observer_list_->Notify(&Observer::OnCertRemoved, make_scoped_refptr(cert)); + observer_list_->Notify(FROM_HERE, &Observer::OnCertRemoved, + make_scoped_refptr(cert)); } void NSSCertDatabase::NotifyObserversOfCACertChanged( const X509Certificate* cert) { - observer_list_->Notify( - &Observer::OnCACertChanged, make_scoped_refptr(cert)); + observer_list_->Notify(FROM_HERE, &Observer::OnCACertChanged, + make_scoped_refptr(cert)); } // static diff --git a/remoting/host/linux/audio_pipe_reader.cc b/remoting/host/linux/audio_pipe_reader.cc index 88d0998..cd293f5 100644 --- a/remoting/host/linux/audio_pipe_reader.cc +++ b/remoting/host/linux/audio_pipe_reader.cc @@ -193,7 +193,7 @@ void AudioPipeReader::DoCapture() { // Dispatch asynchronous notification to the stream observers. scoped_refptr<base::RefCountedString> data_ref = base::RefCountedString::TakeString(&data); - observers_->Notify(&StreamObserver::OnDataRead, data_ref); + observers_->Notify(FROM_HERE, &StreamObserver::OnDataRead, data_ref); } void AudioPipeReader::WaitForPipeReadable() { diff --git a/ui/compositor/compositor_vsync_manager.cc b/ui/compositor/compositor_vsync_manager.cc index 1a10d4a..17336e6 100644 --- a/ui/compositor/compositor_vsync_manager.cc +++ b/ui/compositor/compositor_vsync_manager.cc @@ -55,9 +55,8 @@ void CompositorVSyncManager::RemoveObserver(Observer* observer) { void CompositorVSyncManager::NotifyObservers(base::TimeTicks timebase, base::TimeDelta interval) { observer_list_->Notify( - &CompositorVSyncManager::Observer::OnUpdateVSyncParameters, - timebase, - interval); + FROM_HERE, &CompositorVSyncManager::Observer::OnUpdateVSyncParameters, + timebase, interval); } } // namespace ui |