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

Side by Side Diff: ui/display/manager/display_manager.cc

Issue 2561963002: base: Remove the string logging from CHECK(). (Closed)
Patch Set: checkstring: rebase Created 4 years 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 "ui/display/manager/display_manager.h" 5 #include "ui/display/manager/display_manager.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 #include <limits> 9 #include <limits>
10 #include <map> 10 #include <map>
(...skipping 871 matching lines...) Expand 10 before | Expand all | Expand 10 after
882 return multi_display_mode_ == UNIFIED && 882 return multi_display_mode_ == UNIFIED &&
883 !software_mirroring_display_list_.empty(); 883 !software_mirroring_display_list_.empty();
884 } 884 }
885 885
886 const ManagedDisplayInfo& DisplayManager::GetDisplayInfo( 886 const ManagedDisplayInfo& DisplayManager::GetDisplayInfo(
887 int64_t display_id) const { 887 int64_t display_id) const {
888 DCHECK_NE(kInvalidDisplayId, display_id); 888 DCHECK_NE(kInvalidDisplayId, display_id);
889 889
890 std::map<int64_t, ManagedDisplayInfo>::const_iterator iter = 890 std::map<int64_t, ManagedDisplayInfo>::const_iterator iter =
891 display_info_.find(display_id); 891 display_info_.find(display_id);
892 CHECK(iter != display_info_.end()) << display_id; 892 CHECK(iter != display_info_.end());
893 return iter->second; 893 return iter->second;
894 } 894 }
895 895
896 const Display DisplayManager::GetMirroringDisplayById( 896 const Display DisplayManager::GetMirroringDisplayById(
897 int64_t display_id) const { 897 int64_t display_id) const {
898 auto iter = std::find_if(software_mirroring_display_list_.begin(), 898 auto iter = std::find_if(software_mirroring_display_list_.begin(),
899 software_mirroring_display_list_.end(), 899 software_mirroring_display_list_.end(),
900 [display_id](const Display& display) { 900 [display_id](const Display& display) {
901 return display.id() == display_id; 901 return display.id() == display_id;
902 }); 902 });
(...skipping 533 matching lines...) Expand 10 before | Expand all | Expand 10 after
1436 } 1436 }
1437 1437
1438 const Display& DisplayManager::GetSecondaryDisplay() const { 1438 const Display& DisplayManager::GetSecondaryDisplay() const {
1439 CHECK_LE(2U, GetNumDisplays()); 1439 CHECK_LE(2U, GetNumDisplays());
1440 return GetDisplayAt(0).id() == Screen::GetScreen()->GetPrimaryDisplay().id() 1440 return GetDisplayAt(0).id() == Screen::GetScreen()->GetPrimaryDisplay().id()
1441 ? GetDisplayAt(1) 1441 ? GetDisplayAt(1)
1442 : GetDisplayAt(0); 1442 : GetDisplayAt(0);
1443 } 1443 }
1444 1444
1445 } // namespace display 1445 } // namespace display
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698