From: H.G. Muller Date: Sun, 21 Feb 2010 22:09:24 +0000 (+0100) Subject: Put newly opened Chat Box on top X-Git-Tag: master-20100221~2 X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=74c6f0bfb6476b2ba21f90d9e5d34130b26825ef;p=xboard.git Put newly opened Chat Box on top Dialogs always pop up in front, so set the onTop variable that prevents highighting the button to navigate to it from other Chat Boxes to reflect that a newly opened Chat Box is in view. --- diff --git a/winboard/wchat.c b/winboard/wchat.c index ac75819..4a1b4d3 100644 --- a/winboard/wchat.c +++ b/winboard/wchat.c @@ -207,6 +207,7 @@ LRESULT CALLBACK ChatProc( HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam SendMessage( GetDlgItem(hDlg, IDC_ChatPartner), // [HGM] clickbox: initialize with requested handle WM_SETTEXT, 0, (LPARAM) chatPartner[partner] ); filterHasFocus[partner] = TRUE; + onTop = partner; // a newly opened box becomes top one if(chatPartner[partner][0]) { filterHasFocus[partner] = FALSE; SetFocus( GetDlgItem(hDlg, OPT_ChatInput) );