diff Lib/IMPL/Web/TT/Control.pm @ 109:ddf0f037d460

IMPL::DOM::Node updated to support TT, (added childNodesRef and selectNodesRef for using from TT) Some fixes to the web document model. (beta version)
author wizard
date Mon, 17 May 2010 05:12:08 +0400
parents c6fb6964de4c
children 0475eb382085
line wrap: on
line diff
--- a/Lib/IMPL/Web/TT/Control.pm	Fri May 14 16:06:06 2010 +0400
+++ b/Lib/IMPL/Web/TT/Control.pm	Mon May 17 05:12:08 2010 +0400
@@ -17,7 +17,12 @@
 sub CTOR {
 	my ($this,%args) = @_;
 	
+	if ($this->document) {
+		# load a template
+		#$args{template} = $this->document->context->template($args{template}) if ($args{template});
+	}
 	$this->template($args{template}) if $args{template};
+
 	$this->id($this->nodeName . '-' . $nextId++);
 	$this->controlClass($args{controlClass} || 'Control');
 }