X-Git-Url: http://git.euphorik.ch/?a=blobdiff_plain;f=Parasitemia%2FParasitemiaUI%2FCommandLineArguments.fs;fp=Parasitemia%2FParasitemiaUI%2FCommandLineArguments.fs;h=8025ebf04a8fdbec5c716783262beef2ab3ec9d7;hb=77cb62e17c3e8e7de65b8dab6769be84ca794b92;hp=0000000000000000000000000000000000000000;hpb=f4e3404aaa28beedc9040c0b924c3a8162472b43;p=master-thesis.git diff --git a/Parasitemia/ParasitemiaUI/CommandLineArguments.fs b/Parasitemia/ParasitemiaUI/CommandLineArguments.fs new file mode 100644 index 0000000..8025ebf --- /dev/null +++ b/Parasitemia/ParasitemiaUI/CommandLineArguments.fs @@ -0,0 +1,20 @@ +module ParasitemiaUI.CommandLineArguments + +open System +open System.Windows +open System.Windows.Controls +open System.Diagnostics + +let showWindow (parent : Window) = + let win = Views.CommandLineArgumentsWindow () + win.Owner <- parent + + win.Left <- (if parent.WindowState = WindowState.Maximized then 0. else parent.Left) + parent.ActualWidth / 2. - win.Width / 2. + win.Top <- (if parent.WindowState = WindowState.Maximized then 0. else parent.Top) + parent.ActualHeight / 2. - win.Height / 2. + + win.txtCommandLineArguments.Text <- Utils.argsHelp + + win.butClose.Click.AddHandler (fun obj args -> win.Close ()) + + win.ShowDialog () |> ignore +