Commit c37f22b2 authored by Victor Costan's avatar Victor Costan Committed by Commit Bot

tools/md_browser: Add .svg preview support.

gitiles supports svg, according to
https://github.com/google/gitiles/blob/master/gitiles-servlet/src/main/resources/com/google/gitiles/mime-types.properties

Bug: 
Change-Id: I87e54da98d434b0a932349b682f35e53a6d640a8
Reviewed-on: https://chromium-review.googlesource.com/722425Reviewed-by: default avatarNodir Turakulov <nodir@chromium.org>
Commit-Queue: Victor Costan <pwnall@chromium.org>
Cr-Commit-Position: refs/heads/master@{#509432}
parent 302be672
......@@ -153,6 +153,8 @@ class Handler(SimpleHTTPServer.SimpleHTTPRequestHandler):
self._DoImage(full_path, 'image/png')
elif path.lower().endswith('.jpg'):
self._DoImage(full_path, 'image/jpeg')
elif path.lower().endswith('.svg'):
self._DoImage(full_path, 'image/svg+xml')
elif os.path.isdir(full_path):
self._DoDirListing(full_path)
elif os.path.exists(full_path):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment