added onStateHasFocus / onStateLostFocus to state manager