Android quickfix: Avoid crash at shutdown
authorPaul Olav Tvete <paul.tvete@digia.com>
Wed, 27 Aug 2014 08:56:53 +0000 (10:56 +0200)
committerPaul Olav Tvete <paul.tvete@digia.com>
Wed, 27 Aug 2014 10:22:07 +0000 (12:22 +0200)
commit4c6ebe5f9e4ddc0d799a0f2bf4aef9f7e48e0dfb
treed868c95f10e2fd8049d2bf3a2ed9071604bd187d
parentf2e4ff4fd484d49e7338c9a2c5882782fe8f081b
Android quickfix: Avoid crash at shutdown

Qt Quick does a processEvents() at shutdown. On some versions of
Android, this can trigger a getTextAfterCursor() after
QGuiApplication shutdown. This patch still has a theoretical
race condition, but should reduce the crash probablity to
practically zero.

[ChangeLog][Android] Fixed bug on some devices where the application
would crash at shutdown if the virtual keyboard was open.

Task-number: QTBUG-40957
Change-Id: Iefcc10a77e3d506c32ea151c27a3e87a7be40e68
Reviewed-by: BogDan Vatra <bogdan@kde.org>
src/plugins/platforms/android/qandroidinputcontext.cpp