Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
None
-
4.7.4, 4.8.0, 5.0.0
-
None
Description
When mixing QML and C++, it's possible to clear focus in QGraphicsScene by calling QGraphicsScene::setFocusItem(0). When doing so, QDeclarativeItem::hasActiveFocus() will return true if the declarative item or one of its descendents has (ever) had focus. This is because the function checks if the item has a focusItem(), but not if it actually has focus. QGraphicsItem::hasFocus() works and returns the correct value.
See also https://bugreports.qt.nokia.com/browse/QTCOMPONENTS-1183
Attachments
Issue Links
- resulted in
-
QTBUG-29891 Problem with FocusScope and activeFocus since Qt 4.8.2
-
- Closed
-