mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-16 05:00:46 +01:00
lcl: cocoa: fixed some compilation issue
git-svn-id: trunk@46781 -
This commit is contained in:
parent
9928fb1647
commit
a087d98729
@ -122,7 +122,7 @@ type
|
||||
private
|
||||
FMenuItemTarget: TComponent;
|
||||
public
|
||||
constructor Create(AOwner: NSObject; AMenuItemTarget: TComponent);
|
||||
constructor Create(AOwner: NSObject; AMenuItemTarget: TComponent); reintroduce;
|
||||
procedure ItemSelected;
|
||||
end;
|
||||
|
||||
|
||||
@ -24,10 +24,10 @@ interface
|
||||
|
||||
uses
|
||||
// Libs
|
||||
MacOSAll, CocoaAll,
|
||||
MacOSAll, CocoaAll, Classes, sysutils,
|
||||
// LCL
|
||||
Controls, StdCtrls, Graphics, LCLType, LMessages, LCLProc, LCLMessageGlue,
|
||||
Classes, LazUtf8Classes,
|
||||
LazUtf8Classes,
|
||||
// Widgetset
|
||||
WSStdCtrls, WSLCLClasses, WSControls, WSProc,
|
||||
// LCL Cocoa
|
||||
@ -181,7 +181,7 @@ type
|
||||
class function RetrieveState(const ACustomCheckBox: TCustomCheckBox): TCheckBoxState; override;
|
||||
class procedure SetState(const ACustomCheckBox: TCustomCheckBox; const NewState: TCheckBoxState); override;
|
||||
//
|
||||
class procedure GetPreferredSize(const AWinControl: TWinControl; var PreferredWidth, PreferredHeight: integer; WithThemeSpace: Boolean); override;
|
||||
class procedure GetPreferredSize(const AWinControl: TWinControl; var PreferredWidth, PreferredHeight: integer; {%H-}WithThemeSpace: Boolean); override;
|
||||
end;
|
||||
|
||||
{ TCocoaWSToggleBox }
|
||||
@ -486,8 +486,8 @@ begin
|
||||
|
||||
lOldSize := lButton.bounds.size;
|
||||
lButton.sizeToFit();
|
||||
PreferredWidth := Integer(lButton.bounds.size.width);
|
||||
PreferredHeight := Integer(lButton.bounds.size.height);
|
||||
PreferredWidth := round(lButton.bounds.size.width);
|
||||
PreferredHeight := round(lButton.bounds.size.height);
|
||||
lButton.setBoundsSize(lOldSize);
|
||||
end;
|
||||
|
||||
@ -622,6 +622,8 @@ function GetLinesCount(const s: AnsiString): Integer;
|
||||
var
|
||||
ofs : Integer;
|
||||
begin
|
||||
Result:=0;
|
||||
ofs:=0;
|
||||
GetLineStart(s, -1, ofs, Result);
|
||||
end;
|
||||
|
||||
@ -639,6 +641,8 @@ var
|
||||
t : Integer;
|
||||
begin
|
||||
s:=GetTextStr;
|
||||
t:=0;
|
||||
ofs:=0;
|
||||
GetLineStart(s, Index, ofs, t);
|
||||
eofs:=ofs;
|
||||
while (eofs<=length(s)) and not (s[eofs] in [#10,#13]) do
|
||||
|
||||
Loading…
Reference in New Issue
Block a user