From 074d35cd76a1925f97e011eb9f14eeef6aefbbf4 Mon Sep 17 00:00:00 2001 From: Patrick Pichon Date: Fri, 6 Oct 2023 09:22:49 +0200 Subject: [PATCH] force Invverted to levelcontrol command --- Classes/GroupMgtv2/GrpDomoticz.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Classes/GroupMgtv2/GrpDomoticz.py b/Classes/GroupMgtv2/GrpDomoticz.py index 6b6faf767..04592479b 100644 --- a/Classes/GroupMgtv2/GrpDomoticz.py +++ b/Classes/GroupMgtv2/GrpDomoticz.py @@ -207,6 +207,11 @@ def best_group_widget(self, GroupId): WidgetType = self.ListOfDevices[NwkId]["Ep"][devEp]["ClusterType"][DomoDeviceUnit] self.logging("Debug", "------------ GroupWidget: %s WidgetType: %s" % (GroupWidgetType, WidgetType)) + if WidgetType in ("VenetianInverted", "VanneInverted", "CurtainInverted"): + # Those widgets are commanded via cluster Level Control + GroupWidgetType = "LvlControl" + continue + if GroupWidgetType is None and WidgetType in WIDGET_STYLE: GroupWidgetType = WidgetType continue @@ -240,11 +245,8 @@ def best_group_widget(self, GroupId): GroupWidgetType = WidgetType continue - if WidgetType in ("VenetianInverted", "VanneInverted", "CurtainInverted"): - GroupWidgetType = "LvlControl" - continue - if WidgetType in ("Venetian", "VenetianInverted", "WindowCovering", "BlindPercentInverted"): + if WidgetType in ("Venetian", "WindowCovering", "BlindPercentInverted"): GroupWidgetType = WidgetType if GroupWidgetType is None: