diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2007-04-25 12:26:16 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2007-04-25 12:26:16 +0000 |
commit | 126777bc019a54afb4ec51299f2cf9d2841698aa (patch) | |
tree | 97f76e571902ead55ba138f1156a4b4f00b9b779 /perl-install/dbus_object.pm | |
parent | f1f67448efc714873378dfeb8279fae68054a90a (diff) | |
download | drakx-126777bc019a54afb4ec51299f2cf9d2841698aa.tar drakx-126777bc019a54afb4ec51299f2cf9d2841698aa.tar.gz drakx-126777bc019a54afb4ec51299f2cf9d2841698aa.tar.bz2 drakx-126777bc019a54afb4ec51299f2cf9d2841698aa.tar.xz drakx-126777bc019a54afb4ec51299f2cf9d2841698aa.zip |
re-sync after the big svn loss
Diffstat (limited to 'perl-install/dbus_object.pm')
-rw-r--r-- | perl-install/dbus_object.pm | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/perl-install/dbus_object.pm b/perl-install/dbus_object.pm index 445fc73ba..1b4a4264e 100644 --- a/perl-install/dbus_object.pm +++ b/perl-install/dbus_object.pm @@ -23,11 +23,6 @@ sub attach_object { $o->{object} = $service->get_object($o->{path}, $o->{interface}); } -sub dispatch { - my ($o) = @_; - $o->{bus}{connection}->dispatch; -} - sub call_method { my ($o, $method, @args) = @_; $o->{object}->$method(@args); @@ -41,7 +36,7 @@ sub safe_call_method { }; if ($@) { print STDERR "($method) exception: $@\n"; - $o->dispatch; + $o->{bus}{connection}->dispatch; return; } @ret; @@ -49,8 +44,12 @@ sub safe_call_method { sub set_gtk2_watch { my ($o) = @_; + set_gtk2_watch_helper($o->{bus}); +} - $o->{bus}{connection}->set_watch_callbacks(sub { +sub set_gtk2_watch_helper { + my ($bus) = @_; + $bus->{connection}->set_watch_callbacks(sub { my ($con, $watch) = @_; my $flags = $watch->get_flags; require Net::DBus::Binding::Watch; @@ -65,7 +64,7 @@ sub set_gtk2_watch { #- do nothing for WRITABLE watch, we dispatch when needed }, undef, undef); #- do nothing when watch is disabled or toggled yet - $o->dispatch; + $bus->{connection}->dispatch; } 1; |