summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/network/connection_manager.pm8
-rwxr-xr-xlib/network/drakroam.pm2
-rwxr-xr-xlib/network/netcenter.pm2
3 files changed, 7 insertions, 5 deletions
diff --git a/lib/network/connection_manager.pm b/lib/network/connection_manager.pm
index 9d6145f..cb24859 100644
--- a/lib/network/connection_manager.pm
+++ b/lib/network/connection_manager.pm
@@ -28,9 +28,11 @@ sub create_pixbufs() {
};
}
-sub create {
- my ($in, $net, $w, $pixbufs) = @_;
- { in => $in, net => $net, gui => { w => $w, pixbufs => $pixbufs } };
+sub new {
+ my ($class, $in, $net, $w, $pixbufs) = @_;
+ bless {
+ in => $in, net => $net, gui => { w => $w, pixbufs => $pixbufs },
+ }, $class;
}
sub set_connection {
diff --git a/lib/network/drakroam.pm b/lib/network/drakroam.pm
index 7d499c5..71d7deb 100755
--- a/lib/network/drakroam.pm
+++ b/lib/network/drakroam.pm
@@ -134,7 +134,7 @@ sub main {
$::main_window = $w->{real_window};
my $pixbufs = network::connection_manager::create_pixbufs();
- my $droam = network::connection_manager::create($in, $net, $w, $pixbufs);
+ my $droam = network::connection_manager->new($in, $net, $w, $pixbufs);
network::connection_manager::create_networks_list($droam);
create_drakroam_gui($droam, $dbus, $title, $icon);
diff --git a/lib/network/netcenter.pm b/lib/network/netcenter.pm
index 05e7954..9f15856 100755
--- a/lib/network/netcenter.pm
+++ b/lib/network/netcenter.pm
@@ -15,7 +15,7 @@ use network::tools;
sub build_cmanager {
my ($in, $net, $w, $pixbufs, $connection) = @_;
- my $cmanager = network::connection_manager::create($in, $net, $w, $pixbufs);
+ my $cmanager = network::connection_manager->new($in, $net, $w, $pixbufs);
network::connection_manager::set_connection($cmanager, $connection);
if ($connection->can('get_networks')) {