monitor: Attach to backend instead of GPU

Prepare for the future when a monitor isn't necessarily attached to a
mode setting device, which is practically what MetaGpu represents.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1698>
This commit is contained in:
Jonas Ådahl
2021-01-26 14:49:25 +01:00
committed by Marge Bot
parent 19c4667d6a
commit 6aef4b3970
5 changed files with 17 additions and 21 deletions

View File

@ -985,9 +985,10 @@ calculate_cursor_sprite_gpus (MetaCursorRenderer *renderer,
for (l_mon = monitors; l_mon; l_mon = l_mon->next)
{
MetaMonitor *monitor = l_mon->data;
MetaOutput *output = meta_monitor_get_main_output (monitor);
MetaGpu *gpu;
gpu = meta_monitor_get_gpu (monitor);
gpu = meta_output_get_gpu (output);
if (!g_list_find (gpus, gpu))
gpus = g_list_prepend (gpus, gpu);
}