/[lcore]/trunk/wmessages.pas
ViewVC logotype

Annotation of /trunk/wmessages.pas

Parent Directory Parent Directory | Revision Log Revision Log


Revision 136 - (hide annotations)
Fri Mar 28 03:18:52 2014 UTC (6 years, 9 months ago) by beware
File size: 1576 byte(s)
fix spelling mistakes
1 plugwash 41 { Copyright (C) 2005 Bas Steendijk and Peter Green
2     For conditions of distribution and use, see copyright notice in zlib_license.txt
3     which is included in the package
4     ----------------------------------------------------------------------------- }
5    
6 plugwash 40 unit wmessages;
7 beware 136 //this unit contains various functions and types to make it easier to write
8 plugwash 40 //code that works with both real windows messages and lmessages
9    
10     interface
11     uses windows,messages,pgtypes;
12     type
13     thinstance=thandle;
14     thevent=thandle;
15    
16     //according to MS you are supposed to use get/setwindowlongptr to get/set
17     //pointers in extra window memory so your program can be built for win64, this
18     //is also the only interface to window memory that lmessages offers but delphi
19     //doesn't define it so alias it to getwindowlong here for win32.
20     {$ifndef win64} //future proofing ;)
21     function getwindowlongptr(ahwnd:hwnd;nindex:integer) : taddrint;
22     procedure setwindowlongptr(ahwnd:hwnd;nindex:integer;dwNewLong : taddrint);
23     {$endif}
24     function WaitForSingleEvent(hHandle: THandle; dwMilliseconds: DWORD): DWORD; stdcall;
25     implementation
26     {$ifndef win64}
27     function getwindowlongptr(ahwnd:hwnd;nindex:integer) : taddrint;
28     begin
29     result := getwindowlong(ahwnd,nindex);
30     end;
31     procedure setwindowlongptr(ahwnd:hwnd;nindex:integer;dwNewLong : taddrint);
32     begin
33     setwindowlong(ahwnd,nindex,dwnewlong);
34     end;
35     {$endif}
36     function WaitForSingleEvent(hHandle: THandle; dwMilliseconds: DWORD): DWORD; stdcall;
37     begin
38     result := waitforsingleobject(hhandle,dwmilliseconds);
39     end;
40     end.

Properties

Name Value
svn:eol-style CRLF

No admin address has been configured">No admin address has been configured
ViewVC Help
Powered by ViewVC 1.1.26