Ejemplo n.º 1
0
 def _getFromApps(self, method, *args, **kwargs):
     callables = [plugins.Callable(method, app, *args) for app in self.apps]
     aggregator = plugins.ResponseAggregator(callables)
     try:
         return aggregator(**kwargs)
     except plugins.AggregationError, e:
         app = self.apps[e.index]
         plugins.printWarning("GUI configuration '" + "::".join(args) +\
                              "' differs between applications, ignoring that from " + repr(app) + "\n" + \
                              "Value was " + repr(e.value2) + ", change from " + repr(e.value1), stdout=True)
         return e.value1
Ejemplo n.º 2
0
 def findAllClasses(self, className):
     if len(self.allApps) == 0:
         return [(className, [])]
     else:
         classNames = OrderedDict()
         for app in self.allApps:
             allConfigsForApp = self.getAllIntvConfigs([app])
             replacements = plugins.ResponseAggregator(
                 [x.getReplacements for x in allConfigsForApp])()
             for config in allConfigsForApp:
                 if className in config.getInteractiveActionClasses(
                         self.dynamic):
                     realClassName = replacements.get(className, className)
                     classNames.setdefault(realClassName, []).append(app)
         return classNames.items()
Ejemplo n.º 3
0
 def getColourDictionary(self):
     return plugins.ResponseAggregator([
         x.getColourDictionary for x in self.getAllIntvConfigs(self.allApps)
     ])()
Ejemplo n.º 4
0
 def getDefaultAccelerators(self):
     return plugins.ResponseAggregator([
         x.getDefaultAccelerators
         for x in self.getAllIntvConfigs(self.allApps)
     ])()