Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Feb 19, 2020. It is now read-only.

Add low memory and OS kill support for extensions#470

Merged
ElektrojungeAtWork merged 2 commits into
bitstadium:developfrom
dtweston:add_memory_support_for_extensions
Oct 20, 2017
Merged

Add low memory and OS kill support for extensions#470
ElektrojungeAtWork merged 2 commits into
bitstadium:developfrom
dtweston:add_memory_support_for_extensions

Conversation

@dtweston

Copy link
Copy Markdown
Contributor

When running in an extension, HockeyApp doesn't have support for detecting low memory warnings, or for detecting when the process is killed by the OS.

This PR is an attempt to add this functionality.

@MatkovIvan MatkovIvan left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution!
Please make sure that the CI build is passing. CI build ran on Xcode 8.3.3 and fail on @available, because it supported only since Xcode 9

@dtweston

Copy link
Copy Markdown
Contributor Author

Thanks @MatkovIvan, I had a feeling that might be the case. I'll fix it up shortly.

@lumaxis

lumaxis commented Oct 16, 2017

Copy link
Copy Markdown
Member

Thanks @dtweston ! Not breaking Xcode 8 unnecessarily would be nice 🙂

The UIApplication... notifications are not fired if Hockey is running
in the context of an extension. In this case, we should be using the
NSExtensionHost... notifications instead.
The UIApplicationDidReceiveMemoryWarningNotification isn't fired when
running in an extension, so we need to resort to a lower-level mechanism.
@dtweston dtweston force-pushed the add_memory_support_for_extensions branch from 3d5b3c7 to c8ad9bc Compare October 16, 2017 23:58
@ElektrojungeAtWork

Copy link
Copy Markdown
Contributor

Looking good! Thx for the contribution!!!

@ElektrojungeAtWork ElektrojungeAtWork merged commit c9cf976 into bitstadium:develop Oct 20, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants