-
-
Notifications
You must be signed in to change notification settings - Fork 65
Popup Dismissal
Tomasz K. edited this page Oct 31, 2024
·
33 revisions
Przez chwilę nic się nie działo. Potem - po jakiejś sekundzie - nadal nic się nie działo.
Dismissing a popup can be done in two ways - If you are working within the context of a View
, simply call one of the functions described below. Otherwise (e.g., if you want to dismiss the popup from a ViewModel
), prefix the method name with the PopupManager
class. For the sake of clarity, we will use both ways in the code examples below.
func dismissLastPopup(popupManagerID: PopupManagerID = .shared)
func dismissPopup(_ id: String, popupManagerID: PopupManagerID = .shared)
func dismissPopup<P: Popup>(_ type: P.Type, popupManagerID: PopupManagerID = .shared)
func dismissAllPopups(popupManagerID: PopupManagerID = .shared)