Review Request: Be more conservative about emitting dataUpdated() signal

Aaron Seigo aseigo at kde.org
Tue Aug 26 22:51:57 CEST 2008


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard.vidsolbach.de/r/147/#review141
-----------------------------------------------------------


yes, some visualizations require updates all the time.

engines really shouldn't be updating data with the same values unless requested by a visualization, such as via a polling interval. in the latter case the visualizaton has specifically said "update me even N ms", so that's ok; and that's really the only time an engine should update itself with the same data.

well, with one exception: when the engine itself puts a polling interval in action; but then it's up to the engine to do the right thing, and such engine-wide polling intervals should only be done when the data set is one known to vary over time.

so this patch would break certain things (e.g. graph monitors, as you note) and the benefit would be truly nominal.

what was the use case that motivate this patch?

- Aaron


On 2008-08-26 09:27:18, Alex Merry wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://reviewboard.vidsolbach.de/r/147/
> -----------------------------------------------------------
> 
> (Updated 2008-08-26 09:27:18)
> 
> 
> Review request for Plasma.
> 
> 
> Summary
> -------
> 
> This prevents Plasma::DataContainer::setData() from setting the dirty flag if it did not actually change anything.
> 
> This ensures that dataUpdated() is not emitted if the data was not actually updated.
> 
> The question is: is this behaviour we want?  I can see that some applets (such as ones that draw graphs for system or network usage) might want to depend on getting dataUpdated() regularly, even if the data is exactly the same as before.
> 
> 
> Diffs
> -----
> 
>   trunk/KDE/kdebase/workspace/libs/plasma/datacontainer.cpp
> 
> Diff: http://reviewboard.vidsolbach.de/r/147/diff
> 
> 
> Testing
> -------
> 
> Compiles.  Applets still get updates.
> 
> 
> Thanks,
> 
> Alex
> 
>



More information about the Plasma-devel mailing list