blob: 6a54a39e018debbf38572cb3224daee497f7c99e [file] [log] [blame]
// Copyright 2018 The Chromium OS Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
syntax = "proto2";
option optimize_for = LITE_RUNTIME;
package power_manager;
// Announcement of a backlight brightness change emitted by powerd via a
// ScreenBrightnessChanged or KeyboardBrightnessChanged D-Bus signal.
message BacklightBrightnessChange {
// Backlight brightness as a percent in the range [0.0, 100.0]. See
// https://chromium.googlesource.com/chromiumos/platform2/+/master/power_manager/docs/screen_brightness.md
// for more information about the mapping between percents and hardware
// levels.
optional double percent = 1;
// The reason the brightness was changed.
enum Cause {
// Explicit user request, e.g. brightness keys or brightness slider.
USER_REQUEST = 0;
// Automated change in response to user activity (input event, video
// activity, etc.).
USER_ACTIVITY = 1;
// Automated change triggered by idle timeout due to user inactivity.
USER_INACTIVITY = 2;
// Automated change caused by a change to the ambient light level.
AMBIENT_LIGHT_CHANGED = 3;
// An external power source was connected.
EXTERNAL_POWER_CONNECTED = 4;
// An external power source was disconnected.
EXTERNAL_POWER_DISCONNECTED = 5;
// Backlights were forced off by Chrome (typically due to the user tapping
// the power button on a convertible device).
FORCED_OFF = 6;
// Backlights are no longer being forced off by Chrome.
NO_LONGER_FORCED_OFF = 7;
// Unspecified automated change (suspend/resume, shutdown, etc.).
OTHER = 8;
// Next value to use: 9
}
optional Cause cause = 2;
// Next value to use: 3
}