Fix threaded request synchronization issues

Like it was predicted, 26b2eab752073dc1d8b5769b7cfe307b9982e5b3
encovered the undefined behavior with the request notification
synchronization in case when the request gets updated from within
another thread - i.e. resultAvailable() or stateChanged() notification
could be delivered after the request has been destroyed.

Change-Id: I3411391511ae61d6aa8feb00b1cb0d1f7c431a25
Reviewed-by: Michael Krasnyk <michael.krasnyk@gmail.com>
Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
Make QtDeclarative an optional dependency

Change-Id: I07431e5e51adb0cf86565afbbebc84704295a434
Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
Don't use deprecated qtAddLibrary()

This fixes a warning generated by qmake for every test.

Change-Id: Ifb1393bd58453051b2552b0c68397b591cbc4ccd
Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
Treat detail filter with unset field like a "detail exists" filter

QtContacts filters already meant that; do the same for QtOrganizer filters.

Change-Id: I1af2d10f1456fb0763a5e078f9ab901eed0873a9
Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
[QOrganizerItemMemoryEngine] Optimize work with collections

Use QHash instead of QList, thus reducing access time.

Change-Id: I87f7f0561d0fb1bc67fa78f5cc3e703f17addba1
Reviewed-by: Michael Krasnyk <michael.krasnyk@gmail.com>
Reviewed-by: Alex Blasche <alexander.blasche@digia.com>