switch over to per-day sibling burying

This commit is contained in:
Damien Elmes 2014-01-14 14:18:42 +09:00
parent 8769a6daf0
commit 44b83d9bd8

View File

@ -73,9 +73,8 @@ class _Collection(object):
self.crt = int(time.mktime(d.timetuple())) self.crt = int(time.mktime(d.timetuple()))
self.sched = Scheduler(self) self.sched = Scheduler(self)
if not self.conf.get("newBury", False): if not self.conf.get("newBury", False):
mod = self.db.mod self.conf['newBury'] = True
self.sched.unburyCards() self.setMod()
self.db.mod = mod
def name(self): def name(self):
n = os.path.splitext(os.path.basename(self.path))[0] n = os.path.splitext(os.path.basename(self.path))[0]
@ -148,10 +147,6 @@ crt=?, mod=?, scm=?, dty=?, usn=?, ls=?, conf=?""",
def close(self, save=True): def close(self, save=True):
"Disconnect from DB." "Disconnect from DB."
if self.db: if self.db:
if not self.conf.get("newBury", False):
mod = self.db.mod
self.sched.unburyCards()
self.db.mod = mod
if save: if save:
self.save() self.save()
else: else: