logout impl, keyboard focus bug, crash fix (added 2 files)