Describes settings we want to use for current device. More...
#include <juce_PushNotifications.h>
Classes | |
struct | Category |
Describes a category of a notification. More... | |
Public Types | |
using | Action = Notification::Action |
Public Attributes | |
bool | allowAlert = false |
whether the app should present an alert upon notification More... | |
bool | allowBadge = false |
whether the app may badge its icon upon notification More... | |
bool | allowSound = false |
whether the app should play a sound upon notification More... | |
Array< Category > | categories |
list of categories the app wants to support More... | |
Describes settings we want to use for current device.
Note that at the moment this is only used on iOS and partially on OSX.
On OSX only allow* flags are used and they control remote notifications only. To control sound, alert and badge settings for local notifications on OSX, use Notifications settings in System Preferences.
To setup push notifications for current device, provide permissions required, as well as register categories of notifications you want to support. Each category needs to have a unique identifier and it can optionally have multiple actions. Each action also needs to have a unique identifier. The example setup may look as follows:
bool juce::PushNotifications::Settings::allowAlert = false |
whether the app should present an alert upon notification
bool juce::PushNotifications::Settings::allowBadge = false |
whether the app may badge its icon upon notification
bool juce::PushNotifications::Settings::allowSound = false |
whether the app should play a sound upon notification
list of categories the app wants to support