Details
-
Bug
-
Resolution: Duplicate
-
Not Evaluated
-
5.12.4
-
None
-
Reproducible on Win10 and Win8.1. Used to work with Qt 5.11.0
-
-
1c55a6caf1fc2b8a73a9a756bcf6894c5d4e4398
Description
When using the screen reader application YouDaoDict, a Qt application hangs as soon as the reader app tries to read text from a QTreeView item.
Sample code is this:
#include <QtWidgets/QApplication> #include <QtWidgets/QTreeView> #include <QtWidgets/QMainWindow> #include <QtGui/QStandardItemModel> int main (int argc, char** argv) { QApplication app(argc, argv); QMainWindow mainWindow; QTreeView* m_treeView = new QTreeView(&mainWindow); // Create model and assign it to treeView QStandardItemModel* m_model = new QStandardItemModel(&mainWindow); QStandardItem* rootItem = m_model->invisibleRootItem(); rootItem->appendRow(new QStandardItem("freeze")); m_treeView->setModel(m_model); mainWindow.setCentralWidget(m_treeView); mainWindow.show(); return app.exec(); }
Steps to reproduce:
- install YouDaoDict (see steps below)
- Run the sample app
- Hover the title and hold Ctrl -> a translation shows up after a moment
- Hover the "freeze" item and hold Ctrl -> no translation shows up, but one CPU core becomes completely busy, the application doesn't respond anymore, need to kill the app via TaskManager
The call stack during the freeze looks like this:
... > qwindows.dll!QWindowsUiaMainProvider::ElementProviderFromPoint(double x, double y, IRawElementProviderFragment * * pRetVal) Line 655 C++ UIAutomationCore.dll!ProviderCallouts::ElementProviderFromPoint(struct IRawElementProviderFragmentRoot *,double,double,struct IRawElementProviderFragment * *) Unknown UIAutomationCore.dll!AccessibleProxy::GetFocusOrHitTest() Unknown UIAutomationCore.dll!AccessibleProxy::accHitTest() Unknown oleacc.dll!AccWrap_LocationEtcFix::accHitTest(long,long,struct tagVARIANT *) Unknown oleacc.dll!AccessibleObjectFromPoint() Unknown ...
There is an endless loop originating from oleacc.dll!AccessibleObjectFromPoint() which keeps adding references to the QWindowsUiaMainProvider and apparently never finds what it is looking for. The application freezes and doesn't wake up again.
This is a regression since it used to work with Qt 5.11.0. With that version, the application didn't hang (though YouDaoDict didn't display any tooltip).
Steps to install YouDaoDict:
- Go to http://cidian.youdao.com/ and download the software.
- Run installer, start the application after installation.
- Make sure the two checkboxes on the left side are checked. (Should be the default state)
- Click the drop down menu on the top and enter configuration dialog.
- Ensure the 'pick-translation' uses "Ctrl+Mouse" shortcut.
Attachments
Issue Links
- duplicates
-
QTBUG-77974 QtCreator内存泄漏
- Closed