feat: preparing a migration to the new reader activation mechanism. Right now module will be active when the first successful read will be achieved. From now the initial value for the module will be taken from the persistent storage (leveldb) that keeps the last read value.

This commit is contained in:
Serhiy Mytrovtsiy
2024-02-08 17:35:01 +01:00
parent 7869a6866c
commit 1e9073424b
4 changed files with 30 additions and 60 deletions

View File

@@ -168,7 +168,9 @@ private class Popup: NSStackView, Popup_p {
}
let h = CGFloat(availableModules.count) * Constants.Popup.portalHeight + (CGFloat(availableModules.count-1)*Constants.Popup.spacing)
self.setFrameSize(NSSize(width: self.frame.width, height: h))
self.sizeCallback?(self.frame.size)
if h > 0 {
self.setFrameSize(NSSize(width: self.frame.width, height: h))
self.sizeCallback?(self.frame.size)
}
}
}