Name | Summary |
---|---|
currentActivity | var currentActivity: WeakReference<AppSystemActivity>? The current Spatial activity. |
Name | Summary |
---|---|
executeOnAppSystemActivity | fun executeOnAppSystemActivity(runnable: (activity: AppSystemActivity) -> Unit) This function is used to execute a block of code on the current AppSystemActivity’s main thread. If the current activity has not been set or has been garbage collected, it will throw an exception. |
executeOnVrActivity | inline fun <T : AppSystemActivity> executeOnVrActivity(crossinline runnable: (activity: T) -> Unit) This generic function is used to execute a block of code on the current activity’s main thread. If the current activity has not been set or has been garbage collected, it will do nothing. |
getAppSystemActivity | fun getAppSystemActivity(): AppSystemActivity This function is used to get the current activity. This allows you to specify your activity so that you can access data on it. If the current activity has not been set or has been garbage collected, it will return null. Otherwise, it will return the current activity and cast it to type AppSystemActivity. |
getVrActivity | inline fun <T : AppSystemActivity> getVrActivity(): T This generic function is used to get the current activity. This allows you to specify your activity so that you can access data on it. If the current activity has not been set or has been garbage collected, it will return null. |