예제 #1
0
 def content(self):
     controllers = odict()
     map_controllers('', get_root_controller(), controllers)
     return unicode(render(
         dict(controllers=controllers),
         'genshi', 'tgext.debugbar.sections.templates.controllers'
         ).split('\n', 1)[-1])
예제 #2
0
 def content(self):
     controllers = odict()
     map_controllers('', get_root_controller(), controllers)
     return unicode_text(
         render(dict(controllers=controllers), tg.config['debugbar.engine'],
                'tgext.debugbar.sections.templates.controllers!html').split(
                    '\n', 1)[-1])
예제 #3
0
 def render_first(self, response):
     try:
         self.app_config.hooks['after_render'].remove(self.render_first)
     except ValueError:
         pass  # pre-empted by another request
     else:
         from tgext.debugbar.controller import DebugBarController
         get_root_controller()._debugbar = DebugBarController()
         self.app_config.register_hook('after_render', self.render_bars)
     self.render_bars(response)
예제 #4
0
 def content(self):
     controllers = odict()
     map_controllers("", get_root_controller(), controllers)
     return unicode_text(
         render(
             dict(controllers=controllers),
             tg.config["debugbar.engine"],
             "tgext.debugbar.sections.templates.controllers!html",
         ).split("\n", 1)[-1]
     )
예제 #5
0
 def render_first(self, response):
     try:
         self._disconnect_hook('after_render', self.render_first)
     except ValueError:
         pass  # pre-emptied by another request
     else:
         from tgext.debugbar.controller import DebugBarController
         get_root_controller()._debugbar = DebugBarController()
         self._register_hook('after_render', self.render_bars)
     self.render_bars(response)