Keep track of current page in the profile.
[automanga.git] / manga / profile.py
index 2a82df4..87f02a9 100644 (file)
@@ -49,6 +49,7 @@ def splitline(line):
                 elif c.isspace():
                     ret.append(buf)
                     buf = ""
+                    a = False
                     break
                 elif c == "\\" and p < len(line):
                     buf += bsq(line[p])
@@ -104,6 +105,12 @@ class manga(object):
             return default
         return self.props[key]
 
+    def __getitem__(self, key):
+        return self.props[key]
+
+    def __contains__(self, key):
+        return key in self.props
+
     def setprop(self, key, val):
         self.props[key] = val