Fixes several keyboard issues.