|
|
## -*- coding: utf-8 -*-
|
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
|
<html xmlns="http://www.w3.org/1999/xhtml" id="mainhtml">
|
|
|
<head>
|
|
|
<link rel="icon" href="/images/hgicon.png" type="image/png" />
|
|
|
<meta name="robots" content="index, nofollow"/>
|
|
|
<title>${next.title()}</title>
|
|
|
##<link rel="stylesheet" href="/js/yui/reset-fonts-grids/reset-fonts-grids.css" type="text/css" />
|
|
|
${self.css()}
|
|
|
${self.js()}
|
|
|
</head>
|
|
|
|
|
|
<body class="mainbody">
|
|
|
<div id="container">
|
|
|
<div class="page-header">
|
|
|
<h1>${next.breadcrumbs()}</h1>
|
|
|
${self.page_nav()}
|
|
|
</div>
|
|
|
<div id="main">
|
|
|
${next.main()}
|
|
|
</div>
|
|
|
<div class="page-footer">
|
|
|
Hg App ${c.hg_app_version} © 2010
|
|
|
</div>
|
|
|
|
|
|
<div id="powered-by">
|
|
|
<p>
|
|
|
<a href="http://mercurial.selenic.com/" title="Mercurial">
|
|
|
<img src="/images/hglogo.png" width="75" height="90" alt="mercurial"/></a>
|
|
|
</p>
|
|
|
</div>
|
|
|
|
|
|
<div id="corner-top-left"></div>
|
|
|
<div id="corner-top-right"></div>
|
|
|
<div id="corner-bottom-left"></div>
|
|
|
<div id="corner-bottom-right"></div>
|
|
|
|
|
|
</div>
|
|
|
</body>
|
|
|
</html>
|
|
|
|
|
|
### MAKO DEFS ###
|
|
|
|
|
|
<%def name="page_nav()">
|
|
|
${self.menu()}
|
|
|
</%def>
|
|
|
|
|
|
<%def name="menu(current)">
|
|
|
<%
|
|
|
def is_current(selected):
|
|
|
if selected == current:
|
|
|
return 'class=current'
|
|
|
%>
|
|
|
%if current not in ['home','admin']:
|
|
|
<script type="text/javascript">
|
|
|
YAHOO.util.Event.onDOMReady(function(){
|
|
|
YAHOO.util.Event.addListener('repo_switcher','click',function(){
|
|
|
if(YAHOO.util.Dom.hasClass('repo_switcher','selected')){
|
|
|
YAHOO.util.Dom.setStyle('switch_repos','display','none');
|
|
|
YAHOO.util.Dom.setStyle('repo_switcher','background','');
|
|
|
YAHOO.util.Dom.removeClass('repo_switcher','selected');
|
|
|
}
|
|
|
else{
|
|
|
YAHOO.util.Dom.setStyle('switch_repos','display','');
|
|
|
YAHOO.util.Dom.setStyle('repo_switcher','background','#FFFFFF');
|
|
|
YAHOO.util.Dom.addClass('repo_switcher','selected');
|
|
|
}
|
|
|
});
|
|
|
YAHOO.util.Event.addListener('repos_list','change',function(e){
|
|
|
var wa = YAHOO.util.Dom.get('repos_list').value;
|
|
|
|
|
|
var url = "${h.url('summary_home',repo_name='__REPLACE__')}".replace('__REPLACE__',wa);
|
|
|
window.location = url;
|
|
|
})
|
|
|
});
|
|
|
</script>
|
|
|
<ul class="page-nav">
|
|
|
<li>
|
|
|
<a id="repo_switcher" title="${_('Switch repository')}" href="#">↓</a>
|
|
|
<div id="switch_repos" style="display:none;position: absolute;width: 150px;height: 25px">
|
|
|
<select id="repos_list" size="=10">
|
|
|
%for repo in c.cached_repo_list:
|
|
|
<option value="${repo['name']}">${repo['name']}</option>
|
|
|
%endfor
|
|
|
</select>
|
|
|
</div>
|
|
|
</li>
|
|
|
<li ${is_current('summary')}>${h.link_to(_('summary'),h.url('summary_home',repo_name=c.repo_name))}</li>
|
|
|
<li ${is_current('shortlog')}>${h.link_to(_('shortlog'),h.url('shortlog_home',repo_name=c.repo_name))}</li>
|
|
|
<li ${is_current('changelog')}>${h.link_to(_('changelog'),h.url('changelog_home',repo_name=c.repo_name))}</li>
|
|
|
<li ${is_current('branches')}>${h.link_to(_('branches'),h.url('branches_home',repo_name=c.repo_name))}</li>
|
|
|
<li ${is_current('tags')}>${h.link_to(_('tags'),h.url('tags_home',repo_name=c.repo_name))}</li>
|
|
|
<li ${is_current('files')}>${h.link_to(_('files'),h.url('files_home',repo_name=c.repo_name))}</li>
|
|
|
</ul>
|
|
|
%else:
|
|
|
<ul class="page-nav">
|
|
|
<li ${is_current('home')}>${h.link_to(_('Home'),h.url('/'))}</li>
|
|
|
<li ${is_current('admin')}>${h.link_to(_('Admin'),h.url('admin_home'))}</li>
|
|
|
<li class="logout">${h.link_to(u'Logout',h.url('logout_home'))}</li>
|
|
|
</ul>
|
|
|
%endif
|
|
|
</%def>
|
|
|
|
|
|
<%def name="css()">
|
|
|
<link rel="stylesheet" href="/css/monoblue_custom.css" type="text/css" />
|
|
|
</%def>
|
|
|
|
|
|
<%def name="js()">
|
|
|
<script type="text/javascript" src="/js/yui/utilities/utilities.js"></script>
|
|
|
</%def>
|
|
|
|
|
|
<!-- DEFINITION OF FORM ERROR FETCHER -->
|
|
|
<%def name="get_form_error(element)">
|
|
|
%if hasattr(c,'form_errors') and type(c.form_errors) == dict:
|
|
|
%if c.form_errors.get(element,False):
|
|
|
<span class="error-message">
|
|
|
${c.form_errors.get(element,'')}
|
|
|
</span>
|
|
|
%endif
|
|
|
%endif
|
|
|
</%def>
|