summaryrefslogtreecommitdiffstats
path: root/lib/network/connection_manager.pm
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.com>2008-11-13 19:04:59 +0000
committerOlivier Blin <oblin@mandriva.com>2008-11-13 19:04:59 +0000
commit37f101317665ed7f44ca31a51b2261dd97e7ebb8 (patch)
tree5215b0c02a7aca894a104dd0f28339725f7ad50d /lib/network/connection_manager.pm
parent5b9547fbf85013e064e7a99b651f35bf82f7346b (diff)
downloaddrakx-net-37f101317665ed7f44ca31a51b2261dd97e7ebb8.tar
drakx-net-37f101317665ed7f44ca31a51b2261dd97e7ebb8.tar.gz
drakx-net-37f101317665ed7f44ca31a51b2261dd97e7ebb8.tar.bz2
drakx-net-37f101317665ed7f44ca31a51b2261dd97e7ebb8.tar.xz
drakx-net-37f101317665ed7f44ca31a51b2261dd97e7ebb8.zip
allow to search in networks list (from Pascal Terjan)
Diffstat (limited to 'lib/network/connection_manager.pm')
-rw-r--r--lib/network/connection_manager.pm6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/network/connection_manager.pm b/lib/network/connection_manager.pm
index 7ceada9..0ac2cda 100644
--- a/lib/network/connection_manager.pm
+++ b/lib/network/connection_manager.pm
@@ -298,6 +298,12 @@ sub create_networks_list {
#FIXME Should define an explicit order OPEN < WEP < WPA
return $s1 cmp $s2;
});
+ $cmanager->{gui}{networks_list}->set_enable_search(1);
+ $cmanager->{gui}{networks_list}->set_search_column(1);
+ $cmanager->{gui}{networks_list}->set_search_equal_func(sub {
+ my ($model, $column, $key, $iter, $data) = @_;
+ return $model->get($iter, 2) !~ /^\Q$key/i;
+ });
}
sub select_network {