Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(62)

Side by Side Diff: blimp/engine/app/settings_manager.cc

Issue 2425493002: Remove usage of FOR_EACH_OBSERVER macro in blimp (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « blimp/client/core/session/connection_status.cc ('k') | blimp/engine/app/ui/blimp_screen.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 <blimp/engine/app/settings_manager.h> 5 #include <blimp/engine/app/settings_manager.h>
6 #include "content/public/browser/render_view_host.h" 6 #include "content/public/browser/render_view_host.h"
7 #include "content/public/common/web_preferences.h" 7 #include "content/public/common/web_preferences.h"
8 8
9 namespace blimp { 9 namespace blimp {
10 namespace engine { 10 namespace engine {
(...skipping 25 matching lines...) Expand all
36 const EngineSettings& SettingsManager::GetEngineSettings() const { 36 const EngineSettings& SettingsManager::GetEngineSettings() const {
37 return settings_; 37 return settings_;
38 } 38 }
39 39
40 void SettingsManager::UpdateEngineSettings(const EngineSettings& settings) { 40 void SettingsManager::UpdateEngineSettings(const EngineSettings& settings) {
41 EngineSettings old_settings = settings_; 41 EngineSettings old_settings = settings_;
42 settings_ = settings; 42 settings_ = settings;
43 43
44 if (settings_.record_whole_document != old_settings.record_whole_document) { 44 if (settings_.record_whole_document != old_settings.record_whole_document) {
45 // Notify the observers that the web preferences have changed. 45 // Notify the observers that the web preferences have changed.
46 FOR_EACH_OBSERVER(Observer, observer_list_, OnWebPreferencesChanged()); 46 for (auto& observer : observer_list_)
47 observer.OnWebPreferencesChanged();
47 } 48 }
48 } 49 }
49 50
50 } // namespace engine 51 } // namespace engine
51 } // namespace blimp 52 } // namespace blimp
OLDNEW
« no previous file with comments | « blimp/client/core/session/connection_status.cc ('k') | blimp/engine/app/ui/blimp_screen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698