From 0c07d2cc8bcefbe2404bac6386090d6176b29e2c Mon Sep 17 00:00:00 2001 From: sekelsenmat Date: Sat, 14 Feb 2015 10:14:24 +0000 Subject: [PATCH] cocoa-printer: Now it can already list printer names, part 2 git-svn-id: trunk@47775 - --- components/printers/cocoa/cocoaprinters.inc | 4 ++-- components/printers/cocoa/cocoaprinters_h.inc | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/components/printers/cocoa/cocoaprinters.inc b/components/printers/cocoa/cocoaprinters.inc index 5eeae0389d..297c19b3b7 100644 --- a/components/printers/cocoa/cocoaprinters.inc +++ b/components/printers/cocoa/cocoaprinters.inc @@ -336,7 +336,7 @@ var FPrinterArray: NSArray; //NewPrinter: NSPrinter; begin - {FPrinterArray := NSPrinter.printerNames(); + FPrinterArray := NSPrinter.printerNames(); FPrinterArray.retain; if FPrinterArray = nil then Exit; @@ -355,7 +355,7 @@ begin Lst.InsertObject(0, NewPrinterName, nil{TObject(NewPrinter)}) else Lst.AddObject(NewPrinterName, nil{TObject(NewPrinter)}); - end;} + end; end; procedure TCocoaPrinter.DoResetPrintersList; diff --git a/components/printers/cocoa/cocoaprinters_h.inc b/components/printers/cocoa/cocoaprinters_h.inc index ba4a01deaf..e984621682 100644 --- a/components/printers/cocoa/cocoaprinters_h.inc +++ b/components/printers/cocoa/cocoaprinters_h.inc @@ -1,6 +1,7 @@ {%MainUnit ../osprinters.pas} -//{$modeswitch objectivec1} +{$modeswitch objectivec1} +{$H+} uses // fpc