From 6c8e15a1cfef37cb7be40846376af91be34bbf4b Mon Sep 17 00:00:00 2001 From: paul Date: Fri, 30 Mar 2012 01:24:16 +0000 Subject: [PATCH] win32: reduce amount of hints and warnings git-svn-id: trunk@36434 - --- lcl/interfaces/win32/win32object.inc | 6 +++--- lcl/interfaces/win32/win32wsimglist.pp | 2 ++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/lcl/interfaces/win32/win32object.inc b/lcl/interfaces/win32/win32object.inc index b7274d20e3..be68b693bc 100644 --- a/lcl/interfaces/win32/win32object.inc +++ b/lcl/interfaces/win32/win32object.inc @@ -347,7 +347,7 @@ begin pHandles := nil; retVal := Windows.MsgWaitForMultipleObjects(FWaitHandleCount, pHandles, False, 0, QS_ALLINPUT); - if (WAIT_OBJECT_0 <= retVal) and (retVal < WAIT_OBJECT_0 + FWaitHandleCount) then + if (retVal < WAIT_OBJECT_0 + FWaitHandleCount) then begin index := retVal-WAIT_OBJECT_0; CallWaitHandler; @@ -440,8 +440,8 @@ begin pHandles := nil; retVal := Windows.MsgWaitForMultipleObjects(FWaitHandleCount, pHandles, false, timeout, QS_ALLINPUT); - if (WAIT_OBJECT_0 <= retVal) and (retVal < WAIT_OBJECT_0 + FWaitHandleCount) then - FPendingWaitHandlerIndex := retVal-WAIT_OBJECT_0; + if (retVal < WAIT_OBJECT_0 + FWaitHandleCount) then + FPendingWaitHandlerIndex := retVal - WAIT_OBJECT_0; end; {------------------------------------------------------------------------------ diff --git a/lcl/interfaces/win32/win32wsimglist.pp b/lcl/interfaces/win32/win32wsimglist.pp index 8875cc2ddf..681b9e2197 100644 --- a/lcl/interfaces/win32/win32wsimglist.pp +++ b/lcl/interfaces/win32/win32wsimglist.pp @@ -257,9 +257,11 @@ begin FLAGS := ILC_COLOR or ILC_MASK; end; end; + {$WARNINGS OFF} Result._Init(ImageList_Create(AWidth, AHeight, Flags, ACount, AGrow)); if Result.Allocated and (ACount > 0) then AddData(Result._Handle, ACount, -1, AWidth, AHeight, AData); + {$WARNINGS ON} end; class procedure TWin32WSCustomImageList.Delete(AList: TCustomImageList;