From: Frank Lichtenheld Date: Thu, 23 Feb 2006 19:03:35 +0000 (+0000) Subject: Fix some minor issues X-Git-Tag: switch-to-templates~41 X-Git-Url: https://git.deb.at/?p=deb%2Fpackages.git;a=commitdiff_plain;h=fdc82fe76a3798aea76fdfa7c14f89981a40fb07 Fix some minor issues --- diff --git a/lib/Packages/DoShow.pm b/lib/Packages/DoShow.pm index c9912df..7d5c16b 100644 --- a/lib/Packages/DoShow.pm +++ b/lib/Packages/DoShow.pm @@ -307,11 +307,11 @@ sub do_show { $$menu .= simple_menu( [ _g( "Distribution:" ), _g( "Overview over this suite" ), - "/$suite/", + "$ROOT/$suite/", $suite ], [ _g( "Section:" ), _g( "All packages in this section" ), - "/$suite/$subsection/", + "$ROOT/$suite/$subsection/", $subsection ], ); diff --git a/lib/Packages/HTML.pm b/lib/Packages/HTML.pm index 1de010d..4aeb675 100644 --- a/lib/Packages/HTML.pm +++ b/lib/Packages/HTML.pm @@ -239,13 +239,14 @@ sub dep_item { } # end dep_item sub provides_string { - my ($path, $entry) = @_; + my ($path, $entry,$also) = @_; my @provided_by = split /\s/, $entry; - my $short_desc = "virtual package provided by "; + my $short_desc = $also ? _g("also a virtual package provided by ") + : _g("virtual package provided by "); if (@provided_by < 10) { $short_desc .= join( ', ',map { "$_" } @provided_by); } else { - $short_desc .= scalar(@provided_by)." packages"; + $short_desc .= sprintf( _g("%s packages"), scalar(@provided_by)); } return $short_desc; } @@ -307,8 +308,9 @@ sub print_deps { } elsif (defined $entry->[1]) { $entries{$p_name} ||= $entry; $short_desc = encode_entities( $short_desc, "<>&\"" ); - $short_desc .= "
Also, a ".provides_string( "$ROOT/$path", - $entry->[0] ) + $short_desc .= "
".provides_string( "$ROOT/$path", + $entry->[0], + 1 ) if defined $entry->[0]; push @res_pkgs, dep_item( "$ROOT/$path/$p_name", $p_name, "$pkg_version$arch_str", $short_desc );