From 48281da2e1244ecc79091ea81028d4de49fd8d36 Mon Sep 17 00:00:00 2001 From: Matt Bruce Date: Thu, 12 Jan 2023 08:10:53 -0600 Subject: [PATCH] fixed bug for enable hightlight Signed-off-by: Matt Bruce --- VDS/Publishers/UIControlPublisher.swift | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/VDS/Publishers/UIControlPublisher.swift b/VDS/Publishers/UIControlPublisher.swift index 404fe7c5..dca48c3f 100644 --- a/VDS/Publishers/UIControlPublisher.swift +++ b/VDS/Publishers/UIControlPublisher.swift @@ -13,10 +13,12 @@ import Combine public final class UIControlSubscription: Subscription where SubscriberType.Input == Control { private var subscriber: SubscriberType? private let control: Control - + private let event: UIControl.Event + public init(subscriber: SubscriberType, control: Control, event: UIControl.Event) { self.subscriber = subscriber self.control = control + self.event = event //allow highlight for VDS.Controls on "onClick" events if let c = control as? VDS.Control, event == .touchUpInside { @@ -34,6 +36,13 @@ public final class UIControlSubscription