diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2014-01-11 11:22:46 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2014-01-11 11:22:46 +0000 |
commit | 8b999962dec50fc4599f77c1a23fbdc7b43dab21 (patch) | |
tree | bb9f2f7ea5bffa7f50779af1e129f4ed787f3944 /lib/redmine/themes.rb | |
parent | 2db3338ab22ffbccb69b51c97baeba51646ac1e3 (diff) | |
download | redmine-8b999962dec50fc4599f77c1a23fbdc7b43dab21.tar.gz redmine-8b999962dec50fc4599f77c1a23fbdc7b43dab21.zip |
Make favicon themeable (#15689).
Patch by Felix Schäfer modified by Jean-Philippe Lang.
git-svn-id: http://svn.redmine.org/redmine/trunk@12646 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib/redmine/themes.rb')
-rw-r--r-- | lib/redmine/themes.rb | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/redmine/themes.rb b/lib/redmine/themes.rb index eb2ba9151..c69244f7e 100644 --- a/lib/redmine/themes.rb +++ b/lib/redmine/themes.rb @@ -75,6 +75,18 @@ module Redmine @javascripts ||= assets("javascripts", "js") end + def favicons + @favicons ||= assets("favicon") + end + + def favicon + favicons.first + end + + def favicon? + favicon.present? + end + def stylesheet_path(source) "/themes/#{dir}/stylesheets/#{source}" end @@ -87,6 +99,10 @@ module Redmine "/themes/#{dir}/javascripts/#{source}" end + def favicon_path + "/themes/#{dir}/favicon/#{favicon}" + end + private def assets(dir, ext=nil) |