private void fwMainWindow_Activated(object sender, EventArgs e) { m_activeMainWindow = (Form)sender; }