hi
In treeWidget ,what is the currenItem ? is it a clicked treewidgetitem? [
hi
In treeWidget ,what is the currenItem ? is it a clicked treewidgetitem? [
I think its item that have input focus(so last selected item)
a life without programming is like an empty bottle
The current item is the one that has keyboard focus. When your Tree widget, list widget, etc has a 'single' selection model, the current item is always the selected item. Here's the catch however - the current item is only valid for as long as the widget has focus. If you tab, click or otherwise move focus to another widget, the current item is now invalid and should not be used. The selection however, remains valid.Originally Posted by Alina
I tend to avoid using the current item in 90% of cases and stick with the 'selected' item(s).
Save yourself some pain. Learn C++ before learning Qt.
Bookmarks