FB II Compiler
Know why a window could be refreshed twice
You get an activate event when a window is "brought to the front" (usually as a result of clicking in it)--this is characterized by the window's highlighting changing.
You get an update event when a window is resized, or when any previously-obscured part of the window becomes visible again.
Depending on the circumstances, you may get an activate event without an update event; or an update event without an activate event; or you may get them both.