monitor: Make the connector the last sort key for monitors
We want to ignore the connector in certain situations. Prepare this by changing the sort order so that two monitors will be paired up in the list if only the connector is different. https://gitlab.gnome.org/GNOME/mutter/issues/932
This commit is contained in:
parent
98d7a542b0
commit
0d27c7ee1d
@ -140,10 +140,6 @@ meta_monitor_spec_compare (MetaMonitorSpec *monitor_spec_a,
|
||||
{
|
||||
int ret;
|
||||
|
||||
ret = strcmp (monitor_spec_a->connector, monitor_spec_b->connector);
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
|
||||
ret = strcmp (monitor_spec_a->vendor, monitor_spec_b->vendor);
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
@ -152,7 +148,15 @@ meta_monitor_spec_compare (MetaMonitorSpec *monitor_spec_a,
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
|
||||
return strcmp (monitor_spec_a->serial, monitor_spec_b->serial);
|
||||
ret = strcmp (monitor_spec_a->serial, monitor_spec_b->serial);
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
|
||||
ret = strcmp (monitor_spec_a->connector, monitor_spec_b->connector);
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void
|
||||
|
Loading…
x
Reference in New Issue
Block a user