aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2008-03-05 02:09:18 +0000
committerThierry Vignaud <tv@mandriva.org>2008-03-05 02:09:18 +0000
commit9baaee15f91261996e110b9e7010826f6b950e23 (patch)
treee74a0256533cd50a153a2277501871e0eda5acb6
parent932b9252ad305455c5cc49861546c21999bbc509 (diff)
downloadrpmdrake-9baaee15f91261996e110b9e7010826f6b950e23.tar
rpmdrake-9baaee15f91261996e110b9e7010826f6b950e23.tar.gz
rpmdrake-9baaee15f91261996e110b9e7010826f6b950e23.tar.bz2
rpmdrake-9baaee15f91261996e110b9e7010826f6b950e23.tar.xz
rpmdrake-9baaee15f91261996e110b9e7010826f6b950e23.zip
remember state of "Show automatically selected packages" (#38138)
-rw-r--r--NEWS1
-rw-r--r--Rpmdrake/gui.pm4
-rwxr-xr-xrpmdrake6
3 files changed, 6 insertions, 5 deletions
diff --git a/NEWS b/NEWS
index 95f88ea1..f72221cd 100644
--- a/NEWS
+++ b/NEWS
@@ -1,6 +1,7 @@
- rpmdrake:
o make search box larger (#38298)
o remember latest view mode (#38138)
+ o remember state of "Show automatically selected packages" (#38138)
Version 4.3.2 - 5 March 2008, Thierry Vignaud
diff --git a/Rpmdrake/gui.pm b/Rpmdrake/gui.pm
index 60bd2f7a..b263103b 100644
--- a/Rpmdrake/gui.pm
+++ b/Rpmdrake/gui.pm
@@ -544,7 +544,7 @@ sub callback_choices {
}
sub deps_msg {
- return 1 if $dont_show_selections;
+ return 1 if $dont_show_selections->[0];
my ($title, $msg, $nodes, $nodes_with_deps) = @_;
my @deps = sort { $a cmp $b } difference2($nodes_with_deps, $nodes);
@deps > 0 or return 1;
@@ -583,7 +583,7 @@ sub toggle_nodes {
@nodes = grep { exists $pkgs->{$_} } @nodes
or return;
#- avoid selecting too many packages at once
- return if !$dont_show_selections && @nodes > 2000;
+ return if !$dont_show_selections->[0] && @nodes > 2000;
my $new_state = !$pkgs->{$nodes[0]}{selected};
my @nodes_with_deps;
diff --git a/rpmdrake b/rpmdrake
index b65550d6..9c8d739e 100755
--- a/rpmdrake
+++ b/rpmdrake
@@ -279,7 +279,7 @@ sub run_treeview_dialog {
$col->{widget} =
Gtk2::TreeViewColumn->new_with_attributes(
' ' . $col->{title} . ' ',
- $col->{renderer} =Gtk2::CellRendererText->new,
+ $col->{renderer} = Gtk2::CellRendererText->new,
($col->{markup} ? (markup => $col->{markup}) : (text => $col->{text})),
)
);
@@ -495,7 +495,7 @@ sub run_treeview_dialog {
Rpmdrake::edit_urpm_sources::run() && $reload_db_and_clear_all->();
}, undef, '<Item>' ],
[ N("/_Options") . N("/_Show automatically selected packages"), undef, sub {
- $dont_show_selections = !$checkbox_show_autoselect->get_active;
+ $dont_show_selections->[0] = !$checkbox_show_autoselect->get_active;
}, undef, '<CheckItem>' ],
),
[ N("/_Help"), undef, undef, undef, '<Branch>' ],
@@ -534,7 +534,7 @@ sub run_treeview_dialog {
$check_boxes{$auto_string}->set_active($::rpmdrake_options{auto}) if !$>;
$checkbox_show_autoselect = $factory->get_widget("<main>" . strip_first_underscore(N("/_Options"), N("/_Show automatically selected packages")))
- and $checkbox_show_autoselect->set_active(!$dont_show_selections);
+ and $checkbox_show_autoselect->set_active(!$dont_show_selections->[0]);
gtkadd(
$w->{window},
gtkpack_(