summaryrefslogtreecommitdiffstats
path: root/draksnapshot-applet
diff options
context:
space:
mode:
authortv <tv@99302b65-d5f7-0310-b3dd-f8cd6f4e3d94>2008-09-29 17:04:12 +0000
committertv <tv@99302b65-d5f7-0310-b3dd-f8cd6f4e3d94>2008-09-29 17:04:12 +0000
commit1abfe8602f1f9944afb8825572df1d1b8cd2f84b (patch)
tree65d0622947d87475da1ad110eb3dd11c95d71d81 /draksnapshot-applet
parent428a796c627297e67d6c1e74855c25a981292dd8 (diff)
downloaddraksnapshot-1abfe8602f1f9944afb8825572df1d1b8cd2f84b.tar
draksnapshot-1abfe8602f1f9944afb8825572df1d1b8cd2f84b.tar.gz
draksnapshot-1abfe8602f1f9944afb8825572df1d1b8cd2f84b.tar.bz2
draksnapshot-1abfe8602f1f9944afb8825572df1d1b8cd2f84b.tar.xz
draksnapshot-1abfe8602f1f9944afb8825572df1d1b8cd2f84b.zip
hide applet if all discs got umounted (#41176)
git-svn-id: http://svn.mandriva.com/svn/soft/draksnapshot/trunk@247034 99302b65-d5f7-0310-b3dd-f8cd6f4e3d94
Diffstat (limited to 'draksnapshot-applet')
-rwxr-xr-xdraksnapshot-applet7
1 files changed, 7 insertions, 0 deletions
diff --git a/draksnapshot-applet b/draksnapshot-applet
index e50c042..ff2a9fc 100755
--- a/draksnapshot-applet
+++ b/draksnapshot-applet
@@ -102,6 +102,13 @@ if ($dbus) {
my $old_time;
$con->add_filter(sub {
my ($_bus, $msg) = @_; # perl_checker: Net::DBus::Binding::Message::Signal
+
+ # hide if needed (evals really are needed):
+ if (eval { 'DeviceRemoved' eq $msg->get_member() }) {
+ eval { firstCheck() };
+ return 0;
+ }
+
return 0 if $msg->get_member ne 'DeviceAdded';
my $hal = $dbus->get_service($hal_dn);
my $bool;