From 7c9834a392e0209b9f7417071e3c5114a791a9bd Mon Sep 17 00:00:00 2001 From: Damian <> Date: Tue, 10 Dec 2019 21:34:14 +0000 Subject: [PATCH] 98_DOIF.pm: fixed uiTable function icon, switch git-svn-id: https://svn.fhem.de/fhem/trunk@20708 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/FHEM/98_DOIF.pm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/fhem/FHEM/98_DOIF.pm b/fhem/FHEM/98_DOIF.pm index 17ee9274a..a47b65163 100644 --- a/fhem/FHEM/98_DOIF.pm +++ b/fhem/FHEM/98_DOIF.pm @@ -3852,18 +3852,18 @@ sub FW_makeImage { my ($value,$icon_off,$icon_on,$state_off,$state_on)=@_; $state_on=(defined ($state_on) and $state_on ne "") ? $state_on : "on"; $state_off=(defined ($state_off) and $state_off ne "") ? $state_off : "off"; - $icon_off=(defined ($icon_off) and $icon_off ne "") ? $icon_off : "off"; - $icon_on=((defined ($icon_on) and $icon_on ne "") ? $icon_on : "$icon_off\@DarkOrange"); - return($value,"",("iconSwitch,".$state_on.",".$icon_off.",".$state_off.",".$icon_on)); + my $i_off=(defined ($icon_off) and $icon_off ne "") ? $icon_off : "off"; + $icon_on=((defined ($icon_on) and $icon_on ne "") ? $icon_on :(defined ($icon_off) and $icon_off ne "") ? "$icon_off\@DarkOrange" : "on"); + return($value,"",("iconSwitch,".$state_on.",".$i_off.",".$state_off.",".$icon_on)); } sub icon { my ($value,$icon_off,$icon_on,$state_off,$state_on)=@_; $state_on=(defined ($state_on) and $state_on ne "") ? $state_on : "on"; $state_off=(defined ($state_off) and $state_off ne "") ? $state_off : "off"; - $icon_off=(defined ($icon_off) and $icon_off ne "") ? $icon_off : "off"; - $icon_on=((defined ($icon_on) and $icon_on ne "") ? $icon_on : "$icon_off\@DarkOrange"); - return($value,"",("iconLabel,".$state_on.",".$icon_on.",".$state_off.",".$icon_off)); + my $i_off=(defined ($icon_off) and $icon_off ne "") ? $icon_off : "off"; + $icon_on=((defined ($icon_on) and $icon_on ne "") ? $icon_on :(defined ($icon_off) and $icon_off ne "") ? "$icon_off\@DarkOrange" : "on"); + return($value,"",("iconLabel,".$state_on.",".$icon_on.",".$state_off.",".$i_off)); } 1;