mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-05 08:17:25 +01:00
lcl-cocoa: Fixes compilation errors in last cocoa commit
git-svn-id: trunk@46423 -
This commit is contained in:
parent
80a4317ad8
commit
8d1660b99e
@ -53,6 +53,7 @@ type
|
||||
procedure ResignFirstResponder;
|
||||
procedure DidBecomeKeyNotification;
|
||||
procedure DidResignKeyNotification;
|
||||
procedure SendOnChange;
|
||||
// non event methods
|
||||
function DeliverMessage(Msg: Cardinal; WParam: WParam; LParam: LParam): LResult;
|
||||
function GetPropStorage: TStringList;
|
||||
@ -3063,14 +3064,11 @@ begin
|
||||
end;
|
||||
|
||||
procedure TCocoaSlider.sliderAction(sender: id);
|
||||
var
|
||||
Msg: TLMessage;
|
||||
begin
|
||||
SnapToInteger();
|
||||
// OnChange event
|
||||
FillChar(Msg, SizeOf(Msg), #0);
|
||||
Msg.Msg := LM_CHANGED;
|
||||
DeliverMessage(Msg);
|
||||
if callback <> nil then
|
||||
callback.SendOnChange();
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
@ -1059,7 +1059,7 @@ class procedure TCocoaWSTrackBar.SetOrientation(
|
||||
begin
|
||||
if (AOrientation = trHorizontal) and (ATrackBar.Height > ATrackBar.Width) then
|
||||
ATrackBar.Width := ATrackBar.Height + 1
|
||||
else if (AOrientation = trVertical) and (ATrackBar.Width > ATrackBar.Height then
|
||||
else if (AOrientation = trVertical) and (ATrackBar.Width > ATrackBar.Height) then
|
||||
ATrackBar.Height := ATrackBar.Width + 1;
|
||||
end;
|
||||
|
||||
|
||||
@ -61,6 +61,7 @@ type
|
||||
procedure ResignFirstResponder; virtual;
|
||||
procedure DidBecomeKeyNotification; virtual;
|
||||
procedure DidResignKeyNotification; virtual;
|
||||
procedure SendOnChange; virtual;
|
||||
|
||||
function DeliverMessage(var Msg): LRESULT; virtual; overload;
|
||||
function DeliverMessage(Msg: Cardinal; WParam: WParam; LParam: LParam): LResult; virtual; overload;
|
||||
@ -984,6 +985,11 @@ begin
|
||||
LCLSendKillFocusMsg(Target);
|
||||
end;
|
||||
|
||||
procedure TLCLCommonCallback.SendOnChange;
|
||||
begin
|
||||
SendSimpleMessage(Target, LM_CHANGED);
|
||||
end;
|
||||
|
||||
function TLCLCommonCallback.DeliverMessage(var Msg): LRESULT;
|
||||
begin
|
||||
Result := LCLMessageGlue.DeliverMessage(Target, Msg);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user