From 3db930cb9386680879a9e1b8e744435757a41c80 Mon Sep 17 00:00:00 2001 From: Antoine Levitt Date: Tue, 12 Nov 2019 19:06:36 +0100 Subject: [PATCH] correct mimetype for mov --- src/animation.jl | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/src/animation.jl b/src/animation.jl index e4a213ce..63e001d0 100644 --- a/src/animation.jl +++ b/src/animation.jl @@ -104,15 +104,18 @@ end # write out html to view the gif function Base.show(io::IO, ::MIME"text/html", agif::AnimatedGif) ext = file_extension(agif.filename) - write(io, if ext == "gif" - "" + if ext == "gif" + html = "" elseif ext in ("mov", "mp4") - "" + mimetype = ext == "mov" ? "video/quicktime" : "video/mp4" + html = "" else error("Cannot show animation with extension $ext: $agif") - end) + end + + write(io, html) return nothing end