diff Lib/IMPL/Web/View/TTLoader.pm @ 310:0a9d51cf6dfd

*TTView: refactoring, document supports custom classes, layouts are become controls
author sergey
date Fri, 19 Apr 2013 16:39:01 +0400
parents 5e4e7c8fbca1
children d3b5a67ad2e8
line wrap: on
line diff
--- a/Lib/IMPL/Web/View/TTLoader.pm	Fri Apr 19 00:27:51 2013 +0400
+++ b/Lib/IMPL/Web/View/TTLoader.pm	Fri Apr 19 16:39:01 2013 +0400
@@ -90,6 +90,7 @@
     my $factory = TTFactory->new($tt->class || TTDocument, $tt, $ctx, $name, $registry);
     
     $vars->{registry} = $registry;
+    $vars->{layoutBase} = $this->layoutBase;
     
     return $factory->new( $vars );    
 }
@@ -115,19 +116,6 @@
     return $tt;
 }
 
-sub layout {
-	my ($this,$name) = @_;
-	
-	my $layout;
-	
-	if ($this->layoutBase) {
-		$layout = $this->layoutBase . "/";
-	}
-	
-	$layout .= $name;
-	return $this->template($layout);
-}
-
 sub _appendExt {
     my ($this,$name) = @_;