Showing
2 changed files
with
13 additions
and
2 deletions
| ... | @@ -419,7 +419,7 @@ import SwiftEventBus | ... | @@ -419,7 +419,7 @@ import SwiftEventBus |
| 419 | print("BOX coupon banner pressed!") | 419 | print("BOX coupon banner pressed!") |
| 420 | 420 | ||
| 421 | // box_analysis_pressed event | 421 | // box_analysis_pressed event |
| 422 | - let dealsAnalysis = swiftApi.WarplyBoxAnalysisEventModel() | 422 | + let dealsAnalysis = swiftApi.WarplyBoxAnalysisEventModel(self) |
| 423 | dealsAnalysis._isPressed = true | 423 | dealsAnalysis._isPressed = true |
| 424 | SwiftEventBus.post("box_analysis_pressed", sender: dealsAnalysis) | 424 | SwiftEventBus.post("box_analysis_pressed", sender: dealsAnalysis) |
| 425 | // SwiftEventBus.post("box_analysis_pressed") | 425 | // SwiftEventBus.post("box_analysis_pressed") | ... | ... |
| ... | @@ -4922,9 +4922,11 @@ public class swiftApi { | ... | @@ -4922,9 +4922,11 @@ public class swiftApi { |
| 4922 | 4922 | ||
| 4923 | public class WarplyBoxAnalysisEventModel { | 4923 | public class WarplyBoxAnalysisEventModel { |
| 4924 | private var isPressed: Bool | 4924 | private var isPressed: Bool |
| 4925 | + private var vc: UIViewController | ||
| 4925 | 4926 | ||
| 4926 | - public init() { | 4927 | + public init(_ controller: UIViewController) { |
| 4927 | self.isPressed = false | 4928 | self.isPressed = false |
| 4929 | + self.vc = controller | ||
| 4928 | } | 4930 | } |
| 4929 | 4931 | ||
| 4930 | public var _isPressed: Bool { | 4932 | public var _isPressed: Bool { |
| ... | @@ -4935,6 +4937,15 @@ public class swiftApi { | ... | @@ -4935,6 +4937,15 @@ public class swiftApi { |
| 4935 | self.isPressed = newValue | 4937 | self.isPressed = newValue |
| 4936 | } | 4938 | } |
| 4937 | } | 4939 | } |
| 4940 | + | ||
| 4941 | + public var _vc: UIViewController { | ||
| 4942 | + get { // getter | ||
| 4943 | + return self.vc | ||
| 4944 | + } | ||
| 4945 | + set(newValue) { //setter | ||
| 4946 | + self.vc = newValue | ||
| 4947 | + } | ||
| 4948 | + } | ||
| 4938 | } | 4949 | } |
| 4939 | 4950 | ||
| 4940 | 4951 | ... | ... |
-
Please register or login to post a comment