mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-30 12:12:47 +02:00
carbon: no-printer failure patch by Patrick Chevalley, #17120
git-svn-id: trunk@29475 -
This commit is contained in:
parent
1491b94132
commit
fb560e9128
@ -297,8 +297,13 @@ begin
|
||||
end;
|
||||
|
||||
procedure TCarbonPrinter.UpdatePrinter;
|
||||
var
|
||||
s: string;
|
||||
begin
|
||||
SetPrinter(GetCurrentPrinterName);
|
||||
s := GetCurrentPrinterName;
|
||||
if trim(s) = '' then // Observed if Default printer set to "Use last printer", and no printing done
|
||||
s := '*'; // so select lcl default
|
||||
SetPrinter(s);
|
||||
Validate;
|
||||
end;
|
||||
|
||||
|
@ -14,7 +14,6 @@ begin
|
||||
// TODO: set and get paper margins, title
|
||||
|
||||
if not Assigned(Printer) then Exit;
|
||||
if Printer.Printers.Count <= 0 then Exit;
|
||||
|
||||
CarbonPrinter := Printer as TCarbonPrinter;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user