Bug 110932 - changing folder name over the media protocol locks the folder
Summary: changing folder name over the media protocol locks the folder
Status: RESOLVED FIXED
Alias: None
Product: kio
Classification: Frameworks and Libraries
Component: media (show other bugs)
Version: unspecified
Platform: Mandriva RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: Kevin Ottens
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-08-16 23:48 UTC by tropikhajma
Modified: 2005-09-26 23:23 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description tropikhajma 2005-08-16 23:48:24 UTC
Version:            (using KDE KDE 3.4.2)
Installed from:    Mandriva RPMs
OS:                Linux

To reproduce:
start konqueror
enter media:/ into the location bar
navigate to location where you have enough permissions to rename folders - e.g. to your ~/
rename a folder
now the renamed folder turns to locked folder - it has a picture of a lock in the icon and when I try to enter it, it opens in new window (instead of the default)
It gets fixed when I refresh the view.
Comment 1 Kevin Ottens 2005-09-23 23:02:45 UTC
Can reproduce this one, even in the 3.5 branch.
Comment 2 Kevin Ottens 2005-09-26 23:21:26 UTC
SVN commit 464310 by ervin:

We have to plan a refresh of an item if it uses UDS_LOCAL_PATH.
Thanks to dfaure for the patch.

CCBUG:110932


 M  +9 -4      kdirlister.cpp  


--- branches/KDE/3.5/kdelibs/kio/kio/kdirlister.cpp #464309:464310
@@ -755,10 +755,15 @@
   KFileItem *fileitem = findByURL( 0, oldurl );
   if ( fileitem )
   {
-    aboutToRefreshItem( fileitem );
-    fileitem->setURL( dst );
-    fileitem->refreshMimeType();
-    emitRefreshItem( fileitem );
+    if ( !fileitem->isLocalFile() && !fileitem->localPath().isEmpty() ) // it uses UDS_LOCAL_PATH? ouch, needs an update then
+        FilesChanged( src );
+    else
+    {
+        aboutToRefreshItem( fileitem );
+        fileitem->setURL( dst );
+        fileitem->refreshMimeType();
+        emitRefreshItem( fileitem );
+    }
   }
 #ifdef DEBUG_CACHE
   printDebug();
Comment 3 Kevin Ottens 2005-09-26 23:23:42 UTC
SVN commit 464311 by ervin:

We have to plan a refresh of an item if it uses UDS_LOCAL_PATH.
Thanks to dfaure for the patch.
(forward port)

BUG:110932



 M  +9 -4      kdirlister.cpp  


--- trunk/KDE/kdelibs/kio/kio/kdirlister.cpp #464310:464311
@@ -761,10 +761,15 @@
   KFileItem *fileitem = findByURL( 0, oldurl );
   if ( fileitem )
   {
-    aboutToRefreshItem( fileitem );
-    fileitem->setURL( dst );
-    fileitem->refreshMimeType();
-    emitRefreshItem( fileitem );
+    if ( !fileitem->isLocalFile() && !fileitem->localPath().isEmpty() ) // it uses UDS_LOCAL_PATH? ouch, needs an update then
+        FilesChanged( src );
+    else
+    {
+        aboutToRefreshItem( fileitem );
+        fileitem->setURL( dst );
+        fileitem->refreshMimeType();
+        emitRefreshItem( fileitem );
+    }
   }
 #ifdef DEBUG_CACHE
   printDebug();