From c16346f790e1ca9316e2a7b86ecb198b76742af3 Mon Sep 17 00:00:00 2001 From: Thorsten Sommer Date: Wed, 15 Feb 2023 20:41:44 +0100 Subject: [PATCH] Improved UX, when the user copied a key --- I18N Commander/UI WinForms/Components/TextElements.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/I18N Commander/UI WinForms/Components/TextElements.cs b/I18N Commander/UI WinForms/Components/TextElements.cs index 902f570..2a4b1ef 100644 --- a/I18N Commander/UI WinForms/Components/TextElements.cs +++ b/I18N Commander/UI WinForms/Components/TextElements.cs @@ -249,5 +249,13 @@ public partial class TextElements : UserControl return; Clipboard.SetText(await TextElementProcessor.GetKey(this.currentTextElement.Id)); + + // + // Switch the button's icon to the "ok" icon for a few + // seconds, to indicate, that the key was copied: + // + this.buttonCopyKey.Image = Icons.icons8_ok_512; + await Task.Delay(TimeSpan.FromSeconds(1)); + this.buttonCopyKey.Image = Icons.icons8_key2_512; } } \ No newline at end of file