Author: janderwald Date: Sun Aug 27 13:42:16 2006 New Revision: 23736
URL: http://svn.reactos.org/svn/reactos?rev=23736&view=rev Log: * auto-select correct radio button * only repaint required on up/down notifications events
Modified: trunk/reactos/dll/win32/console/colors.c
Modified: trunk/reactos/dll/win32/console/colors.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/console/colors.c?... ============================================================================== --- trunk/reactos/dll/win32/console/colors.c (original) +++ trunk/reactos/dll/win32/console/colors.c Sun Aug 27 13:42:16 2006 @@ -83,7 +83,10 @@ SendMessage(GetDlgItem(hwndDlg, IDC_UPDOWN_COLOR_RED), UDM_SETRANGE, 0, (LPARAM)MAKELONG(255, 0)); SendMessage(GetDlgItem(hwndDlg, IDC_UPDOWN_COLOR_GREEN), UDM_SETRANGE, 0, (LPARAM)MAKELONG(255, 0)); SendMessage(GetDlgItem(hwndDlg, IDC_UPDOWN_COLOR_BLUE), UDM_SETRANGE, 0, (LPARAM)MAKELONG(255, 0)); - InvalidateRect(hwndDlg, NULL, TRUE); + SetDlgItemInt(hwndDlg, IDC_EDIT_COLOR_RED, GetRValue(pConInfo->ScreenBackground), FALSE); + SetDlgItemInt(hwndDlg, IDC_EDIT_COLOR_GREEN, GetGValue(pConInfo->ScreenBackground), FALSE); + SetDlgItemInt(hwndDlg, IDC_EDIT_COLOR_BLUE, GetBValue(pConInfo->ScreenBackground), FALSE); + CheckRadioButton(hwndDlg, IDC_RADIO_SCREEN_TEXT, IDC_RADIO_POPUP_BACKGROUND, IDC_RADIO_SCREEN_BACKGROUND); return TRUE; } case WM_DRAWITEM: @@ -169,7 +172,9 @@ blue = LOBYTE(blue); } s_Colors[pConInfo->ActiveStaticControl] = RGB(red, green, blue); - InvalidateRect(hwndDlg, NULL, TRUE); //FIXME + InvalidateRect(GetDlgItem(hwndDlg, IDC_STATIC_COLOR1 + pConInfo->ActiveStaticControl), NULL, TRUE); + InvalidateRect(GetDlgItem(hwndDlg, IDC_STATIC_SCREEN_COLOR), NULL, TRUE); + InvalidateRect(GetDlgItem(hwndDlg, IDC_STATIC_POPUP_COLOR), NULL, TRUE); break; } case WM_COMMAND: