Manages an app activation operation.
public : sealed class ActivatedOperation : IActivatedOperation
public sealed class ActivatedOperation : IActivatedOperation
Public NotInheritable Class ActivatedOperation Implements IActivatedOperation
Windows 10 (introduced v10.0.10240.0)
Windows.Foundation.UniversalApiContract (introduced v1)
: This class is not agile, which means that you need to consider its threading model and marshaling behavior. For more info, see Threading and Marshaling (C++/CX)
GetDeferral() GetDeferral() GetDeferral() GetDeferral()
Requests that the completion of app activation be delayed.
public : ActivatedDeferral GetDeferral()
public ActivatedDeferral GetDeferral()
Public Function GetDeferral() As ActivatedDeferral
The activation deferral object.
When an app starts, the system displays its splash screen until the app indicates that it is ready to display its UI by returning from its activation handler. The app has several seconds to set up its state and initial UI. The UI for the app is displayed to the user when the app returns from its activation handler. However, some apps need to start asynchronous operations to retrieve state information and set up their UI (like using fragment loading to display app pages). Apps that must complete activation asynchronously can get a deferral object from the activation event arguments. This object enables the app to complete activation outside its handler. When the app acquires the deferral object, its activation is not completed when the activation handler returns.
An app can complete activation after its required asynchronous operations complete and it is ready to display its UI. App activation is delayed until the app calls the ActivatedDeferral.complete method.
Requesting a deferral enables an app to display its static splash screen for up to 15 seconds. If the app hasn't completed activation after 15 seconds, the system considers the app hung and will terminate it if the user navigates away from the splash screen.
Note that in normal circumstances and app should take no more than a few seconds to finish activation. If your app requires more than 3 or 4 seconds to restore state and prepare its UI, then you should finish activation and display an extended splash screen screen until your app is ready.
- See Also