Review Request: Fix sourceFilter to actually filter the sources in QML DataModel

Viranch Mehta viranch.mehta at gmail.com
Fri Jun 15 22:20:23 UTC 2012


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

Review request for Plasma and Marco Martin.


Description
-------

This fixes a bug in PlasmaCore.DataModel. The DataModel does not correctly filter the sources when sourceFilter is provided.

The dataUpdated function does terminate when sourceName does not match the sourceFilter, but when it does match, all sources from the data engine are added to the said DataModel instead of checking for the sourceFilter again. This patch introduces that check.

(the patch is clearer than the description)


Diffs
-----

  plasma/declarativeimports/core/datamodel.cpp 9400dbe 

Diff: http://git.reviewboard.kde.org/r/105267/diff/


Testing
-------

Tested with Battery Monitor applet when there are multiple batteries and a model is required consisting of only the battery sources from powermanagement engine.

Works as expected with the patch.


Thanks,

Viranch Mehta

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20120615/29d08672/attachment.html>


More information about the Plasma-devel mailing list