@@ -0,0 +1,603 @@
+package com.haxademic.core.ui;%0A%0Aimport com.haxademic.core.app.P;%0Aimport com.haxademic.core.debug.DebugUtil;%0A%0Aimport processing.event.KeyEvent;%0A%0Apublic class CursorToggle %7B%0A%0A%09protected boolean isHidden;%0A%09%0A%09public CursorToggle(boolean defaultHidden) %7B%0A%09%09if(P.p == null) DebugUtil.printErr(%22===========%5Cn Please wait until setup() to init CursorToggle %5Cn===========%22);%0A%09%09isHidden = defaultHidden;%0A%09%09P.p.registerMethod(%22keyEvent%22, this);%0A%09%7D%0A%09%0A%09public void keyEvent(KeyEvent e) %7B%0A%09%09if(e.getKey() == 'm') isHidden = !isHidden;%0A%09%09if(isHidden == true) %7B%0A%09%09%09P.p.noCursor();%0A%09%09%7D else %7B%0A%09%09%09P.p.cursor();%0A%09%09%7D%0A%09%7D%0A%0A%7D%0A

Add cursor toggle key listener object