aboutsummaryrefslogtreecommitdiffstats
path: root/lib/ManaTools/Rpmdragora
diff options
context:
space:
mode:
authorAngelo Naselli <anaselli@linux.it>2016-03-13 20:13:53 +0100
committerAngelo Naselli <anaselli@linux.it>2016-03-13 20:13:53 +0100
commitc8ad37121fd16d76176a36f4a6350e7760170a91 (patch)
tree7d1c3ac68b6cff79d2db870e95ccf46b459fac7d /lib/ManaTools/Rpmdragora
parent178d513d49e30e3b91c8f3805e3223e3410544f3 (diff)
downloadmanatools-c8ad37121fd16d76176a36f4a6350e7760170a91.tar
manatools-c8ad37121fd16d76176a36f4a6350e7760170a91.tar.gz
manatools-c8ad37121fd16d76176a36f4a6350e7760170a91.tar.bz2
manatools-c8ad37121fd16d76176a36f4a6350e7760170a91.tar.xz
manatools-c8ad37121fd16d76176a36f4a6350e7760170a91.zip
Fixed rpmdragora icons
Diffstat (limited to 'lib/ManaTools/Rpmdragora')
-rw-r--r--lib/ManaTools/Rpmdragora/gui.pm15
1 files changed, 5 insertions, 10 deletions
diff --git a/lib/ManaTools/Rpmdragora/gui.pm b/lib/ManaTools/Rpmdragora/gui.pm
index 4dd2d56b..bd36d809 100644
--- a/lib/ManaTools/Rpmdragora/gui.pm
+++ b/lib/ManaTools/Rpmdragora/gui.pm
@@ -41,6 +41,7 @@ use MDK::Common::Various qw(chomp_ to_bool);
use MDK::Common::String qw(formatAlaTeX);
use MDK::Common::Math qw(sum);
use MDK::Common::System qw(list_passwd);
+use File::ShareDir ':ALL';
use ManaTools::rpmdragora;
use ManaTools::Rpmdragora::open_db;
@@ -489,28 +490,22 @@ sub set_node_state {
my ($tblItem, $state, $detail_list) = @_;
return if $state eq 'XXX' || !$state;
+ my $icon = File::ShareDir::dist_file(ManaTools::Shared::distName(), "images/rpmdragora/state_$state.png");
if ($detail_list) {
$detail_list->parent()->parent()->startMultipleChanges();
- $tblItem->addCell($state,"/usr/share/rpmdrake/icons/state_$state.png") if(ref $tblItem eq "yui::YCBTableItem");
+
+ $tblItem->addCell($state, $icon) if(ref $tblItem eq "yui::YCBTableItem");
if(to_bool(member($state, qw(base installed to_install)))){
- # it should be parent()->setChecked(1)
$detail_list->checkItem($tblItem, 1);
- # $tblItem->setSelected(1);
}else{
$detail_list->checkItem($tblItem, 0);
- # $tblItem->setSelected(0);
}
-# if(!to_bool($state ne 'base')){
-# #$iter->cell(0)->setLabel('-');
-# $tblItem->cell(0)->setLabel('-');
-# }
$detail_list->parent()->parent()->doneMultipleChanges();
}
else {
# no item list means we use just the item to add state information
- $tblItem->addCell($state,"/usr/share/rpmdrake/icons/state_$state.png") if(ref $tblItem eq "yui::YCBTableItem");
+ $tblItem->addCell($state, $icon) if(ref $tblItem eq "yui::YCBTableItem");
$tblItem->check(to_bool(member($state, qw(base installed to_install))));
-# $tblItem->cell(0)->setLabel('-') if !to_bool($state ne 'base');
}
}