From 279f8d333b7b388bcdf977e1b22bde2a6e23d083 Mon Sep 17 00:00:00 2001 From: Thomas Bluemel Date: Sun, 28 Dec 2003 16:31:44 +0000 Subject: [PATCH] use DSTINVERT for DrawFocusRect() and the moving/sizing rectangle svn path=/trunk/; revision=7293 --- reactos/lib/user32/windows/defwnd.c | 4 ++-- reactos/lib/user32/windows/draw.c | 10 ++++------ 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/reactos/lib/user32/windows/defwnd.c b/reactos/lib/user32/windows/defwnd.c index cedbb6a6c5b..85d0c45c32e 100644 --- a/reactos/lib/user32/windows/defwnd.c +++ b/reactos/lib/user32/windows/defwnd.c @@ -1,4 +1,4 @@ -/* $Id: defwnd.c,v 1.119 2003/12/28 00:41:31 weiden Exp $ +/* $Id: defwnd.c,v 1.120 2003/12/28 16:31:44 weiden Exp $ * * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS user32.dll @@ -451,7 +451,7 @@ UserDrawMovingFrame(HDC hdc, RECT *rect, BOOL thickframe) if (thickframe) { UserDrawWindowFrame(hdc, rect, GetSystemMetrics(SM_CXFRAME), - GetSystemMetrics(SM_CYFRAME), PATINVERT ); + GetSystemMetrics(SM_CYFRAME), DSTINVERT); } else DrawFocusRect( hdc, rect ); } diff --git a/reactos/lib/user32/windows/draw.c b/reactos/lib/user32/windows/draw.c index 623adf1e4e4..8037dfd0b8d 100644 --- a/reactos/lib/user32/windows/draw.c +++ b/reactos/lib/user32/windows/draw.c @@ -1864,16 +1864,14 @@ DrawFocusRect(HDC hdc, CONST RECT *rect) return TRUE; #else - HBRUSH hbrush = SelectObject(hdc, GetStockObject(GRAY_BRUSH)); PatBlt(hdc, rect->left, rect->top, - rect->right - rect->left - 1, 1, PATINVERT); + rect->right - rect->left - 1, 1, DSTINVERT); PatBlt(hdc, rect->left, rect->top + 1, 1, - rect->bottom - rect->top - 1, PATINVERT); + rect->bottom - rect->top - 1, DSTINVERT); PatBlt(hdc, rect->left + 1, rect->bottom - 1, - rect->right - rect->left - 1, -1, PATINVERT); + rect->right - rect->left - 1, -1, DSTINVERT); PatBlt(hdc, rect->right - 1, rect->top, -1, - rect->bottom - rect->top - 1, PATINVERT); - SelectObject(hdc, hbrush); + rect->bottom - rect->top - 1, DSTINVERT); return TRUE; #endif