[mutter/wayland] monitor: expose min-backlight-step



commit cd76313297c59289206c36f3e257cb77df5d4351
Author: Asad Mehmood <asad78611 googlemail com>
Date:   Thu Oct 17 16:05:59 2013 +0100

    monitor: expose min-backlight-step
    
    Expose min-backlight-step so that gnome-settings-daemon can
    support backlights with less than 10 steps without mutter
    normalizing the brightness back to its original value
    
    https://bugzilla.gnome.org/show_bug.cgi?id=710380

 src/core/monitor.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/src/core/monitor.c b/src/core/monitor.c
index 5b5093c..999b23e 100644
--- a/src/core/monitor.c
+++ b/src/core/monitor.c
@@ -729,6 +729,9 @@ meta_monitor_manager_handle_get_resources (MetaDBusDisplayConfig *skeleton,
                              g_variant_new_take_string (make_display_name (manager, output)));
       g_variant_builder_add (&properties, "{sv}", "backlight",
                              g_variant_new_int32 (output->backlight));
+      g_variant_builder_add (&properties, "{sv}", "min-backlight-step",
+                             g_variant_new_int32 ((output->backlight_max - output->backlight_min) ?
+                                                  100 / (output->backlight_max - output->backlight_min) : 
-1));
       g_variant_builder_add (&properties, "{sv}", "primary",
                              g_variant_new_boolean (output->is_primary));
       g_variant_builder_add (&properties, "{sv}", "presentation",


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]