- 
    Bug 
- 
    Resolution: Fixed
- 
    P4: Low 
- 
    None
- 
    4.8.2, 5.0.0
- 
    None
- 
    Windows 7 32bit, Qt 4.8.2, mingw
Steps to reproduce:
1) create a form with QTreeWidget and a push button
2) connect a push button's signal "clicked()" to a slot
3) in a slot create a new QTreeWidgetItem, add it to the view and start editing.
4) Compile and run
5) Start clicking on a push button quickly
Result:
Sometimes I see "edit: editing failed" in stderr, and the new item doesn't open the editor. Code:
void Test::slotAdd()
{
    QTreeWidgetItem *i = new QTreeWidgetItem(ui->tree, QStringList() << "Name" << "Data");
    i->setFlags(i->flags() | Qt::ItemIsEditable);
    ui->tree->addTopLevelItem(i);
    ui->tree->setCurrentItem(i, QItemSelectionModel::ClearAndSelect);
    ui->tree->editItem(i);
}
Test project is attached.