mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-15 05:49:12 +02:00
* bugfix of range check errors (bug #1588)
+ added win32 types for easier porting to win64
This commit is contained in:
parent
611bff7511
commit
a28c6b5d6a
@ -74,7 +74,7 @@ begin
|
|||||||
else
|
else
|
||||||
StatText[0] := #9; // Center the rest
|
StatText[0] := #9; // Center the rest
|
||||||
StrPCopy(@StatText[1],Text);
|
StrPCopy(@StatText[1],Text);
|
||||||
SendMessage(HStatus,SB_SETTEXT,Num,LongInt(@StatText));
|
SendMessage(HStatus,SB_SETTEXT,WPARAM(Num),LPARAM(@StatText));
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{********************************************************************}
|
{********************************************************************}
|
||||||
@ -189,7 +189,7 @@ Begin
|
|||||||
AskSave;
|
AskSave;
|
||||||
FileName := 'Unsaved';
|
FileName := 'Unsaved';
|
||||||
SetStatusText(0,StrPas(FileName));
|
SetStatusText(0,StrPas(FileName));
|
||||||
SendMessage(HEdit,WM_SetText,1,LongInt(Empty));
|
SendMessage(HEdit,WM_SetText,1,LRESULT(Empty));
|
||||||
SendMessage(HEdit,EM_SetModify,0,0);
|
SendMessage(HEdit,EM_SetModify,0,0);
|
||||||
End;
|
End;
|
||||||
|
|
||||||
@ -222,17 +222,17 @@ begin
|
|||||||
DeleteObject(TheFont);
|
DeleteObject(TheFont);
|
||||||
TheColor := ChooseFontRec.rgbColors;
|
TheColor := ChooseFontRec.rgbColors;
|
||||||
TheFont := CreateFontIndirect(@TheLogFont);
|
TheFont := CreateFontIndirect(@TheLogFont);
|
||||||
SendMessage(HEdit,WM_SETFONT,TheFont,1);
|
SendMessage(HEdit,WM_SETFONT,WPARAM(TheFont),1);
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{********************************************************************}
|
{********************************************************************}
|
||||||
|
|
||||||
Function WindowProc (Window:HWnd;AMessage,WParam,LParam:Longint): Longint;
|
Function WindowProc (Window:HWnd;AMessage: UINT;WParam:WPARAM; LParam:LPARAM): LRESULT;
|
||||||
stdcall; export;
|
stdcall; export;
|
||||||
Var
|
Var
|
||||||
R : rect;
|
R : rect;
|
||||||
StatH : Word;
|
StatH : LONG;
|
||||||
NrMenu : Longint;
|
NrMenu : Longint;
|
||||||
NotiCode : LongInt;
|
NotiCode : LongInt;
|
||||||
Begin
|
Begin
|
||||||
@ -364,7 +364,7 @@ Begin
|
|||||||
end;
|
end;
|
||||||
TheColor := GetSysColor(COLOR_WINDOWTEXT);
|
TheColor := GetSysColor(COLOR_WINDOWTEXT);
|
||||||
TheFont := CreateFontIndirect(@TheLogFont);
|
TheFont := CreateFontIndirect(@TheLogFont);
|
||||||
SendMessage(HEdit,WM_SETFONT,TheFont,1);
|
SendMessage(HEdit,WM_SETFONT,WPARAM(TheFont),1);
|
||||||
ShowWindow(Hedit,SW_Show);
|
ShowWindow(Hedit,SW_Show);
|
||||||
UpdateWindow(HEdit);
|
UpdateWindow(HEdit);
|
||||||
End;
|
End;
|
||||||
@ -424,7 +424,7 @@ Begin
|
|||||||
begin
|
begin
|
||||||
Edges[1] := 400;
|
Edges[1] := 400;
|
||||||
Edges[2] := 500;
|
Edges[2] := 500;
|
||||||
SendMessage(AWnd,SB_SETPARTS,2,LongInt(@Edges));
|
SendMessage(AWnd,SB_SETPARTS,2,LPARAM(@Edges));
|
||||||
end;
|
end;
|
||||||
StatusCreate := AWnd;
|
StatusCreate := AWnd;
|
||||||
End;
|
End;
|
||||||
@ -461,7 +461,11 @@ End.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.1 2001-05-03 21:39:34 peter
|
Revision 1.2 2001-09-04 01:07:59 carl
|
||||||
|
* bugfix of range check errors (bug #1588)
|
||||||
|
+ added win32 types for easier porting to win64
|
||||||
|
|
||||||
|
Revision 1.1 2001/05/03 21:39:34 peter
|
||||||
* moved to own module
|
* moved to own module
|
||||||
|
|
||||||
Revision 1.2 2000/07/13 11:33:10 michael
|
Revision 1.2 2000/07/13 11:33:10 michael
|
||||||
|
@ -18,8 +18,8 @@ uses
|
|||||||
const
|
const
|
||||||
AppName = 'WinHello';
|
AppName = 'WinHello';
|
||||||
|
|
||||||
function WindowProc(Window: HWnd; AMessage, WParam,
|
function WindowProc(Window: HWnd; AMessage: UINT; WParam : WPARAM;
|
||||||
LParam: Longint): Longint; stdcall; export;
|
LParam: LPARAM): LRESULT; stdcall; export;
|
||||||
|
|
||||||
var
|
var
|
||||||
dc : hdc;
|
dc : hdc;
|
||||||
@ -110,7 +110,11 @@ end.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.1 2001-05-03 21:39:34 peter
|
Revision 1.2 2001-09-04 01:08:09 carl
|
||||||
|
* bugfix of range check errors (bug #1588)
|
||||||
|
+ added win32 types for easier porting to win64
|
||||||
|
|
||||||
|
Revision 1.1 2001/05/03 21:39:34 peter
|
||||||
* moved to own module
|
* moved to own module
|
||||||
|
|
||||||
Revision 1.2 2000/07/13 11:33:10 michael
|
Revision 1.2 2000/07/13 11:33:10 michael
|
||||||
|
Loading…
Reference in New Issue
Block a user