make unitwindowobject work on linux again
authorbeware <beware@bircd.org>
Tue, 11 Mar 2014 22:48:46 +0000 (22:48 +0000)
committerbeware <beware@bircd.org>
Tue, 11 Mar 2014 22:48:46 +0000 (22:48 +0000)
git-svn-id: file:///svnroot/lcore/trunk@130 b1de8a11-f9be-4011-bde0-cc7ace90066a

lmessages.pas
unitwindowobject.pas

index 39f6f92871319396bf524295f6652b6c58b47b2d..3edc46383f284fb1ebcf2cc80876b9c8d873428c 100755 (executable)
@@ -73,6 +73,7 @@ type
 const\r
   WS_EX_TOOLWINDOW = $80;\r
   WS_POPUP = longint($80000000);\r
+  CW_USEDEFAULT=$80000000;\r
   hinstance=nil;\r
   PM_REMOVE = 1;\r
   WM_USER = 1024;\r
index 1c0d32d124c5505734d27dc254e89ab323fa33b5..706c6a370bb3ec9fce471920d95d50b6308853eb 100644 (file)
@@ -141,6 +141,7 @@ begin
   windows.postmessage(hwndmain,msg,wparam,lparam);\r
 end;\r
 \r
+{$ifdef mswindows}\r
 function twindowobjectbase.ProcessMessage : Boolean;\r
 var\r
     MsgRec : TMsg;\r
@@ -157,13 +158,16 @@ procedure twindowobjectbase.processmessages;
 begin\r
   while processmessage do;\r
 end;\r
+{$endif}\r
 \r
 procedure twindowobjectbase.messageloop;\r
 var\r
   MsgRec : TMsg;\r
 begin\r
   while GetMessage(MsgRec, hwnd(0), 0, 0) do begin\r
+    {$ifdef mswindowss}\r
     TranslateMessage(MsgRec);\r
+    {$endif}\r
     DispatchMessage(MsgRec);\r
     if exitloopflag then exit;\r
     {if not peekmessage(msgrec,0,0,0,PM_NOREMOVE) then onidle}\r