<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Jul 18, 2013 at 12:11 AM, Milian Wolff <span dir="ltr"><<a href="mailto:mail@milianw.de" target="_blank">mail@milianw.de</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">On Wednesday 17 July 2013 00:08:01 Albert Vaca Cintora wrote:<br>


> > On July 17, 2013, 1:15 a.m., Milian Wolff wrote:<br>
> > > project/projectproxymodel.cpp, line 124<br>
> > > <<a href="http://git.reviewboard.kde.org/r/111537/diff/2/?file=170971#file170971l" target="_blank">http://git.reviewboard.kde.org/r/111537/diff/2/?file=170971#file170971l</a><br>
> > > ine124>> ><br>
<div class="im">> > >     Some kind of caching would be a good idea here I bet. This way this<br>
> > >     function will be called N times on every items for N being the<br>
> > >     depth of the item in the project tree. That doesn't sound good...<br>
> > ><br>
> > >     You could just store something like a QHash<ProjectBaseItem*, bool><br>
> > >     and clear it when the base model gets changed and/or when the<br>
> > >     filter changes.<br>
> I actually tried it, but I can not do it since the function is const and can<br>
> not alter the instance (without a ugly cast to non-const).<br>
<br>
</div>Why did you commit this already? Please, this is not the way to handle such<br>
cases. If someone gave a +1 but someone else raised issues, please first<br>
resolve those before commiting it.<br></blockquote><div><br></div><div>I was with Aleix when I submitted this patch and we saw your comments but we agreed on submitting this "first version" now and iterate over it. I plan to solve the performance issue next, and not only that: for example, I think that the root folder should be always visible even when filtering, and I want to fix that too.</div>

<div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
The "ugly cast" should be resolved via a mutable cache.<br></blockquote><div><br></div><div>Thank you! I didn't know that keyword, and it totally solves the problem. I will implement it this way then.</div>

<div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
Please add this feature.  </blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><br></blockquote><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">


Cheers<br>
<span class=""><font color="#888888">--<br>
Milian Wolff<br>
<a href="mailto:mail@milianw.de">mail@milianw.de</a><br>
<a href="http://milianw.de" target="_blank">http://milianw.de</a></font></span></blockquote></div><br></div></div>