X-Git-Url: http://winboard.nl/cgi-bin?a=blobdiff_plain;f=winboard%2Fwchat.c;h=30b6aa5ba6c69b84305518b2c6dd66e2796744d9;hb=d91dfdc72d9abeb6733b72c9bef81ccee55b9735;hp=3b90b2c3d8000dd838820a061baa466a800cf7f0;hpb=b42a7598bf84b00ff82160234839d7b1c9f3f329;p=xboard.git diff --git a/winboard/wchat.c b/winboard/wchat.c index 3b90b2c..30b6aa5 100644 --- a/winboard/wchat.c +++ b/winboard/wchat.c @@ -61,7 +61,7 @@ char *NextInHistory(); extern HWND ChatDialog; extern HINSTANCE hInst; -extern HWND hwndMain; +extern HWND hwndConsole; extern WindowPlacement wpChat[MAX_CHAT]; extern WindowPlacement wpConsole; @@ -180,7 +180,7 @@ LRESULT CALLBACK ChatProc( HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam { static SnapData sd; char buf[MSG_SIZ], mess[MSG_SIZ]; - int partner = -1, i; + int partner = -1, i, x, y; static BOOL filterHasFocus[MAX_CHAT]; WORD wMask; HWND hMemo; @@ -195,18 +195,21 @@ LRESULT CALLBACK ChatProc( HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam sprintf(buf, "Chat Window %s", first.tidy); SetWindowText(hDlg, buf); } - for(i=0; ipartner), chatPartner[i]); - } else EnableWindow( GetDlgItem(hDlg, IDC_Focus1+i-(i>partner)), 1 ); + } else EnableWindow( GetDlgItem(hDlg, IDC_Focus1+i-(i>partner)), 0 ); for(i=0; i %s\r\n", mess); // echo only tells to handle, not channel @@ -369,7 +371,7 @@ void ChatPopUp(char *icsHandle) lpProc = MakeProcInstance( (FARPROC) ChatProc, hInst ); /* Note to self: dialog must have the WS_VISIBLE style set, otherwise it's not shown! */ - CreateDialog( hInst, MAKEINTRESOURCE(DLG_Chat), hwndMain, (DLGPROC)lpProc ); + CreateDialog( hInst, MAKEINTRESOURCE(DLG_Chat), hwndConsole, (DLGPROC)lpProc ); FreeProcInstance(lpProc);