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

Unified Diff: ui/views/mus/screen_mus.cc

Issue 1905893002: Revert of Makes ScreenMus not check that displays are non-empty (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/mus/screen_mus.cc
diff --git a/ui/views/mus/screen_mus.cc b/ui/views/mus/screen_mus.cc
index 1a66fa864d6bcfea27c0062a17de6d4c488da384..faa31ad3463dc1ac9b46a703fc11236c1faf2e7b 100644
--- a/ui/views/mus/screen_mus.cc
+++ b/ui/views/mus/screen_mus.cc
@@ -98,14 +98,8 @@
// from running on the calling thread. http://crbug.com/594852.
display_manager_observer_binding_.WaitForIncomingMethodCall();
- // The WaitForIncomingMethodCall() should have supplied the set of Displays,
- // unless mus is going down, in which case encountered_error() is true.
- if (displays_.empty()) {
- DCHECK(display_manager_.encountered_error());
- // In this case we install a default display and assume the process is
- // going to exit shortly so that the real value doesn't matter.
- displays_.push_back(gfx::Display(0xFFFFFFFF, gfx::Rect(0, 0, 801, 802)));
- }
+ // The WaitForIncomingMethodCall() should have supplied the set of Displays.
+ DCHECK(displays_.size());
}
int ScreenMus::FindDisplayIndexById(int64_t id) const {
@@ -213,7 +207,6 @@
// added.
DCHECK(displays_.empty());
displays_ = displays.To<std::vector<gfx::Display>>();
- DCHECK(!displays_.empty());
for (size_t i = 0; i < displays.size(); ++i) {
if (displays[i]->is_primary) {
primary_display_index_ = static_cast<int>(i);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698