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

Side by Side Diff: chrome/browser/chromeos/login/screens/network_screen.cc

Issue 2416763002: Replace FOR_EACH_OBSERVER in c/b/chromeos with range-based for (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
OLDNEW
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/chromeos/login/screens/network_screen.h" 5 #include "chrome/browser/chromeos/login/screens/network_screen.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/location.h" 9 #include "base/location.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 421 matching lines...) Expand 10 before | Expand all | Expand 10 after
432 DCHECK_CURRENTLY_ON(content::BrowserThread::UI); 432 DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
433 433
434 language_list_ = std::move(new_language_list); 434 language_list_ = std::move(new_language_list);
435 language_list_locale_ = new_language_list_locale; 435 language_list_locale_ = new_language_list_locale;
436 selected_language_code_ = new_selected_language; 436 selected_language_code_ = new_selected_language;
437 437
438 g_browser_process->local_state()->SetString(prefs::kApplicationLocale, 438 g_browser_process->local_state()->SetString(prefs::kApplicationLocale,
439 selected_language_code_); 439 selected_language_code_);
440 if (view_) 440 if (view_)
441 view_->ReloadLocalizedContent(); 441 view_->ReloadLocalizedContent();
442 FOR_EACH_OBSERVER(Observer, observers_, OnLanguageListReloaded()); 442 for (auto& observer : observers_)
443 observer.OnLanguageListReloaded();
443 } 444 }
444 445
445 void NetworkScreen::OnSystemTimezoneChanged() { 446 void NetworkScreen::OnSystemTimezoneChanged() {
446 std::string current_timezone_id; 447 std::string current_timezone_id;
447 CrosSettings::Get()->GetString(kSystemTimezone, &current_timezone_id); 448 CrosSettings::Get()->GetString(kSystemTimezone, &current_timezone_id);
448 GetContextEditor().SetString(kContextKeyTimezone, current_timezone_id); 449 GetContextEditor().SetString(kContextKeyTimezone, current_timezone_id);
449 } 450 }
450 451
451 } // namespace chromeos 452 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698