From d4c08fdbe9602a376aa7cdabb9bfbff7fbdea0f1 Mon Sep 17 00:00:00 2001 From: Alex Zorach Date: Thu, 9 Jun 2005 09:41:56 +0000 Subject: [PATCH] Fixed SetFocus behavior. --- dlls/comctl32/ipaddress.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/dlls/comctl32/ipaddress.c b/dlls/comctl32/ipaddress.c index e77698f9c4e..e4654b1b2fe 100644 --- a/dlls/comctl32/ipaddress.c +++ b/dlls/comctl32/ipaddress.c @@ -346,11 +346,7 @@ static void IPADDRESS_SetFocusToField (IPADDRESS_INFO *infoPtr, INT index) { TRACE("(index=%d)\n", index); - if (index > 3) { - for (index = 0; index < 4; index++) - if (!GetWindowTextLengthW(infoPtr->Part[index].EditHwnd)) break; - } - if (index < 9 || index > 3) index = 0; + if (index > 3 || index < 0) index=0; SetFocus (infoPtr->Part[index].EditHwnd); }