From 750b776349cb96f50c4f5b0eba3662bc7da27e69 Mon Sep 17 00:00:00 2001 From: Michael Date: Thu, 23 Feb 2017 12:47:42 -0500 Subject: [PATCH] Fix the terminal. #71 --- ShiftOS.WinForms/Commands.cs | 11 +++++++++++ ShiftOS.WinForms/Controls/TerminalBox.cs | 6 ++++++ 2 files changed, 17 insertions(+) diff --git a/ShiftOS.WinForms/Commands.cs b/ShiftOS.WinForms/Commands.cs index 2d297f5..91caff4 100644 --- a/ShiftOS.WinForms/Commands.cs +++ b/ShiftOS.WinForms/Commands.cs @@ -39,6 +39,17 @@ using Newtonsoft.Json; /// namespace ShiftOS.WinForms { + [Namespace("sos")] + public static class MichaelDrunkStuff + { + [Command("drunkmichael")] + public static bool Drunky() + { + + return true; + } + } + [Namespace("trm")] public static class TerminalExtensions { diff --git a/ShiftOS.WinForms/Controls/TerminalBox.cs b/ShiftOS.WinForms/Controls/TerminalBox.cs index 6c05027..ffc3f86 100644 --- a/ShiftOS.WinForms/Controls/TerminalBox.cs +++ b/ShiftOS.WinForms/Controls/TerminalBox.cs @@ -44,6 +44,12 @@ namespace ShiftOS.WinForms.Controls catch { } } + protected override void OnClick(EventArgs e) + { + base.OnClick(e); + this.Select(this.TextLength, 0); + } + public void Write(string text) { this.Text += Localization.Parse(text);