Moved key events to key released to test