<html>
<head>
</head>
<body>
Hi Thomas,<br>
<blockquote type="cite" cite="mid:20030502213337.GA20842@planescape.com">
  <blockquote type="cite">
    <pre wrap="">Well, I have had a look at MS Project and at gnome/mrproject. In both <br>these programs a task becomes a subproject as soon as it gets some <br>children. Child tasks can be generated simply by indenting other tasks.<br><br>I would also say that this is the behaviour that does not surprise the <br>user.<br></pre>
    </blockquote>
    <pre wrap=""><!----><br>Sounds fine then; but its too long ago that I looked at the code so I<br>don't know how to solve that; I suspect you have an idea?</pre>
    </blockquote>
Well...<br>
My first idea is to drop the subclasses of the node. If that is too little
OOP, we can have a look at the state pattern from the "GOF".<br>
One nice link about it is <a class="moz-txt-link-freetext" href="http://www002.upp.so-net.ne.jp/ys_oota/mdp/State/">http://www002.upp.so-net.ne.jp/ys_oota/mdp/State/</a>
:)<br>
But the link <a class="moz-txt-link-freetext" href="http://exciton.cs.rice.edu/research/StatePat/seminar1/sld009.htm">http://exciton.cs.rice.edu/research/StatePat/seminar1/sld009.htm</a>
might be easier to read.<br>
    <br>
In our case the node would keep a reference to a state object. These state
objects have the class hierarchy of Milestone, Project, Task, Subproject.<br>
In all cases where this is neccessary, the node just forwards requests to
its state object. <br>
And just in case we have an edit operation that would require to change between
task and project etc. we would replace the state object. The node object
would remain.<br>
    <br>
Let's think about these alternatives and let us look for more alternatives,
before we decide what to do.<br>
    <br>
Regards,<br>
    <br>
Heiko<br>
    </body>
    </html>