Class AndroidUiContext
Represents the app's UI on Android: an activity, in which the device shows its prompts and the app its ads.
public class AndroidUiContext : IUiContext
- Inheritance
-
AndroidUiContext
- Implements
- Inherited Members
Constructors
AndroidUiContext(IActivityEvent)
Represents the app's UI on Android: an activity, in which the device shows its prompts and the app its ads.
public AndroidUiContext(IActivityEvent activityEvent)
Parameters
activityEventIActivityEventThe activity, with its events.
Properties
Activity
Gets the activity.
public Activity Activity { get; }
Property Value
ActivityEvent
Gets the activity, with its events.
public IActivityEvent ActivityEvent { get; }
Property Value
Methods
IsActive()
Determines whether the UI is shown to the user, as far as the platform tells: Android checks its view, and iOS always answers true.
public Task<bool> IsActive()
Returns
Remarks
It asks on the UI thread whether the activity is not destroyed and its window's view is shown; false where that cannot be read.
IsDestroyed()
Determines whether the UI is gone, as far as the platform tells: a desktop reports a hidden window as gone, and iOS never reports one.
public Task<bool> IsDestroyed()
Returns
Remarks
It is the activity's own answer; false where that cannot be read.