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

Unified Diff: chromeos/display/output_configurator.cc

Issue 10974014: Disable extended desktop. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updated comments. keep pointer inside root Created 8 years, 3 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
Index: chromeos/display/output_configurator.cc
diff --git a/chromeos/display/output_configurator.cc b/chromeos/display/output_configurator.cc
index 6fb573a37b4646d9c84023d22922e4dad912e0cc..66a5b17601dbbe6e411cd19e90dd68635b581add 100644
--- a/chromeos/display/output_configurator.cc
+++ b/chromeos/display/output_configurator.cc
@@ -255,9 +255,11 @@ static int GetDualOutputs(Display* display,
to_populate->mirror_mode = 0;
// See if this output refers to an internal display.
+ // TODO(oshmia): Use |IsInternalOutputName| once the change is merged
+ // to m23. crbug.com/152003.
+ const std::string name(output_info->name);
to_populate->is_internal =
- OutputConfigurator::IsInternalOutputName(
- std::string(output_info->name));
+ name.find(kInternal_LVDS) == 0 || name.find(kInternal_eDP) == 0;
VLOG(1) << "Found display #" << found_count
<< " with output " << (int)to_populate->output
@@ -375,8 +377,13 @@ static OutputState GetNextState(Display* display,
(0 != outputs[1].mirror_mode);
switch (current_state) {
case STATE_DUAL_PRIMARY_ONLY:
- state =
- mirror_supported ? STATE_DUAL_MIRROR : STATE_DUAL_PRIMARY_ONLY;
+ // TODO(oshima): Temporarily disable extended
+ // desktop. crbug.com/152003.
+ state = STATE_DUAL_SECONDARY_ONLY;
+ break;
+ case STATE_DUAL_SECONDARY_ONLY:
+ state = mirror_supported ?
+ STATE_DUAL_MIRROR : STATE_DUAL_PRIMARY_ONLY;
break;
case STATE_DUAL_MIRROR:
state = STATE_DUAL_PRIMARY_ONLY;
@@ -834,7 +841,9 @@ void OutputConfigurator::RemoveObserver(Observer* observer) {
// static
bool OutputConfigurator::IsInternalOutputName(const std::string& name) {
- return name.find(kInternal_LVDS) == 0 || name.find(kInternal_eDP) == 0;
+ // TODO(oshima): There is only one display for m23 and no need to
+ // distinguish internal display.
+ return false;
}
void OutputConfigurator::NotifyOnDisplayChanged() {
« no previous file with comments | « chrome/browser/ui/webui/options/chromeos/display_options_handler.cc ('k') | ui/aura/display_change_observer_x11.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698