From 5a547e6b955ea5c655edb3b87b7ff7676ced36fe Mon Sep 17 00:00:00 2001 From: Angelo Naselli Date: Tue, 6 Nov 2012 20:15:01 +0000 Subject: change code alignment using tabstop=4 shiftwidth=4 expandtab --- ConfigReader.pm | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) (limited to 'ConfigReader.pm') diff --git a/ConfigReader.pm b/ConfigReader.pm index 22d3b49..379d144 100644 --- a/ConfigReader.pm +++ b/ConfigReader.pm @@ -1,3 +1,4 @@ +# vim: set et ts=4 sw=4: # Copyright 2012 Steven Tucker # # This file is part of AdminPanel @@ -29,12 +30,12 @@ sub new { my ($class, $fileName) = @_; my $self = { - my $data = 0, - my $catLen = 0, + my $data = 0, + my $catLen = 0, my $currCat = 0, - my $modLen = 0, - my $currMod = 0, - my $placeHolder = 0 + my $modLen = 0, + my $currMod = 0, + my $placeHolder = 0 }; bless $self, 'ConfigReader'; @@ -46,7 +47,7 @@ sub new { if(ref(@{$self->{data}->{category}}[0]->{module}) eq "ARRAY") { $self->{modLen} = scalar(@{@{$self->{data}->{category}}[0]->{module}}); } else { - $self->{modLen} = 1; + $self->{modLen} = 1; } $self->{currMod} = -1; @@ -57,7 +58,7 @@ sub hasNextCat { my ($self) = @_; if($self->{currCat} + 1 >= $self->{catLen}) { - return 0; + return 0; } return 1; } @@ -67,7 +68,7 @@ sub getNextCat { $self->{currCat}++; if($self->{currCat} >= $self->{catLen}) { - return 0; + return 0; } # Reset the Module Count and Mod length for new Category @@ -75,7 +76,7 @@ sub getNextCat { if(ref(@{$self->{data}->{category}}[$self->{currCat}]->{module}) eq "ARRAY") { $self->{modLen} = scalar(@{@{$self->{data}->{category}}[$self->{currCat}]->{module}}); } else { - $self->{modLen} = 1; + $self->{modLen} = 1; } my $tmp = @{$self->{data}->{category}}[$self->{currCat}]; @@ -87,7 +88,7 @@ sub hasNextMod { my ($self) = @_; if($self->{currMod} + 1 >= $self->{modLen}) { - return 0; + return 0; } return 1; } @@ -100,9 +101,9 @@ sub getNextMod { $self->{currMod}++; if($self->{modLen} == 1) { - $ret = @{$self->{data}->{category}}[$self->{currCat}]->{module}; + $ret = @{$self->{data}->{category}}[$self->{currCat}]->{module}; } else { - $ret = @{@{$self->{data}->{category} }[$self->{currCat}]->{module}}[$self->{currMod}]; + $ret = @{@{$self->{data}->{category} }[$self->{currCat}]->{module}}[$self->{currMod}]; } return $ret; -- cgit v1.2.1