- def __setLastRes(self, res):
- # res == None means this display was last switched off
- if res is not None and not res in self._resolutions:
- raise ValueError("Resolution "+res+" not available for "+self.name+".")
- self.__lastResolution = res
- self.hasLastResolution = True
-
- def __getLastRes(self):
- if not self.hasLastResolution:
- raise ValueError("Connector %s has no last known resolution." % self.name)
- return self.__lastResolution
-
- lastResolution = property(__getLastRes, __setLastRes)
-