Advising functions is limited. For example, if you select a window with your mouse, no function is called interactively, it just changes the window.

Maybe I can use the same hook modeline uses to know how to color itself active or inactive?

-Steven