Permalink
Browse files

Add links to enum searches from ElunaTrinityWotlk repository

  • Loading branch information...
1 parent c42b8c0 commit 404fe51cb9f7858ab05d11a6c97869bd504a5254 @Rochet2 Rochet2 committed Apr 9, 2016
Showing with 6 additions and 0 deletions.
  1. +6 −0 docs/ElunaDoc/__main__.py
@@ -135,6 +135,12 @@ def data_type_parser(content):
url = '{}{}/index.html'.format(('../' * level), class_name)
return '<strong><a class="mod" href="{}">{}</a></strong>'.format(url, class_name)
+ # Case for enums to direct to a search on github
+ enum_name = content[1:-1]
+ url = 'https://github.com/ElunaLuaEngine/ElunaTrinityWotlk/search?l=cpp&q=%22enum+{}%22&type=Code&utf8=%E2%9C%93'.format(enum_name)
+ return '<strong><a href="{}">{}</a></strong>'.format(url, enum_name)
+
+ # By default we just return the name without the [] around it
return content[1:-1]
return link_parser, data_type_parser

0 comments on commit 404fe51

Please sign in to comment.