2 #RFKill-Applet (Harvie 2oo9)
8 my $rfkill = '/sys/class/rfkill/rfkill*/state';
9 #my $rfkill = '/sys/devices/*/*/*/rfkill/rfkill*/state';
10 my $icon_e = 'gnome-dev-wavelan'; #enabled
11 my $icon_d = 'emblem-unreadable'; #disabled
13 my $statusicon = Gtk2
::StatusIcon
->new();
14 #$statusicon->signal_connect(activate => sub { Gtk2->main_quit; }); #exit on click...
20 #my $thr = threads->new(sub {
24 $state = `head -c 1 $rfkill 2> /dev/null`;
27 $statusicon->set_from_icon_name($icon_e);
28 $statusicon->set_tooltip_text('Radio enabled');
30 $statusicon->set_from_icon_name($icon_d);
31 $statusicon->set_tooltip_text('Radio disabled');
This page took 0.2981 seconds and 4 git commands to generate.