Skip to content

How to get Android activity/application context? #122

Answered by marcprux
hepspl asked this question in Q&A
Discussion options

You must be logged in to vote

For Skip-generated projects, we stash the global application context in the Foundation.ProcessInfo singleton, which you can access like this:

import Foundation

#if SKIP 
let appContext = ProcessInfo.processInfo.androidContext
#endif

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by hepspl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants