# HG changeset patch # User Sylvain Thénault # Date 1249309950 -7200 # Node ID 87aed8cb7ff6c4387a5bc8898815b851ad009b18 # Parent f8df42c9da6b54d38b8ea854f04505c26a5c89f7 [uicfg reloading] don't reload uicfg when appobjects modules won't be reloaded as well diff -r f8df42c9da6b -r 87aed8cb7ff6 vregistry.py --- a/vregistry.py Mon Aug 03 16:31:30 2009 +0200 +++ b/vregistry.py Mon Aug 03 16:32:30 2009 +0200 @@ -213,11 +213,15 @@ super(VRegistry, self).__init__() self.config = config - def reset(self): + def reset(self, force_reload=None): self.clear() self._lastmodifs = {} + # don't reload uicfg when appobjects modules won't be reloaded as well if uicfg is not None: - reload(uicfg) + if force_reload is None: + force_reload = self.config.mode == 'dev' + if force_reload: + reload(uicfg) def __getitem__(self, name): """return the registry (dictionary of class objects) associated to