summaryrefslogtreecommitdiffstats
path: root/perl-install/printer/office.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2002-11-14 17:36:32 +0000
committerPascal Rigaux <pixel@mandriva.com>2002-11-14 17:36:32 +0000
commit78e8097c578fb334c7440a5459fdb7aecc827feb (patch)
tree365a303dd0143c940451e55df0316b3aaf6c0a67 /perl-install/printer/office.pm
parent0321ff25b57d94626c9a5c2d02fbdb5448474fc6 (diff)
downloaddrakx-78e8097c578fb334c7440a5459fdb7aecc827feb.tar
drakx-78e8097c578fb334c7440a5459fdb7aecc827feb.tar.gz
drakx-78e8097c578fb334c7440a5459fdb7aecc827feb.tar.bz2
drakx-78e8097c578fb334c7440a5459fdb7aecc827feb.tar.xz
drakx-78e8097c578fb334c7440a5459fdb7aecc827feb.zip
- add/remove spaces to make perl_checker happy
- remove redundant parentheses - add some parentheses for clarity
Diffstat (limited to 'perl-install/printer/office.pm')
-rw-r--r--perl-install/printer/office.pm17
1 files changed, 8 insertions, 9 deletions
diff --git a/perl-install/printer/office.pm b/perl-install/printer/office.pm
index f870c4dac..a933fca29 100644
--- a/perl-install/printer/office.pm
+++ b/perl-install/printer/office.pm
@@ -47,7 +47,7 @@ sub configureoffice {
# Load Star Office printer config file
my $configfilecontent = readsofficeconfigfile($configfilename);
# Update remote CUPS queues
- if (0 && ($printer->{SPOOLER} eq "cups") &&
+ if (0 && $printer->{SPOOLER} eq "cups" &&
((-x "$::prefix/usr/bin/curl") || (-x "$::prefix/usr/bin/wget"))) {
my @printerlist = printer::cups::get_remote_queues();
foreach my $listentry (@printerlist) {
@@ -113,7 +113,7 @@ sub add_cups_remote_to_office {
# Load Star Office printer config file
my $configfilecontent = readsofficeconfigfile($configfilename);
# Update remote CUPS queues
- if (($printer->{SPOOLER} eq "cups") &&
+ if ($printer->{SPOOLER} eq "cups" &&
((-x "$::prefix/usr/bin/curl") || (-x "$::prefix/usr/bin/wget"))) {
my @printerlist = printer::cups::get_remote_queues();
foreach my $listentry (@printerlist) {
@@ -136,8 +136,7 @@ sub add_cups_remote_to_office {
}
# Does the file exist and is it not an error message?
if ((-r "$::prefix/etc/foomatic/$queue.ppd") &&
- (cat_("$::prefix/etc/foomatic/$queue.ppd") =~
- /^\*PPD-Adobe/)) {
+ cat_("$::prefix/etc/foomatic/$queue.ppd") =~ /^\*PPD-Adobe/) {
$configfilecontent =
$suites{$suite}{make}($printer, $queue,
$configprefix,
@@ -225,7 +224,7 @@ sub makestarofficeprinterentry {
$configfile = addentry("$queue.PostScript.$queue",
"Level=$pslevel", $configfile);
# Set Color/BW
- my $color = ($ppd =~ /^\s*\*ColorDevice:\s*\"?([Tt]rue)\"?\s*$/m) ? "1" : "0";
+ my $color = $ppd =~ /^\s*\*ColorDevice:\s*\"?([Tt]rue)\"?\s*$/m ? "1" : "0";
$configfile = removeentry("$queue.PostScript.$queue", "BitmapColor=", $configfile);
$configfile = addentry("$queue.PostScript.$queue", "BitmapColor=$color", $configfile);
# Set the default paper size
@@ -266,8 +265,8 @@ sub makeopenofficeprinterentry {
$configfile);
# "Comment" line
$configfile = removeentry($queue, "Comment=", $configfile);
- if (($printer->{configured}{$queue}) &&
- ($printer->{configured}{$queue}{queuedata}{desc})) {
+ if ($printer->{configured}{$queue} &&
+ $printer->{configured}{$queue}{queuedata}{desc}) {
$configfile = addentry
($queue,
"Comment=$printer->{configured}{$queue}{queuedata}{desc}",
@@ -279,8 +278,8 @@ sub makeopenofficeprinterentry {
}
# "Location" line
$configfile = removeentry($queue, "Location=", $configfile);
- if (($printer->{configured}{$queue}) &&
- ($printer->{configured}{$queue}{queuedata}{loc})) {
+ if ($printer->{configured}{$queue} &&
+ $printer->{configured}{$queue}{queuedata}{loc}) {
$configfile = addentry
($queue,
"Location=$printer->{configured}{$queue}{queuedata}{loc}",