fixed focus bugs