Cocoa/MultiDisplay: unused functions removed

This commit is contained in:
rich2014 2023-10-17 23:32:52 +08:00
parent 8750601c96
commit afc2dae9d3
2 changed files with 0 additions and 23 deletions

View File

@ -42,7 +42,6 @@ function NSRectToRect(const NS: NSRect): TRect;
procedure NSToLCLRect(const ns: NSRect; ParentHeight: Single; out lcl: TRect);
procedure LCLToNSRect(const lcl: TRect; ParentHeight: Single; out ns: NSRect);
function NSScreenZeroHeight: CGFloat;
function NSPrimaryScreenHeight: CGFloat;
function NSGlobalScreenHeight: CGFloat;
@ -753,11 +752,6 @@ begin
ns.size.height:=lcl.Bottom-lcl.Top;
end;
function NSScreenZeroHeight: CGFloat;
begin
Result := NSScreen(NSScreen.screens.objectAtIndex(0)).frame.size.height;
end;
// the height of primary display
function NSPrimaryScreenHeight: CGFloat;
begin

View File

@ -1333,23 +1333,6 @@ begin
Point.y := contentView.bounds.size.height - Point.y;
end;
procedure NSScreenGetRect(sc: NSScreen; mainScreenHeight: double; out r: TRect);
var
fr : NSRect;
begin
fr := sc.frame;
r := Bounds(
Round(fr.origin.x),
Round(fr.origin.y - fr.size.height + mainScreenHeight),
Round(fr.size.width), Round(fr.size.height)
);
end;
procedure NSScreenGetRect(sc: NSScreen; out r: TRect);
begin
NSScreenGetRect(sc, NSScreen.mainScreen.frame.size.height, r);
end;
procedure LCLWindowExtension.lclSetFrame(const r: TRect);
var
ns : NSRect;