Bug 171959 - Renaming files/directories in folder view throws an error message
Summary: Renaming files/directories in folder view throws an error message
Status: RESOLVED FIXED
Alias: None
Product: plasma4
Classification: Plasma
Component: widget-folderview (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-01 13:39 UTC by FiNeX
Modified: 2008-12-08 17:45 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
remove KFileItemDelegate::EventFilter from editor before (possibly) grabbing focus. (436 bytes, patch)
2008-10-03 11:48 UTC, Sander Ernes
Details
modified patch for current trunk. (431 bytes, patch)
2008-11-04 09:39 UTC, FiNeX
Details

Note You need to log in before you can comment on or make changes to this bug.
Description FiNeX 2008-10-01 13:39:35 UTC
Version:           r866511 (using Devel)
OS:                Linux
Installed from:    Compiled sources

Steps to reproduce:
1) add a folder view plasmoid
2) Try to rename a file or a directory
  - select the file
  - press F2
  - rename it

This will opens an error message:
  "The file or folder /home/test/Documents/Misc does not exist."

The path printed on the error message is the one of the old file name.
Comment 1 Sander Ernes 2008-10-03 11:48:20 UTC
Created attachment 27668 [details]
remove KFileItemDelegate::EventFilter from editor before (possibly) grabbing focus.
Comment 2 Sander Ernes 2008-10-03 11:50:50 UTC
KFileItemDelegate::eventFilter emits commitData() and closeEditor() both on losing focus and pressing "Enter".
Because focus remains on editor after "Enter" is pressed and in that case FolderView::closeEditor grabs it, FolderView is commiting (renaming) twice.
Comment 3 JP Rosevear 2008-10-31 17:18:04 UTC
See also https://bugzilla.novell.com/show_bug.cgi?id=432728
Comment 4 FiNeX 2008-11-04 09:38:34 UTC
Using the patch suggested by Sander, renaming files doesn't throw the error message. The patch is ok to me.

I've updated it because the code of folderview has a bit changed.
Comment 5 FiNeX 2008-11-04 09:39:20 UTC
Created attachment 28314 [details]
modified patch for current trunk.
Comment 6 Aaron J. Seigo 2008-12-08 17:45:38 UTC
SVN commit 894444 by aseigo:

patch by Sander Ernes to fix an errant warning dialog
BUG:171959


 M  +1 -1      iconview.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=894444