monitor-manager: Make the config manager an 'experimental feature'

Instead of using a environment variable, add a new 'experimental
feature' gsetting keyword "monitor-config-manager" that enables the use
of the new MetaMonitorConfigManager. This commit also makes it possible
to switch between the two systems without restarting mutter.

The D-Bus API is disabled when the experimental feature is not enabled,
and clients trying to access it will get a access-denied error in
response. A new property 'IsExperimentalApiEnabled' is added to let the
D-Bus client know whether it is possible to use the experimental API or
not.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
This commit is contained in:
Jonas Ådahl
2017-03-04 15:30:56 +08:00
parent 57acbc53fb
commit 0c64c35a8a
10 changed files with 99 additions and 37 deletions

View File

@ -219,9 +219,15 @@ run_tests (gpointer data)
meta_backend_override_experimental_features (backend);
meta_backend_enable_experimental_feature (
backend,
META_EXPERIMENTAL_FEATURE_SCALE_MONITOR_FRAMEBUFFER);
if (g_strcmp0 (g_getenv ("MUTTER_USE_CONFIG_MANAGER"), "1") == 0)
{
meta_backend_enable_experimental_feature (
backend,
META_EXPERIMENTAL_FEATURE_MONITOR_CONFIG_MANAGER);
meta_backend_enable_experimental_feature (
backend,
META_EXPERIMENTAL_FEATURE_SCALE_MONITOR_FRAMEBUFFER);
}
ret = g_test_run ();