Index: NantTask.cs
===================================================================
RCS file: /cvsroot/nant/nant/src/NAnt/Tasks/NantTask.cs,v
retrieving revision 1.18
diff -c -r1.18 NantTask.cs
*** NantTask.cs	7 Jun 2002 15:46:29 -0000	1.18
--- NantTask.cs	24 Jun 2002 08:41:06 -0000
***************
*** 19,24 ****
--- 19,25 ----
  // Scott Hernandez (ScottHernandez@hotmail.com)
  
  using System;
+ using System.Collections;
  using System.Collections.Specialized;
  using System.Diagnostics;
  using System.IO;
***************
*** 39,48 ****
          string _buildFileName = null;
          string _target = null;
          bool _inheritAll = true;
! 
!         // TODO: Support for handling properties.  Should it inherit the parent 
!         // project's properties.  How to set properties for the new project?  
!         // The same Ant task handles these issues.
  
          /// <summary>The build file to build.</summary>
          [TaskAttribute("buildfile", Required=true)]
--- 40,46 ----
          string _buildFileName = null;
          string _target = null;
          bool _inheritAll = true;
!         ArrayList _params = new ArrayList();
  
          /// <summary>The build file to build.</summary>
          [TaskAttribute("buildfile", Required=true)]
***************
*** 76,81 ****
--- 74,85 ----
                    project.Properties.Inherit(Project.Properties);
                  }
  
+                 if (_params.Count > 0) {
+                     foreach (PropertyTask param in _params) {
+                         project.Properties.AddReadOnly(param.PropName, param.Value);
+                     }
+                 }
+ 
                  // handle multiple targets
                  if (DefaultTarget != null) {
                      foreach (string t in DefaultTarget.Split(' ')) {
***************
*** 90,95 ****
--- 94,111 ----
                  }
              } finally {
                  Log.Unindent();
+             }
+         }
+ 
+         protected override void InitializeElement(XmlNode elementNode) {
+             foreach (XmlNode node in elementNode) {
+                 if (node.Name.Equals("property")) {
+                     PropertyTask param = new PropertyTask();
+                     param.Project = Project;
+                     param.Initialize(node);
+                     _params.Add(param);
+                 }
+                     
              }
          }
      }
