add missing model parameters

This commit is contained in:
Martin Baeuml
2011-05-24 23:23:01 +02:00
parent 1444185c1e
commit 175a61db8f
+3 -3
View File
@@ -75,12 +75,12 @@ class ImageFileModelItem(FileModelItem):
FileModelItem.__init__(self, model, file, parent)
for ann in file['annotations']:
ami = AnnotationModelItem(ann, self)
ami = AnnotationModelItem(model, ann, self)
self.children_.append(ami)
def addAnnotation(self, ann):
self.file_['annotations'].append(ann)
ami = AnnotationModelItem(ann, self)
ami = AnnotationModelItem(model, ann, self)
self.children_.append(ami)
def removeAnnotation(self, pos):
@@ -161,7 +161,7 @@ class AnnotationModelItem(ModelItem):
for key, value in annotation.iteritems():
if key == None:
continue
self.children_.append(KeyValueModelItem(key, self))
self.children_.append(KeyValueModelItem(model, key, self))
def type(self):
return self.annotation_['type']