Implements keyboard movement and dramatically reduce memory usage