/
githubmirror
/
PowerToys
Обзор
Документация
Войти
/
githubmirror
/
PowerToys
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/modules/powerdisplay/PowerDisplay.Models/ProfileMonitorSetting.cs
51 строка
2 KB
moooyo
[PowerDisplay] Stable monitor Id + survive transient discovery failures (#47712)
08 май 2026, 10:25
Не верифицирован
08 май 2026, 10:25
95b7055
Код
Авторство
О чём код?
// Copyright (c) Microsoft Corporation // The Microsoft Corporation licenses this file to you under the MIT license. // See the LICENSE file in the project root for more information. using System.Text.Json.Serialization; namespace PowerDisplay.Models { /// <summary> /// Monitor settings for a specific profile /// </summary> public class ProfileMonitorSetting { /// <summary> /// Gets or sets the monitor's unique identifier. /// Format: the DevicePath form documented on <see cref="PowerDisplay.Common.Models.Monitor.Id"/>. /// </summary> [JsonPropertyName("monitorId")] public string MonitorId { get; set; } [JsonPropertyName("brightness")] public int? Brightness { get; set; } [JsonPropertyName("contrast")] public int? Contrast { get; set; } [JsonPropertyName("volume")] public int? Volume { get; set; } /// <summary> /// Gets or sets the color temperature VCP preset value. /// JSON property name kept as "colorTemperature" for backward compatibility. /// </summary> [JsonPropertyName("colorTemperature")] public int? ColorTemperatureVcp { get; set; } public ProfileMonitorSetting() { MonitorId = string.Empty; } public ProfileMonitorSetting(string monitorId, int? brightness = null, int? colorTemperatureVcp = null, int? contrast = null, int? volume = null) { MonitorId = monitorId; Brightness = brightness; ColorTemperatureVcp = colorTemperatureVcp; Contrast = contrast; Volume = volume; } } }