Class Quit
This command executes the Quit system command
Quits the entire application and closes everything down. If there are any pending changes the user is prompted to cancel, or save those changes first.
Inherited Members
Namespace: LemonEdge.Client.Core.Commands
Assembly: LemonEdge.ClientCore.dll
Syntax
[CommandDescriptorOptions(Command.Quit, null)]
public class Quit : EPCommand, IHasChildren<EPCommandWithDescriptor>, IHasChildren, IEPCommand, ICommand, IDisposable
Constructors
Quit(IRootController, IModelLayoutCommon)
Creates a new Quit command
Declaration
public Quit(IRootController root, IModelLayoutCommon owner)
Parameters
Type | Name | Description |
---|---|---|
IRootController | root | The root controller, for service access. |
IModelLayoutCommon | owner | The owning context for this command |
Methods
InternalCanExecute(object)
True if the host context is the main application form
Declaration
public override bool InternalCanExecute(object parameter)
Parameters
Type | Name | Description |
---|---|---|
object | parameter | The command parameter |
Returns
Type | Description |
---|---|
bool | True if the host context is the main application form |
Overrides
InternalExecuteAsync(object)
Quits the entire application and closes everything down. If there are any pending changes the user is prompted to cancel, or save those changes first.
Declaration
public override Task InternalExecuteAsync(object parameter)
Parameters
Type | Name | Description |
---|---|---|
object | parameter | The command parameter |
Returns
Type | Description |
---|---|
Task | A task indicating the completion of the operation. |
Overrides
QuitApplication(IModelLayoutHost)
Quits the entire application and closes everything down. If there are any pending changes the user is prompted to cancel, or save those changes first.
Declaration
public static Task<bool> QuitApplication(IModelLayoutHost host)
Parameters
Type | Name | Description |
---|---|---|
IModelLayoutHost | host | The main context to quit the application from. Needs to be the main application form |
Returns
Type | Description |
---|---|
Task<bool> | True if the application was closed, false if the user cancelled |