Moved themes into subdirs

This commit is contained in:
str4d
2013-01-21 10:54:24 +00:00
parent 0f98f155be
commit c74b8a5947
8 changed files with 2 additions and 4 deletions

View File

@ -113,7 +113,7 @@ def detect_theme():
if theme[:7] == 'http://':
g.exttheme = theme
theme = 'duck'
if not os.path.isfile(safe_join(safe_join(STATIC_DIR, 'styles'), '%s.css' % theme)):
if not os.path.isfile(safe_join(safe_join(STATIC_DIR, 'styles'), '%s/style.css' % theme)):
theme = 'duck'
g.theme = theme
@after_this_request

View File

@ -5,8 +5,6 @@
<li><a href="{{ change_theme('danimoth') }}">{{ _('Danimoth') }}</a></li>
<li><a href="{{ change_theme('light') }}">{{ _('Light') }}</a></li>
<li><a href="{{ change_theme('dark') }}">{{ _('Dark') }}</a></li>
<li><a href="{{ change_theme('default') }}">{{ _('Barebones styling') }}</a></li>
<li><a href="{{ change_theme('mainmenu') }}">{{ _('Dropdown menu only') }}</a></li>
</ul>
</div>
<div class='aside second'>

View File

@ -9,7 +9,7 @@
{%- endif %}
<link rel="canonical" href="{{ canonical() }}" />
{% if g.exttheme %}<link rel="stylesheet" type="text/css" href="{{ g.exttheme }}" title="External theme" />{% else -%}
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='styles/' + g.theme + '.css') }}" title="{{ g.theme }}" />
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='styles/' + g.theme + '/style.css') }}" title="{{ g.theme }}" />
{%- endif %}
<link rel="shortcut icon" type="image/x-icon" href="{{ url_for('static', filename='favicon.ico') }}" />
<meta name="robots" content="NOODP" />