merge openOnFocus branch