/usr/share/doc/libgtk2-notify-perl/examples/multi-actions.pl is in libgtk2-notify-perl 0.05-3build2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | #!/usr/bin/perl
use strict;
use warnings;
use Gtk2::Notify -init, 'Multi Actions';
my $n = Gtk2::Notify->new(
'Low disk space',
'You can free up some disk space by emptying the trash can.'
);
$n->set_urgency('critical');
$n->set_category('device');
$n->add_action('help', 'Help', \&action_cb);
$n->add_action('ignore', 'Ignore', \&action_cb);
$n->add_action('empty', 'Empty Trash', \&action_cb);
$n->show;
Gtk2->main;
sub action_cb {
my ($n, $action) = @_;
print "You clicked $action\n";
$n->close;
Gtk2->main_quit;
}
|