diff options
Diffstat (limited to 'source/WindowsFormsApplication1/Apps/TextPad.cs')
| -rw-r--r-- | source/WindowsFormsApplication1/Apps/TextPad.cs | 27 |
1 files changed, 16 insertions, 11 deletions
diff --git a/source/WindowsFormsApplication1/Apps/TextPad.cs b/source/WindowsFormsApplication1/Apps/TextPad.cs index 1b49129..639bcca 100644 --- a/source/WindowsFormsApplication1/Apps/TextPad.cs +++ b/source/WindowsFormsApplication1/Apps/TextPad.cs @@ -7,7 +7,7 @@ using System.IO; using System.Linq; using System.Text; using System.Threading.Tasks; -using System.Windows.Forms; +using ShiftUI; namespace ShiftOS { @@ -16,7 +16,7 @@ namespace ShiftOS private bool codepointscooldown = false; private int codepointsearned = 0; private bool needtosave = false; - + public TextPad() { InitializeComponent(); @@ -37,7 +37,8 @@ namespace ShiftOS pnloptions.Show(); txtuserinput.Size = new Size(txtuserinput.Size.Width, txtuserinput.Size.Height - pnloptions.Height); } - else { + else + { pnlbreak.BackgroundImage = Properties.Resources.uparrow; pnloptions.Hide(); txtuserinput.Size = new Size(txtuserinput.Size.Width, txtuserinput.Size.Height + pnloptions.Height); @@ -53,7 +54,7 @@ namespace ShiftOS API.InfoboxSession.FormClosing += (object s, FormClosingEventArgs a) => { string result = API.GetInfoboxResult(); - switch(result) + switch (result) { case "Yes": codepointsearned = 0; @@ -65,7 +66,8 @@ namespace ShiftOS } }; } - else { + else + { makenewdoc(); } } @@ -156,23 +158,25 @@ namespace ShiftOS if (res2 != "fail") { string fContents = File.ReadAllText(res2); - + txtuserinput.Text = fContents; } break; } }; } - else { + else + { string res = API.GetFSResult(); if (res != "fail") { - try { + try + { string fContents = File.ReadAllText(res); txtuserinput.Text = fContents; } - catch(Exception ex) + catch (Exception ex) { txtuserinput.Text = ex.Message; } @@ -206,7 +210,8 @@ namespace ShiftOS if (codepointscooldown == true) { } - else { + else + { codepointsearned = codepointsearned + 1; codepointscooldown = true; tmrcodepointcooldown.Start(); @@ -236,4 +241,4 @@ namespace ShiftOS tmrshowearnedcodepoints.Stop(); } } -} +}
\ No newline at end of file |
