Review Request: Respect filters for counters

David Edmundson kde at davidedmundson.co.uk
Tue Jun 26 10:47:21 UTC 2012



> On June 26, 2012, 5:41 a.m., Dominik Cermak wrote:
> > I'm not sure about one thing: In the patch as it is now (diff 3) I removed all the counting code form the two models, but that means that one have to use the filter model to get the counts. If one wants to use the AccountsModel/GroupsModel without the filter model maybe we should leave the counting code in those models, which would mean we would count twice...

That sounds like it would over complicate things. 

I think it's ok to say the filter model provides additional (not just filtering) information. Maybe we could move the roles there later to clarify it. 


- David


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/105130/#review15153
-----------------------------------------------------------


On June 22, 2012, 10:28 a.m., Dominik Cermak wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/105130/
> -----------------------------------------------------------
> 
> (Updated June 22, 2012, 10:28 a.m.)
> 
> 
> Review request for Telepathy.
> 
> 
> Description
> -------
> 
> I tried to solve it on filter model level. Here is what I've done so far, it's not finished yet but I want to show it so you can speak up if it's totally (or partly) wrong, so I don't waste time. I still have to find out what I can remove from the other code now.
> 
> Also it's not so nice to have so much in data(), so if someone has an idea how to make this more elegant, I'm open for suggestions.
> 
> 
> This addresses bug 300956.
>     http://bugs.kde.org/show_bug.cgi?id=300956
> 
> 
> Diffs
> -----
> 
>   KTp/Models/accounts-filter-model.h 9ed824a1e9a970e33b07343ae9143734857820c8 
>   KTp/Models/accounts-filter-model.cpp c17b3359178ffceca5ae815d41008058218f3bf5 
>   KTp/Models/accounts-model-item.h 11554a9624de0fb7ba2d9123ef770d090a3b952d 
>   KTp/Models/accounts-model-item.cpp 1d65af3fd6d2b8b52562c7dccb63104bb026428d 
>   KTp/Models/accounts-model.cpp 795a1f4615369dbb01f631e9347cf239a523899b 
>   KTp/Models/groups-model-item.h 26dcb00aaf5135a578983680303080dc9e5d51bd 
>   KTp/Models/groups-model-item.cpp 00dbede6e6431c9666cbb293a02c2572e8cac1a5 
>   KTp/Models/groups-model.cpp 6e295ab543b712fd4075684df6cd164beae295e0 
> 
> Diff: http://git.reviewboard.kde.org/r/105130/diff/
> 
> 
> Testing
> -------
> 
> Now the counters work as expected.
> 
> 
> Thanks,
> 
> Dominik Cermak
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-telepathy/attachments/20120626/c413d25a/attachment.html>


More information about the KDE-Telepathy mailing list