Review Request 121880: FocusedTreeView: use a timer to batch recomputations of column width

Milian Wolff mail at milianw.de
Tue Jan 6 12:53:13 UTC 2015


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/121880/#review73257
-----------------------------------------------------------


afaik, the FocusedTreeView is only being used by the OutputWidget, which already contains code like this as well to scroll the view to the bottom. Could we merge the two somehow to get rid of the timer duplication?

- Milian Wolff


On Jan. 6, 2015, 11:58 a.m., Nicolai Hähnle wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/121880/
> -----------------------------------------------------------
> 
> (Updated Jan. 6, 2015, 11:58 a.m.)
> 
> 
> Review request for KDevelop.
> 
> 
> Repository: kdevplatform
> 
> 
> Description
> -------
> 
> We need to recompute the column width when a new row is inserted to ensure that
> the horizontal scrollbar behaves properly.
> 
> Under certain circumstances (in particular: running an extremely spammy process
> or filtering large outputs), rowInserted is called many times in quick succession,
> which leads to essentially quadratic runtime behavior, because some of the
> recomputation triggers a slow layout recomputation inside QTreeView. So we delay
> the recomputation until we get back to the event loop.
> 
> After this change, output views work smoothly even on very large outputs.
> 
> 
> Diffs
> -----
> 
>   util/focusedtreeview.h f813c2de6d8679c57c1477d8bc63c29e2139ba98 
>   util/focusedtreeview.cpp b58720313cc9c3ca08ae401c009425a30cdc326a 
> 
> Diff: https://git.reviewboard.kde.org/r/121880/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Nicolai Hähnle
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20150106/bd2bd6dc/attachment-0001.html>


More information about the KDevelop-devel mailing list