Focus problem for Win32 platform



Hi,

Is it known Windows issue that focus is missing the parent window when dialog is closing?

My program description:

1. Create toplevel window (main_win).
2. Create toplevel window (dialog)
   - dialog->set_transient_for( main_win );
   - main_win->set_sensitive( false );
we need those calls to emulate modal dialog for current main_win only, but whole application (other windows) is still responding on user events.
3. on dialog->hide()
   - main_win->set_sensitive( true );
- main_win->grab_focus(); // I added this string just before I wrote the mail, and it won't handle the problem with focus.

Problem:

When closing a dialog on Win32 platforms focus is moving not on parent (previous = main_win) window, but random toplevel window from this application or any other, someone told me it looks like "extra" Alt+TAB (switch task) is generating on this moment.

Any comments?

Thanks in advance,
-andrew




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]