Fix keyboard focus handling when finishing inline renaming with Enter
Review Request #107606 - Created Dec. 6, 2012 and submitted
My commit 951cb9c35d7a9ef814b3de5b359915968da9b881 (which was to fix bug 308018 and bug 309421) caused crashes when finishing inline renaming with 'Enter'. This was fixed by 3143acc084d54d43df469b54762bfa10a7050a9f, but a little problem remains: the keyboard focus is not transferred back to the view after finishing inline renaming. My new approach is to revert the two earlier commits, and to delay the deletion of the KItemListRoleEditor until the next item is renamed inline.
Keyboard focus handling works fine. I cannot reproduce bug 308018 and bug 309421. The only problem is that dragging text and dropping it on a Places Panel entry sometimes does not finish the drag and leads to a crash when closing Dolphin, but it seems that this problem exists also in the current state of the 4.9 branch, so it's no reason not to commit this fix (it would be better to fix that, of course, but I have no clue why it happens, and the use case is so uncommon that I'd prefer not to delay the fix for bug 311206. Maybe I'll tell the packagers about it, so they can apply it to their 4.9.4 packages before the bug causes more trouble. KDE 4.9.4 might be used for quite some time considering that it's not clear yet if there will be a 4.9.5). I could not see any other regressions caused by my proposed patch, but it has turned out that inline renaming is a very fragile thing, and we had a couple of regressions related to it already, so I would like to make sure that we get it right this time. Everyone is invited to test it and report any problems (or better ideas how to fix it) here. Emmanuel: you found an inline renaming regression already and know some of the problems that one can run into here - do you see a problem with my new approach?