[Pkg-owncloud-commits] [owncloud-client] 48/115: Nautilus Overlays: Fix: do not change an dictionary which is iterated.
Sandro Knauß
hefee-guest at moszumanska.debian.org
Fri Aug 29 22:03:59 UTC 2014
This is an automated email from the git hooks/post-receive script.
hefee-guest pushed a commit to branch master
in repository owncloud-client.
commit 4aec783362ec42a20cfe7952d09f736488e67957
Author: Klaas Freitag <freitag at owncloud.com>
Date: Fri Aug 15 17:03:15 2014 +0200
Nautilus Overlays: Fix: do not change an dictionary which is iterated.
Also, item.invalidate_extension_info() is sufficient, no need to call
update_file_info afterwards.
---
shell_integration/nautilus/ownCloud.py | 12 +++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/shell_integration/nautilus/ownCloud.py b/shell_integration/nautilus/ownCloud.py
index 801c6c2..ac04a17 100755
--- a/shell_integration/nautilus/ownCloud.py
+++ b/shell_integration/nautilus/ownCloud.py
@@ -90,13 +90,19 @@ class ownCloudExtension(GObject.GObject, Nautilus.ColumnProvider, Nautilus.InfoP
item = self.find_item_for_file(parts[2])
if item:
item.add_emblem(emblem)
+
elif action == 'UPDATE_VIEW':
+ # Search all items underneath this path and invalidate them
if parts[1] in self.registered_paths:
+ update_items = []
for p in self.nautilusVFSFile_table:
- if p.startswith( parts[1] ):
+ if p == parts[1] or p.startswith( parts[1] ):
item = self.nautilusVFSFile_table[p]
- item.invalidate_extension_info()
- self.update_file_info(item)
+ update_items.append(item)
+
+ for item in update_items:
+ item.invalidate_extension_info()
+ # self.update_file_info(item)
elif action == 'REGISTER_PATH':
self.registered_paths[parts[1]] = 1
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud-client.git
More information about the Pkg-owncloud-commits
mailing list