1
0
mirror of https://github.com/gryf/pygtktalog.git synced 2025-12-17 19:40:21 +01:00

* Changed version to 1.0 RC2.

* Bugfix in files removal. Controller should collect all file ids,
   otherwise it'll starts to remove wrong files, because in the meantime
   model removing items from liststore.
This commit is contained in:
2008-05-14 08:40:33 +00:00
parent 6709576aec
commit ea667cf03e
3 changed files with 23 additions and 20 deletions

View File

@@ -307,17 +307,13 @@ class SearchController(Controller):
d[1].append(zpath)
return False
ids = []
for p in list_of_paths:
val = model.get_value(model.get_iter(p), 0)
if model.get_value(model.get_iter(p), 4) == self.model.DIR:
# remove from disctree model aswell
dpath = []
dmodel.foreach(foreach_searchtree, (val, dpath))
for dp in dpath:
dmodel.remove(dmodel.get_iter(dp))
ids.append(model.get_value(model.get_iter(p), 0))
for fid in ids:
# delete from db
self.model.delete(val)
self.model.delete(fid)
self.model.unsaved_project = True
found = self.model.search(self.search_string)