From 8af525be4eabba5fb737fa0dabcb985713519d20 Mon Sep 17 00:00:00 2001 From: Evan Langlais Date: Fri, 24 Mar 2017 12:57:11 -0400 Subject: [PATCH] Testing osk --- Enigma/StationsGUI/DebugStationView.Designer.cs | 17 +++++++++++++++-- Enigma/StationsGUI/DebugStationView.cs | 6 ++++++ EnigmaX/Classes/SystemFunctions.cs | 9 +++++++++ 3 files changed, 30 insertions(+), 2 deletions(-) diff --git a/Enigma/StationsGUI/DebugStationView.Designer.cs b/Enigma/StationsGUI/DebugStationView.Designer.cs index 8dff3b3..518ca37 100644 --- a/Enigma/StationsGUI/DebugStationView.Designer.cs +++ b/Enigma/StationsGUI/DebugStationView.Designer.cs @@ -30,6 +30,7 @@ private void InitializeComponent() { this.metroButton1 = new MetroFramework.Controls.MetroButton(); this.metroButton2 = new MetroFramework.Controls.MetroButton(); + this.metroButton3 = new MetroFramework.Controls.MetroButton(); this.SuspendLayout(); // // metroButton1 @@ -52,14 +53,25 @@ private void InitializeComponent() this.metroButton2.UseSelectable = true; this.metroButton2.Click += new System.EventHandler(this.metroButton2_Click); // - // DebugForm + // metroButton3 + // + this.metroButton3.Location = new System.Drawing.Point(176, 414); + this.metroButton3.Name = "metroButton3"; + this.metroButton3.Size = new System.Drawing.Size(75, 23); + this.metroButton3.TabIndex = 2; + this.metroButton3.Text = "keyboard"; + this.metroButton3.UseSelectable = true; + this.metroButton3.Click += new System.EventHandler(this.metroButton3_Click); + // + // DebugStationView // this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.ClientSize = new System.Drawing.Size(1094, 652); + this.Controls.Add(this.metroButton3); this.Controls.Add(this.metroButton2); this.Controls.Add(this.metroButton1); - this.Name = "DebugForm"; + this.Name = "DebugStationView"; this.Text = "Debug Form"; this.Load += new System.EventHandler(this.Form1_Load); this.ResumeLayout(false); @@ -70,6 +82,7 @@ private void InitializeComponent() private MetroFramework.Controls.MetroButton metroButton1; private MetroFramework.Controls.MetroButton metroButton2; + private MetroFramework.Controls.MetroButton metroButton3; } } diff --git a/Enigma/StationsGUI/DebugStationView.cs b/Enigma/StationsGUI/DebugStationView.cs index be3102b..b562afa 100644 --- a/Enigma/StationsGUI/DebugStationView.cs +++ b/Enigma/StationsGUI/DebugStationView.cs @@ -48,5 +48,11 @@ private void metroButton2_Click(object sender, EventArgs e) _station.interCom.send("%HOST%|-test", "This is a test dummy ping"); } } + + private void metroButton3_Click(object sender, EventArgs e) + { + SystemFunctions.showOSK(); + + } } } diff --git a/EnigmaX/Classes/SystemFunctions.cs b/EnigmaX/Classes/SystemFunctions.cs index 66160c9..d623d00 100644 --- a/EnigmaX/Classes/SystemFunctions.cs +++ b/EnigmaX/Classes/SystemFunctions.cs @@ -1,6 +1,8 @@ using EnigmaX.GUI; using System; using System.Collections.Generic; +using System.Diagnostics; +using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; @@ -23,5 +25,12 @@ public static Employee showPinScreenUntilAuthenticated(EmployeeRole role) } } + public static void showOSK() { + string progFiles = @"C:\Program Files\Common Files\Microsoft Shared\ink"; + string keyboardPath = Path.Combine(progFiles, "TabTip.exe"); + Process keyboardProc = Process.Start(keyboardPath); + + } + } }