mirror of
https://github.com/python-kasa/python-kasa.git
synced 2025-08-09 20:24:02 +00:00
Fix changing brightness when effect is active (#1019)
This PR changes the behavior of `brightness` module if an effect is active. Currently, changing the brightness disables the effect when the brightness is changed, this fixes that. This will also improve the `set_effect` interface to use the current brightness when an effect is activated. * light_strip_effect: passing `bAdjusted` with the changed properties changes the brightness. * light_effect: the brightness is stored only in the rule, so we modify it when adjusting the brightness. This is also done during the initial effect activation. --------- Co-authored-by: Steven B <51370195+sdb9696@users.noreply.github.com>
This commit is contained in:
@@ -112,6 +112,9 @@ class Module(ABC):
|
||||
"LightTransition"
|
||||
)
|
||||
ReportMode: Final[ModuleName[smart.ReportMode]] = ModuleName("ReportMode")
|
||||
SmartLightEffect: Final[ModuleName[smart.SmartLightEffect]] = ModuleName(
|
||||
"LightEffect"
|
||||
)
|
||||
TemperatureSensor: Final[ModuleName[smart.TemperatureSensor]] = ModuleName(
|
||||
"TemperatureSensor"
|
||||
)
|
||||
|
Reference in New Issue
Block a user