Bug 927862 - Implement AttentionWindow

State machine pattern doesn't disallow us to check the state where it comes from.
See if we have A, B, C states, A->C and B-C might have different things to do.

The spirit of state machine is having only one state at one time, but the handler added to the state is fine to use the previous state info.

See this implementation of https://github.com/jakesgordon/javascript-state-machine

If we really don't want a previous state check, we will create states like 'close-from-init' and 'close-from-closing' which has poor sense. What do you think?