universal-tools / UTNotificationsFeedback

7 stars 0 forks source link

If i want to have Button in game for disable all PushNoti and can Enable on same Button? #45

Closed AtitJeu closed 7 years ago

AtitJeu commented 7 years ago

If i want to have Button in game for disable all PushNoti and can Enable too?

1. i see it have fuction void UTNotifications.SampleUI.HideAll() but it can use again for Unhide ? or i should use SetNotificationsEnabled() ? true false for

2. for sure player can disable PushNoti if him not want PushNoti show on phone and player can enable by myself in same button

thx a lot for read and answer

yuriy-universal-ivanov commented 7 years ago

Hi @AtitJeu ,

SetNotificationsEnabled() is designed exactly for that purpose. You are right: you may set it to false to disable the notifications and then back to true to enable them again. Unfortunately, if there were any notifications hidden when calling SetNotificationsEnabled(false) they can't be shown again, but new notifications will appear well. Moreover, you may work with the whole UTNotifications API as well as notifications are always enabled - it's completely safe: user will not see or hear any notifications while there are disabled, but will start get notifications after you enable them again.

Best regards, Yuriy, Universal Tools team.

AtitJeu commented 7 years ago

thx a lot