Review Request: Correctly trigger executed signal of KListWidget for both single click and double click.
Yichao Yu
yyc1992 at gmail.com
Fri Dec 21 08:31:46 GMT 2012
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/107829/
-----------------------------------------------------------
Review request for kdelibs.
Description
-------
When clicking on a item in a KListWidget, the `executed` signals is not correctly emitted.
If the system-wide setting is to use single click, only `executed( QListWidgetItem *item )` is emitted (once).
If the setting is to use double click, `executed( QListWidgetItem *item )` will be emitted twice and `executed( QListWidgetItem *item, const QPoint &pos )` is emitted once, which cause the edit note dialog in Kontact_KNotePlugin to popup a second time right after close in some cases.
This patch fixes the problem. It is a little hacky but there isn't another easy way to get the position of the single click event except overriding the mouseReleaseEvent function.
Diffs
-----
kdeui/itemviews/klistwidget.h 9309efc
kdeui/itemviews/klistwidget.cpp 13497bf
Diff: http://git.reviewboard.kde.org/r/107829/diff/
Testing
-------
Compiled kdelibs as well as program that has problem (kontact) and the signal is triggered correctly.
Thanks,
Yichao Yu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20121221/6bffdb69/attachment.htm>
More information about the kde-core-devel
mailing list