Provides the Windows Runtime core event message dispatcher. Instances of this type are responsible for processing the window messages and dispatching the events to the client.
Syntax
Attributes
- MarshalingBehaviorAttribute(Agile)
- MuseAttribute()
- VersionAttribute(NTDDI_WIN8)
- WebHostHiddenAttribute()
Members
The CoreDispatcher class has these types of members:
Events
The CoreDispatcher class has these events.
| Event | Description |
|---|---|
| AcceleratorKeyActivated | Fired when an accelerator key is activated (pressed or held down). |
Methods
The CoreDispatcher class has these methods. It also inherits methods from the Object class.
| Method | Description |
|---|---|
| ProcessEvents | Starts the dispatcher processing the input event queue for this instance of CoreWindow. |
| RunAsync | Schedules the provided callback on the UI thread from a worker thread, and returns the results asynchronously. |
| RunIdleAsync | Schedules a callback on the UI thread from a worker thread at idle priority, and returns the results asynchronously. |
Properties
The CoreDispatcher class has these properties.
| Property | Access type | Description |
|---|---|---|
| Read-only | Gets a value that specifies whether the event dispatcher provided by this instance of CoreWindow has access to the current thread or not. |
Remarks
Instances of this type can be obtained from the CoreWindow.Dispatcher property. The current CoreWindow instance can be obtained by calling CoreWindow.GetForCurrentThread.
void MyCoreWindowEvents::Run() // this is an implementation of IFrameworkView::Run() used to show context. It is called by CoreApplication::Run(). { CoreWindow::GetForCurrentThread()->Activate(); /... CoreWindow::GetForCurrentThread()->Dispatcher->ProcessEvents(CoreProcessEventsOption::ProcessUntilQuit); }
Requirements
|
Minimum supported client | Windows 8 [Windows Store apps only] |
|---|---|
|
Minimum supported server | Windows Server 2012 [Windows Store apps only] |
|
Minimum supported phone | Windows Phone 8 |
|
Namespace |
|
|
Metadata |
|
Build date: 2/25/2013