From 908cafda2c2585220d0b5ce222dc09ff8460874d Mon Sep 17 00:00:00 2001 From: Olivier Blin Date: Wed, 30 Apr 2008 19:23:07 +0000 Subject: move out some variables (for future usage) --- lib/network/monitor.pm | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'lib/network') diff --git a/lib/network/monitor.pm b/lib/network/monitor.pm index 2b0ba94..fb9247a 100644 --- a/lib/network/monitor.pm +++ b/lib/network/monitor.pm @@ -5,13 +5,13 @@ use dbus_object; our @ISA = qw(dbus_object); +my $monitor_service = "com.mandriva.monitoring"; +my $monitor_path = "/com/mandriva/monitoring/wireless"; +my $monitor_interface = "com.mandriva.monitoring.wireless"; + sub new { my ($type, $bus) = @_; - dbus_object::new($type, - $bus, - "com.mandriva.monitoring", - "/com/mandriva/monitoring/wireless", - "com.mandriva.monitoring.wireless"); + dbus_object::new($type, $bus, $monitor_service, $monitor_path, $monitor_interface); } sub list_wireless { @@ -104,7 +104,8 @@ sub list_wireless { sub select_network { my ($o, $id) = @_; - $o->call_method('SelectNetwork', Net::DBus::dbus_uint32($id)); + my $method = 'SelectNetwork'; + $o->call_method($method, Net::DBus::dbus_uint32($id)); } 1; -- cgit v1.2.1