Better focus detection
Stop editor freezing