From 8dfc12915479cb72117d5a07f6dbe209c025a541 Mon Sep 17 00:00:00 2001 From: Graeme Geldenhuys Date: Sun, 1 Mar 2015 18:41:22 +0000 Subject: bug: fixes deleting extra character after Cut-To-Clipboard it TextEdit widget Using the keyboard combination to cut to the clipboard deleted an extra character that was not selected. --- examples/apps/ide/src/fpg_textedit.pas | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/examples/apps/ide/src/fpg_textedit.pas b/examples/apps/ide/src/fpg_textedit.pas index 3e88f3d1..6acea537 100644 --- a/examples/apps/ide/src/fpg_textedit.pas +++ b/examples/apps/ide/src/fpg_textedit.pas @@ -1583,17 +1583,20 @@ begin ckCopy: begin CopyToClipboard; + consumed := True; end; ckPaste: begin // if not ReadOnly then PasteFromClipboard; + consumed := True; end; ckCut: begin CutToClipboard; + consumed := True; end; end; @@ -1611,6 +1614,8 @@ begin SLine := FLines[CaretPos.Y]; + if not consumed then + begin case keycode of keyBackspace: begin @@ -1728,7 +1733,8 @@ begin end; consumed := True; end; - end; + end; // case keycode + end; // if not consumed if CaretScroll then begin -- cgit v1.2.3-70-g09d2