Skip to content

Conversation

@devgeeks
Copy link
Owner

@devgeeks devgeeks commented Mar 1, 2016

Fixes #12

Seems the plugin was not swizzling AppDelegate, but simply overriding
it.

This means it all worked fine and dandy as long as no other plugins were
overriding or swizzling AppDelegates applicationWillResignActive or
applicationDidBecomeActive.

Sadly, phonegap-plugin-push and many more do exactly this... so the
combination was causing one or both plugins to fail.

This change fixes the swizzling in this plugin, making it play nicely
with phonegap-plugin-push, and hopefully others.

Coincidentally, phonegap-plugin-push was also incorrectly overriding
applicationDidBecomeActive, so I have sent a PR to correct
phonegap-plugin-push as well.

Seems the plugin was not swizzling AppDelegate, but simply overriding
it.

This means it all worked fine and dandy as long as no other plugins were
overriding or swizzling AppDelegates applicationWillResignActive or
applicationDidBecomeActive.

Sadly, phonegap-plugin-push and many more do exactly this... so the
combination was causing one or both plugins to fail.

This change fixes the swizzling in this plugin, making it play nicely
with phonegap-plugin-push, and hopefully others.

Coincidentally, phonegap-plugin-push was also incorrectly overriding
applicationDidBecomeActive, so I have sent a PR to correct
phonegap-plugin-push as well.
@devgeeks devgeeks self-assigned this Mar 1, 2016
@devgeeks devgeeks added the bug label Mar 1, 2016
@EddyVerbruggen
Copy link
Contributor

We could do this without swizzling at all. I can send a PR of that approach if you like.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Switching back to app does not hide splash screen.

3 participants