diff Lib/IMPL/Web/TT/Collection.pm @ 194:4d0e1962161c

Replaced tabs with spaces IMPL::Web::View - fixed document model, new features (control classes, document constructor parameters)
author cin
date Tue, 10 Apr 2012 20:08:29 +0400
parents d1676be8afcc
children
line wrap: on
line diff
--- a/Lib/IMPL/Web/TT/Collection.pm	Tue Apr 10 08:13:22 2012 +0400
+++ b/Lib/IMPL/Web/TT/Collection.pm	Tue Apr 10 20:08:29 2012 +0400
@@ -7,35 +7,35 @@
 
 our $AUTOLOAD;
 sub AUTOLOAD {
-	my $this = shift;
-	my ($method) = ($AUTOLOAD =~ /(\w+)$/);
-	
-	return if $method eq 'DESTROY';
-	
-	if ( @_ >= 1 ) {
-		# set
-		
-		if ($method =~ /^add(\w+)/) {
-			my ($name,$args) = @_;
-			return $this->appendChild($this->document->CreateControl($name,$1,$args));
-		}
-		
-		# we can't assing a node, so this is a dynamic property
-		return $this->nodeProperty($method,@_);
-	} else {
-		# get
-		# try a dynamic property first 
-		if ( my $val = $this->nodeProperty($method) ) {
-			return $val;
-		} else {
-		# and return a first child node as last opportunity
-			my @result = $this->selectNodes($method);
-	
-			return $result[0] if @result;
-		}
-	}
-	
-	return;
+    my $this = shift;
+    my ($method) = ($AUTOLOAD =~ /(\w+)$/);
+    
+    return if $method eq 'DESTROY';
+    
+    if ( @_ >= 1 ) {
+        # set
+        
+        if ($method =~ /^add(\w+)/) {
+            my ($name,$args) = @_;
+            return $this->appendChild($this->document->CreateControl($name,$1,$args));
+        }
+        
+        # we can't assing a node, so this is a dynamic property
+        return $this->nodeProperty($method,@_);
+    } else {
+        # get
+        # try a dynamic property first 
+        if ( my $val = $this->nodeProperty($method) ) {
+            return $val;
+        } else {
+        # and return a first child node as last opportunity
+            my @result = $this->selectNodes($method);
+    
+            return $result[0] if @result;
+        }
+    }
+    
+    return;
 }
 
 1;