summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/network/connection.pm1
-rwxr-xr-xlib/network/netcenter.pm4
2 files changed, 4 insertions, 1 deletions
diff --git a/lib/network/connection.pm b/lib/network/connection.pm
index 75564e0..cf3d14c 100644
--- a/lib/network/connection.pm
+++ b/lib/network/connection.pm
@@ -93,6 +93,7 @@ sub get_status {
=item get_status_icon()
Get status icon path (connected/disconnected/unconfigured)
+The file may not exist
=cut
diff --git a/lib/network/netcenter.pm b/lib/network/netcenter.pm
index 80b5909..c779bf8 100755
--- a/lib/network/netcenter.pm
+++ b/lib/network/netcenter.pm
@@ -57,8 +57,10 @@ sub main {
child => gtknew('VBox', spacing => 5, children_tight => [
map_index {
my $cmanager = build_cmanager($in, $net, $w, $pixbufs, $_);
+ my $icon = $_->get_status_icon;
+ ugtk2::_find_imgfile($icon) or $icon = $_->get_type_icon;
my $head = gtknew('HBox', children => [
- 0, gtknew('Image', file => $_->get_status_icon),
+ 0, gtknew('Image', file => $icon),
0, gtknew('Label', padding => [ 5, 0 ]),
1, gtknew('Label', ellipsize => 'end', alignment => [ 0, 0 ], text_markup => '<b>' . $_->get_description . '</b>'),
0, gtknew('Label', padding => [ 2, 0 ]),