diff options
author | Thierry Vignaud <tv@mandriva.org> | 2007-03-07 11:32:05 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mandriva.org> | 2007-03-07 11:32:05 +0000 |
commit | 20474b048d996f71a4d1a80057aefcd2f586a7bf (patch) | |
tree | 6ede9ae0474f01b82188c6c00e5bc29f055a7e50 | |
parent | c0b6411dfd7dbb8374eab03d42c1b886a02c8df2 (diff) | |
download | rpmdrake-20474b048d996f71a4d1a80057aefcd2f586a7bf.tar rpmdrake-20474b048d996f71a4d1a80057aefcd2f586a7bf.tar.gz rpmdrake-20474b048d996f71a4d1a80057aefcd2f586a7bf.tar.bz2 rpmdrake-20474b048d996f71a4d1a80057aefcd2f586a7bf.tar.xz rpmdrake-20474b048d996f71a4d1a80057aefcd2f586a7bf.zip |
(format_pkg_simplifiedinfo) show again version, currently installed version (#26946), source medium (#23153), size, architecture (#26410)
-rw-r--r-- | Rpmdrake/gui.pm | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/Rpmdrake/gui.pm b/Rpmdrake/gui.pm index f06ffb13..491ed1d2 100644 --- a/Rpmdrake/gui.pm +++ b/Rpmdrake/gui.pm @@ -60,7 +60,7 @@ our %pkg_columns = ( sub format_pkg_simplifiedinfo { my ($pkgs, $key, $urpm, $descriptions) = @_; - my ($name, $_version) = split_fullname($key); + my ($name, $version) = split_fullname($key); my $medium = pkg2medium($pkgs->{$key}{pkg}, $urpm)->{name}; my $update_descr = $pkgs->{$key}{pkg}->flag_upgrade && $descriptions->{$name}{pre} && $descriptions->{$name}{medium} eq $medium; my $s = ugtk2::markup_to_TextView_format(join("\n", format_header($name . ' - ' . translate($pkgs->{$key}{summary})) . @@ -83,6 +83,22 @@ sub format_pkg_simplifiedinfo { (escape_text_for_TextView_markup_format($pkgs->{$key}{description} || $descriptions->{$name}{description}) || '<i>' . N("No description") . '</i>') )) }; push @$s, [ "\n" ]; + push @$s, [ gtkadd(gtkshow(my $exp0 = Gtk2::Expander->new(format_field(N("Details:")))), + gtknew('TextView', text => ugtk2::markup_to_TextView_format( + join("\n", + format_field(N("Version: ")) . $version, + ($pkgs->{$key}{pkg}->flag_installed ? + format_field(N("Currently installed version: ")) . find_installed_version($pkgs->{$key}{pkg}) + : () + ), + format_field(N("Architecture: ")) . $pkgs->{$key}{pkg}->arch, + format_field(N("Size: ")) . N("%s KB", int($pkgs->{$key}{pkg}->size/1024)), + format_field(N("Medium: ")) . pkg2medium($pkgs->{$key}{pkg}, $urpm)->{name}, + ), + ), + )) ]; + $exp0->set_use_markup(1); + push @$s, [ "\n\n" ]; push @$s, [ gtkadd(gtkshow(my $exp = Gtk2::Expander->new(format_field(N("Files:")))), gtknew('TextView', text => exists $pkgs->{$key}{files} ? |