1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133
|
# -*- encoding:utf-8 -*-
from mako import runtime, filters, cache
UNDEFINED = runtime.UNDEFINED
__M_dict_builtin = dict
__M_locals_builtin = locals
_magic_number = 6
_modified_time = 1357242050.211483
_template_filename=u'templates/root.mako'
_template_uri=u'root.mako'
_template_cache=cache.Cache(__name__, _modified_time)
_source_encoding='utf-8'
_exports = ['css_link', 'pre', 'post', 'css']
def render_body(context,**pageargs):
context.caller_stack._push_frame()
try:
__M_locals = __M_dict_builtin(pageargs=pageargs)
def pre():
return render_pre(context.locals_(__M_locals))
self = context.get('self', UNDEFINED)
set = context.get('set', UNDEFINED)
def post():
return render_post(context.locals_(__M_locals))
next = context.get('next', UNDEFINED)
__M_writer = context.writer()
# SOURCE LINE 1
self.seen_css = set()
__M_writer(u'\n')
# SOURCE LINE 7
__M_writer(u'\n')
# SOURCE LINE 10
__M_writer(u'\n')
# SOURCE LINE 15
__M_writer(u'\n')
# SOURCE LINE 22
__M_writer(u'\n')
# SOURCE LINE 25
__M_writer(u'<html>\n<head><title>IDP test login</title>\n ')
# SOURCE LINE 27
__M_writer(unicode(self.css()))
__M_writer(u'\n <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />\n</head>\n<body>\n ')
# SOURCE LINE 31
__M_writer(unicode(pre()))
__M_writer(u'\n')
# SOURCE LINE 34
__M_writer(unicode(next.body()))
__M_writer(u'\n')
# SOURCE LINE 35
__M_writer(unicode(post()))
__M_writer(u'\n</body>\n</html>\n')
return ''
finally:
context.caller_stack._pop_frame()
def render_css_link(context,path,media=''):
context.caller_stack._push_frame()
try:
context._push_buffer()
self = context.get('self', UNDEFINED)
__M_writer = context.writer()
# SOURCE LINE 2
__M_writer(u'\n')
# SOURCE LINE 3
if path not in self.seen_css:
# SOURCE LINE 4
__M_writer(u' <link rel="stylesheet" type="text/css" href="')
__M_writer(filters.html_escape(unicode(path)))
__M_writer(u'" media="')
__M_writer(unicode(media))
__M_writer(u'">\n')
pass
# SOURCE LINE 6
__M_writer(u' ')
self.seen_css.add(path)
__M_writer(u'\n')
finally:
__M_buf, __M_writer = context._pop_buffer_and_writer()
context.caller_stack._pop_frame()
__M_writer(filters.trim(__M_buf.getvalue()))
return ''
def render_pre(context):
context.caller_stack._push_frame()
try:
context._push_buffer()
__M_writer = context.writer()
# SOURCE LINE 11
__M_writer(u'\n <div class="header">\n <h1><a href="/">Login</a></h1>\n </div>\n')
finally:
__M_buf, __M_writer = context._pop_buffer_and_writer()
context.caller_stack._pop_frame()
__M_writer(filters.trim(__M_buf.getvalue()))
return ''
def render_post(context):
context.caller_stack._push_frame()
try:
context._push_buffer()
__M_writer = context.writer()
# SOURCE LINE 16
__M_writer(u'\n <div>\n <div class="footer">\n <p>© Copyright 2011 Umeå Universitet </p>\n </div>\n </div>\n')
finally:
__M_buf, __M_writer = context._pop_buffer_and_writer()
context.caller_stack._pop_frame()
__M_writer(filters.trim(__M_buf.getvalue()))
return ''
def render_css(context):
context.caller_stack._push_frame()
try:
context._push_buffer()
def css_link(path,media=''):
return render_css_link(context,path,media)
__M_writer = context.writer()
# SOURCE LINE 8
__M_writer(u'\n ')
# SOURCE LINE 9
__M_writer(unicode(css_link('/css/main.css', 'screen')))
__M_writer(u'\n')
finally:
__M_buf, __M_writer = context._pop_buffer_and_writer()
context.caller_stack._pop_frame()
__M_writer(filters.trim(__M_buf.getvalue()))
return ''
|