Changeset 5956


Ignore:
Timestamp:
22 Apr 2011, 01:37:43 (13 years ago)
Author:
uli
Message:

Use plural to be more accurate.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.sirp/trunk/src/waeup/sirp/interfaces.py

    r5955 r5956  
    1414from waeup.sirp.permissions import RoleSource
    1515
    16 class IThemeProvider(Interface):
     16class IThemesProvider(Interface):
    1717    """A component that delivers all themes defined.
    1818
     
    3737        """
    3838
    39 class ThemeSource(BasicSourceFactory):
     39class ThemesSource(BasicSourceFactory):
    4040    """A source for themes.
    4141    """
     
    4343        """Get names of themes.
    4444        """
    45         theme_provider = getUtility(IThemeProvider, name="default")
    46         return [x for x, y in theme_provider()]
     45        themes_provider = getUtility(IThemesProvider, name="default")
     46        return [x for x, y in themes_provider()]
    4747   
    4848    def getTitle(self, value):
    4949        """Get a user-presentable description for a theme.
    5050        """
    51         theme_provider = getUtility(IThemeProvider, name="default")
    52         for name, theme in theme_provider():
     51        themes_provider = getUtility(IThemesProvider, name="default")
     52        for name, theme in themes_provider():
    5353            if name == value:
    5454                return theme.description
    5555        return u'unnamed'
    5656
    57 class ThemeSourceBinder(object):
     57class ThemesSourceBinder(object):
    5858    """A source binder for the `ThemeSource`.
    5959
     
    7777
    7878    def __call__(self, context):
    79         return ThemeSource()
     79        return ThemesSource()
    8080
    8181class FatalCSVError(Exception):
     
    111111        title = u'Skin',
    112112        default = u'waeuptheme-gray1.css',
    113         source = ThemeSourceBinder(),
     113        source = ThemesSourceBinder(),
    114114        required = True,
    115115        )
Note: See TracChangeset for help on using the changeset viewer.