#NEWLINE# def load_template_source( self , template_name , template_dirs = None ) : #NEWLINE# #INDENT# '\n        Loads templates from Python eggs via pkg_resource.resource_string.\n\n        For every installed app, it tries to get the resource (app, template_name).\n        ' #NEWLINE# if ( resource_string is not None ) : #NEWLINE# #INDENT# pkg_name = ( 'templates/' + template_name ) #NEWLINE# for app in settings . INSTALLED_APPS : #NEWLINE# #INDENT# try : #NEWLINE# #INDENT# return ( resource_string ( app , pkg_name ) . decode ( settings . FILE_CHARSET ) , ( 'egg:%s:%s' % ( app , pkg_name ) ) ) #NEWLINE# #UNINDENT# except : #NEWLINE# #INDENT# pass #NEWLINE# #UNINDENT# #UNINDENT# #UNINDENT# raise TemplateDoesNotExist ( template_name )