mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-11-26 09:47:16 +01:00
Cocoa: Publish CFStringToString procedure
git-svn-id: trunk@44490 -
This commit is contained in:
parent
b20ef6a9a5
commit
e6f28409e4
@ -64,6 +64,8 @@ function ColorToNSColor(const Color: TColorRef): NSColor; inline;
|
|||||||
|
|
||||||
procedure ShortcutToKeyEquivalent(const AShortCut: TShortcut; out Key: string; out shiftKeyMask: NSUInteger);
|
procedure ShortcutToKeyEquivalent(const AShortCut: TShortcut; out Key: string; out shiftKeyMask: NSUInteger);
|
||||||
|
|
||||||
|
function CFStringToString(AString: CFStringRef): String;
|
||||||
|
|
||||||
implementation
|
implementation
|
||||||
|
|
||||||
const
|
const
|
||||||
@ -178,6 +180,8 @@ begin
|
|||||||
ShiftKeyMask := ShiftKeyMask + NSCommandKeyMask;
|
ShiftKeyMask := ShiftKeyMask + NSCommandKeyMask;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
function CFStringToStr(AString: CFStringRef; Encoding: CFStringEncoding = DEFAULT_CFSTRING_ENCODING): String;
|
function CFStringToStr(AString: CFStringRef; Encoding: CFStringEncoding = DEFAULT_CFSTRING_ENCODING): String;
|
||||||
var
|
var
|
||||||
Str: Pointer;
|
Str: Pointer;
|
||||||
@ -210,6 +214,11 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function CFStringToString(AString: CFStringRef): String;
|
||||||
|
begin
|
||||||
|
result:=CFStringToStr(AString);
|
||||||
|
end;
|
||||||
|
|
||||||
function GetNSObjectView(obj: NSObject): NSView;
|
function GetNSObjectView(obj: NSObject): NSView;
|
||||||
begin
|
begin
|
||||||
Result := nil;
|
Result := nil;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user