From 2fde40f46a2c87ffeeacfc384e3e82d11a091b25 Mon Sep 17 00:00:00 2001 From: Federico Fissore Date: Wed, 27 Feb 2013 11:47:03 +0100 Subject: [PATCH] changed test to Character.isISOControl --- app/src/processing/app/EditorListener.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/processing/app/EditorListener.java b/app/src/processing/app/EditorListener.java index af0a106b5..334345e29 100644 --- a/app/src/processing/app/EditorListener.java +++ b/app/src/processing/app/EditorListener.java @@ -130,7 +130,7 @@ public class EditorListener { } // The char is not control code when CTRL key pressed? It should be a shortcut. - if (c >= ' ') { + if (!Character.isISOControl(c)) { event.consume(); return true; } @@ -487,7 +487,7 @@ public class EditorListener { if ((event.getModifiers() & KeyEvent.CTRL_MASK) != 0) { // The char is not control code when CTRL key pressed? It should be a shortcut. - if (c >= ' ') { + if (!Character.isISOControl(c)) { event.consume(); return true; }