From 66f2badbfcb03c16bf19c3dd2439e1a7264a768c Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Tue, 13 Nov 2012 09:32:16 +0100 Subject: [PATCH] Druckoptionen 'Drucker' & 'Warteschlange' auch anzeigen, wenn nur OpenDocument aktiviert ist Fixt #1840. --- bin/mozilla/io.pl | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/bin/mozilla/io.pl b/bin/mozilla/io.pl index 60a535f36..0d7601ea6 100644 --- a/bin/mozilla/io.pl +++ b/bin/mozilla/io.pl @@ -38,7 +38,7 @@ use Carp; use CGI; -use List::MoreUtils qw(uniq); +use List::MoreUtils qw(any uniq); use List::Util qw(min max first); use SL::CVar; @@ -1089,11 +1089,12 @@ sub print_options { opthash("inline", $form->{SM}{inline}, $locale->text('In-line')) if ($form->{media} eq 'email'); + my $printable_templates = any { $::lx_office_conf{print_templates}->{$_} } qw(latex opendocument); push @MEDIA, grep $_, opthash("screen", $form->{OP}{screen}, $locale->text('Screen')), - ($form->{printers} && scalar @{ $form->{printers} } && $::lx_office_conf{print_templates}->{latex}) ? + ($printable_templates && $form->{printers} && scalar @{ $form->{printers} }) ? opthash("printer", $form->{OP}{printer}, $locale->text('Printer')) : undef, - ($::lx_office_conf{print_templates}->{latex} && !$options{no_queue}) ? + ($printable_templates && !$options{no_queue}) ? opthash("queue", $form->{OP}{queue}, $locale->text('Queue')) : undef if ($form->{media} ne 'email'); -- 2.20.1