<div><br><br><div class="gmail_quote">On Thu, Apr 8, 2010 at 6:42 PM, Aaron J. Seigo <span dir="ltr">&lt;<a href="mailto:aseigo@kde.org">aseigo@kde.org</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">On April 8, 2010, Christophe Olinger wrote:<br>
&gt; One thing missing is the layout of the actual subComponents in the applets.<br>
&gt; Currently they are just added in a row. For this we need the API. The<br>
&gt; layout should recognize which type of applet arrives and lay it out<br>
&gt; accordingly. That means lots of if/thens within tha applet code. This also<br>
&gt; means adding new states with new subcomponents would mean adding if/tehns<br>
&gt; to the actual addToLayout functions in the applets.<br>
<br>
</div>what i&#39;d recommend is to provide a way to tag subcomponents with values (e.g.<br>
an enum) that says something about what they do.<br>
<br>
divide up each MainComponent into &quot;zones&quot; (navigation, media playing, status,<br>
whatever :) and then each sub component can be tagged by the creator of the<br>
sub component (e.g. a state) with what it is.<br>
<br>
then the main components will know which zone they belong in.<br>
<br>
from there, i&#39;d go with a naive implementation, at least at first, that just<br>
puts things into the respective zones on a first-come-first-placed basis.<br>
<br>
this alleviates the needs for if/else and odd interactions between state<br>
plugins and the main components that need to lay out a plugin&#39;s custom sub<br>
components.<br>
<font color="#888888"><br>
--<br></font></blockquote><div><br></div><div>Great suggestion. Exactly what I had in mind :-). I&#39;ll try to hack on that in the coming days. First finding the cause of this stupid medialyout error :-/ Propably some wrong includes or declarations.<div>
<br></div><div>I&#39;ll also apply for an SVN account. Lots of thanks to all of you for the motivation.</div></div><div><br></div><div> </div><div>Cheers,</div><div><br></div><div>Chris</div></div><br></div>