Add a workaround for Qt 5.9...5.11.X to fix tablet support
Basically, the patch mimics this Qt's patch that has been added in Qt 5.12.0 only: https://codereview.qt-project.org/#/c/239918/
BUG:399696