monitor: Add display name

The display name is being used by the monitor manager to expose to name
to the DBUS API.

It is being rebuilt each time, so instead build the displa yname once
for the monitor and keep it around, with an API to retrieve it, so that
we can reuse it in preparation of xdg-output v2 support.

https://gitlab.gnome.org/GNOME/mutter/issues/645
This commit is contained in:
Olivier Fourdan
2019-06-26 11:24:19 +02:00
parent c3c6668343
commit 6541d49fe7
3 changed files with 120 additions and 5 deletions

View File

@ -2734,7 +2734,7 @@ rebuild_monitors (MetaMonitorManager *manager)
{
MetaMonitorNormal *monitor_normal;
monitor_normal = meta_monitor_normal_new (gpu, output);
monitor_normal = meta_monitor_normal_new (gpu, manager, output);
manager->monitors = g_list_append (manager->monitors,
monitor_normal);
}