def cms_settings(request):
 from menus.menu_pool import MenuRenderer
 @lru_cache.lru_cache(maxsize=None)
 def _get_menu_renderer():
  from menus.menu_pool import menu_pool
  return menu_pool.get_renderer(request)
 toolbar = get_toolbar_from_request(request)
 _get_menu_renderer = lazy(_get_menu_renderer, MenuRenderer)
 return {'cms_menu_renderer': _get_menu_renderer(), 'cms_content_renderer': toolbar.content_renderer, 'CMS_MEDIA_URL': get_cms_setting('MEDIA_URL'), 'CMS_TEMPLATE': (lambda : get_template_from_request(request))}

def cms_settings ( request ) : from menus . menu_pool import MenuRenderer @ lru_cache . lru_cache ( maxsize = None ) def _get_menu_renderer ( ) : from menus . menu_pool import menu_pool return menu_pool . get_renderer ( request ) toolbar = get_toolbar_from_request ( request ) _get_menu_renderer = lazy ( _get_menu_renderer , MenuRenderer ) return { 'cms_menu_renderer' : _get_menu_renderer ( ) , 'cms_content_renderer' : toolbar . content_renderer , 'CMS_MEDIA_URL' : get_cms_setting ( 'MEDIA_URL' ) , 'CMS_TEMPLATE' : ( lambda : get_template_from_request ( request ) ) }
adds cms-related variables to the context .