Chronos Plugins  5.2.0
This documentation covers the plugin interfaces definitions and an example implementation.
AxelSemrau.Chronos.Plugin.IGuiHelper Interface Reference

Helper functions for GUI related tasks. More...

Public Member Functions

void OwnMyWindow (IntPtr handle)
 Make the window with the given handle owned by the Chronos main window. This prevents it from dropping behind by accident. More...
 

Properties

System.Threading.Tasks.TaskScheduler GuiThreadScheduler [get]
 Use this scheduler to do actions on the thread that owns the main GUI. More...
 
System.Threading.Tasks.TaskFactory GuiTaskFactory [get]
 For your convenience, a default task factory for tasks running on the GUI thread. More...
 
IWin32Window MainWindow [get]
 If you need to set the owner window yourself or want to show message boxes. More...
 
bool MainWindowEnabled [get, set]
 Allows you to temporarily disable all user interaction with the Chronos main window. More...
 
Dispatcher GuiDispatcher [get]
 The dispatcher that is used for WPF operations on the main GUI thread. More...
 

Detailed Description

Helper functions for GUI related tasks.

Helpers

Definition at line 19 of file Helpers.cs.

Member Function Documentation

◆ OwnMyWindow()

void AxelSemrau.Chronos.Plugin.IGuiHelper.OwnMyWindow ( IntPtr  handle)

Make the window with the given handle owned by the Chronos main window. This prevents it from dropping behind by accident.

Parameters
handle

Does not seem to work as intended if the handle belongs to a WindowInteropHelper

Referenced by MockPlugin.SampleList.MockSampleListWorker.DoYourJob().

Property Documentation

◆ GuiDispatcher

Dispatcher AxelSemrau.Chronos.Plugin.IGuiHelper.GuiDispatcher
get

The dispatcher that is used for WPF operations on the main GUI thread.

Definition at line 53 of file Helpers.cs.

53 { get; }

◆ GuiTaskFactory

System.Threading.Tasks.TaskFactory AxelSemrau.Chronos.Plugin.IGuiHelper.GuiTaskFactory
get

For your convenience, a default task factory for tasks running on the GUI thread.

Definition at line 28 of file Helpers.cs.

28 { get; }

Referenced by MockPlugin.Device.MockDevice.OnIsConnectedChanged().

◆ GuiThreadScheduler

System.Threading.Tasks.TaskScheduler AxelSemrau.Chronos.Plugin.IGuiHelper.GuiThreadScheduler
get

Use this scheduler to do actions on the thread that owns the main GUI.

Definition at line 24 of file Helpers.cs.

24 { get; }

Referenced by MockPlugin.SampleList.MockSampleListWorker.HandleAbortButton(), MockPlugin.SampleList.MockSampleListWorker.HandleStopButton(), and MockPlugin.SampleList.MockSampleListWorker.MockSampleListWorker().

◆ MainWindow

◆ MainWindowEnabled

bool AxelSemrau.Chronos.Plugin.IGuiHelper.MainWindowEnabled
getset

Allows you to temporarily disable all user interaction with the Chronos main window.

Use with care. You can lock the user out if you disable it and forget to enable it (because of unhandled exceptions or similar). This is primarily meant to be used if you want to show an external processes' window in style of a modal dialog.

Definition at line 48 of file Helpers.cs.

48 { get; set; }

The documentation for this interface was generated from the following file: