mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-04 22:19:38 +00:00
31_HUEDevice.pm: set desired for lights if group is switched
git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@23164 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
b6da64a2fb
commit
4773044462
@ -957,6 +957,16 @@ HUEDevice_Set($@)
|
|||||||
if( %obj ) {
|
if( %obj ) {
|
||||||
if( defined($obj{on}) ) {
|
if( defined($obj{on}) ) {
|
||||||
$hash->{desired} = $obj{on}?1:0;
|
$hash->{desired} = $obj{on}?1:0;
|
||||||
|
|
||||||
|
if( defined($hash->{lights}) ) {
|
||||||
|
foreach my $light ( split(',', $hash->{lights}) ) {
|
||||||
|
next if( !$light );
|
||||||
|
my $code = $light;
|
||||||
|
$code = $hash->{IODev}->{NAME} ."-". $code if( defined($hash->{IODev}) );
|
||||||
|
next if( !defined($modules{HUEDevice}{defptr}{$code}) );
|
||||||
|
$modules{HUEDevice}{defptr}{$code}->{desired} = $hash->{desired};
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if( !defined($obj{transitiontime}) ) {
|
if( !defined($obj{transitiontime}) ) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user