"Interactive mode:\n" +
(sprintf " %s [<document-file>] [--debug]\n" programName) +
" <document-file> : a PIAZ file to automatically open at startup\n" +
- " --debug : output information like intermediate images in the current directory (it takes more CPU and memory)"
\ No newline at end of file
+ " --debug : output information like intermediate images in the current directory (it takes more CPU and memory)"
+
+open System
+open System.Windows
+
+type FunCommand (execute : obj -> unit, canExecute : obj -> bool) =
+ let canExecuteChanged = Event<EventHandler, EventArgs> ()
+
+ interface Input.ICommand with
+ [<CLIEvent>]
+ member this.CanExecuteChanged = canExecuteChanged.Publish
+
+ member this.CanExecute (param : obj) = canExecute param
+
+ member this.Execute (param : obj) = execute param
\ No newline at end of file