diff options
author | Thierry Vignaud <tv@mandriva.org> | 2008-04-14 21:36:39 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mandriva.org> | 2008-04-14 21:36:39 +0000 |
commit | c370dc062a46869c5a955658ade1a15d621dc4f9 (patch) | |
tree | 46500667545489ff17dbc5e23472e07e9c55ed31 | |
parent | a5ac960c3b430c4cef646e31d6ac72b87b66862f (diff) | |
download | rpmdrake-c370dc062a46869c5a955658ade1a15d621dc4f9.tar rpmdrake-c370dc062a46869c5a955658ade1a15d621dc4f9.tar.gz rpmdrake-c370dc062a46869c5a955658ade1a15d621dc4f9.tar.bz2 rpmdrake-c370dc062a46869c5a955658ade1a15d621dc4f9.tar.xz rpmdrake-c370dc062a46869c5a955658ade1a15d621dc4f9.zip |
(run_treeview_dialog) fix a crash when default view is unknown (#40025)
-rw-r--r-- | NEWS | 1 | ||||
-rwxr-xr-x | rpmdrake | 6 |
2 files changed, 6 insertions, 1 deletions
@@ -1,5 +1,6 @@ - rpmdrake: o fix searching when numeric pad's return key is pressed + o fix a crash when default view is unknown (#40025) Version 4.9.13 - 3 April 2008, Thierry Vignaud @@ -584,7 +584,11 @@ sub run_treeview_dialog { # to retrieve a path, one must prevent "accelerators completion": my $get_path = sub { return join('', map { my $i = $_; $i =~ s/_//g; $i } @_) }; - $factory->get_item('<main>' . $get_path->(N("/_View") . '/' . $modes{$mode->[0]}))->set_active(1); + if (my $widget = $factory->get_item('<main>' . $get_path->(N("/_View") . '/' . $modes{$mode->[0]}))) { + $widget->set_active(1); + } else { + warn "Impossible to set $mode->[0] view as default\n"; + } %check_boxes = map { $_ => $factory->get_widget("<main>" . $get_path->($auto_string)); |