Skip to content

Commit

Permalink
IOS Invokes local notifications on the EDT
Browse files Browse the repository at this point in the history
Which contradicts the documentation.
  • Loading branch information
shai-almog authored Jul 11, 2023
1 parent 9e85ec3 commit e0f8968
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions Ports/iOSPort/src/com/codename1/impl/ios/IOSImplementation.java
Original file line number Diff line number Diff line change
Expand Up @@ -8106,15 +8106,8 @@ public static LocalNotificationCallback getLocalNotificationCallback() {

public static void localNotificationReceived(final String notificationId) {
if (localNotificationCallback != null) {
Display.getInstance().callSerially(new Runnable() {

@Override
public void run() {
if (getLocalNotificationCallback() != null) {
getLocalNotificationCallback().localNotificationReceived(notificationId);
}
}
});
// this should be invoked off the EDT...
localNotificationCallback.localNotificationReceived(notificationId);
} else { // could be a race condition against the native code... Retry in 2 seconds
new Thread() {
public void run() {
Expand Down

0 comments on commit e0f8968

Please sign in to comment.