Simplify transaction expiry mechanism
authorGatis Paeglis <gatis.paeglis@digia.com>
Mon, 1 Oct 2012 12:04:09 +0000 (14:04 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Sat, 13 Oct 2012 03:51:19 +0000 (05:51 +0200)
commitd70cb669324be5ec94fdf7d5620e28b55295c295
tree1569fade23e580b7b1977efb8c62195ebe9870b6
parentce81da52ea1fffa67188e19eb9dbba66501dd82f
Simplify transaction expiry mechanism

This patch makes transaction mechanism less scattered around and
conforms to the xdnd specification:

Don't block and keep a history of previous data. This can be very difficult to implement,
but it is clearly the ideal behavior from the user's perspective because it allows him to
drop something and then continue working with the assurance that the target will get the
data regardless of how slow the network connections are.

When the source receives XdndFinished, it can remove the item from its history, thereby keeping
it from getting too large. The source must also be prepared to throw out extremely old data
in case a target malfunctions.

I assume that 10min for drag-and-drop operation can be considered 'extremely' old data.

Change-Id: I73dcd21aee3ad188d2260e49d80824da6ba040ab
Task-numer: QTBUG-14493
Reviewed-by: David Faure (fixes for KDE) <faure@kde.org>
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
src/plugins/platforms/xcb/qxcbdrag.cpp
src/plugins/platforms/xcb/qxcbdrag.h