From 1c01a28d9001d5caf9653d1c37c036c5473dc836 Mon Sep 17 00:00:00 2001
From: Andreas Valder <andreasv@fsmpi.rwth-aachen.de>
Date: Tue, 6 Sep 2016 19:31:00 +0200
Subject: [PATCH] fixed drop-down menus

---
 templates/lecture.html | 10 +++++-----
 templates/macros.html  | 30 +++++++++++++++++-------------
 2 files changed, 22 insertions(+), 18 deletions(-)

diff --git a/templates/lecture.html b/templates/lecture.html
index 1e84d59..2f6ae67 100644
--- a/templates/lecture.html
+++ b/templates/lecture.html
@@ -12,13 +12,13 @@
 	<div class="panel-body">
 		<div class="row" style="padding: 0px;">
 			<div class="col-sm-6 col-xs-12" style="padding-bottom: 5px;">
-				<span>
-					<a href="{{url_for('course', handle=course.handle)}}#lecture-{{lecture.id}}" class="btn btn-default" >Zur Veranstaltungsseite</a>
-				<span>
+				<a href="{{url_for('course', handle=course.handle)}}#lecture-{{lecture.id}}" class="btn btn-default" >Zur Veranstaltungsseite</a>
 			</div>
 			<div class="col-sm-6 col-xs-12">
-				<div class="pull-right" style="margin-left: 10px;">{{ video_download_btn(videos) }}</div>
-				<div class="pull-right">{{ video_embed_btn(lecture.id) }}</div>
+				<ul class="list-inline pull-right">
+					<li>{{ video_embed_btn(lecture.id) }}</li>
+					<li class="dropdown">{{ video_download_btn(videos) }}</li>
+				</ul>
 			</div>
 		</div>
 		<div class="row">
diff --git a/templates/macros.html b/templates/macros.html
index 4c7a73e..e77412d 100644
--- a/templates/macros.html
+++ b/templates/macros.html
@@ -95,7 +95,7 @@
 {% endmacro %}
 
 {% macro video_download_btn(videos) %}
-<button class="btn btn-primary dropdown-toggle{% if videos|length is equalto 0 %} disabled{% endif %}" type="button" data-toggle="dropdown">Download <span class="caret"></span></button>
+<span class="btn btn-primary dropdown-toggle{% if videos|length is equalto 0 %} disabled{% endif %}" type="button" data-toggle="dropdown">Download <span class="caret"></span></span>
 <ul class="dropdown-menu">
 	{% for v in videos %}
 		{% if v.downloadable %}	
@@ -152,18 +152,22 @@ $('#embedcodebtn').popover(
 				{% endif %}
 			</ul>
 		</span>
-		<span class="col-sm-3 col-xs-12">
-			<span class="pull-right">
-				<span>
-					{{ video_download_btn(videos) }}
-				</span>
-				<a href="{{url_for('lecture', id=lecture.id)}}" class="btn btn-default {% if videos|length is equalto 0 %}disabled{% endif %}">
-					<span class="glyphicon glyphicon-play"></span>
-					Play
-				</a>
-				{{ valuedeletebtn(['lectures',lecture.id,'deleted']) }}
-			</span>
-		</span>
+		<div class="col-sm-3 col-xs-12">
+			<ul class="pull-right list-inline">
+				<li class="dropdown">
+						{{ video_download_btn(videos) }}
+				</li>
+				<li>
+						<a href="{{url_for('lecture', id=lecture.id)}}" class="btn btn-default {% if videos|length is equalto 0 %}disabled{% endif %}">
+							<span class="glyphicon glyphicon-play"></span>
+							Play
+						</a>
+				</li>
+				<li>
+						{{ valuedeletebtn(['lectures',lecture.id,'deleted']) }}
+				</li>
+			</ul>
+		</div>
 	</div>
 </li>
 {% endmacro %}
-- 
GitLab