Commit 8718e413 authored by fv3rdugo's avatar fv3rdugo
Browse files

Add set recommended options button

parent db657b4d
......@@ -27,7 +27,7 @@
% next;
% }
<div class="col-lg-10">
<select class="selectpicker form-control input-lg" name="driver_<%= $driver_name %>">
<select class="selectpicker form-control input-lg" id="driver_<%= $driver_name %>" name="driver_<%= $driver_name %>">
% for my $option( $driver->get_options ) {
% my $selected ='';
% $selected = 'selected' if $domain->get_driver($driver_name) eq $option->{value};
......@@ -43,16 +43,29 @@
</div>
</div>
<div class="col-md-6">
<div class="alert alert-info" role="alert">
<strong>Recommended options:</strong><br>
<span class="label label-default">image</span>:<span class="label label-success">auto_glz</span><br>
<span class="label label-default">jpeg</span>:<span class="label label-success">auto</span><br>
<span class="label label-default">zlib</span>:<span class="label label-success">auto</span><br>
<span class="label label-default">playback</span>:<span class="label label-success">on</span><br>
<span class="label label-default">streaming</span>:<span class="label label-success">filter</span><br>
</div>
<div class="alert alert-info" role="alert">
<strong>Recommended options:</strong><br>
<span class="label label-default">image</span>:<span class="label label-success">auto_glz</span><br>
<span class="label label-default">jpeg</span>:<span class="label label-success">auto</span><br>
<span class="label label-default">zlib</span>:<span class="label label-success">auto</span><br>
<span class="label label-default">playback</span>:<span class="label label-success">on</span><br>
<span class="label label-default">streaming</span>:<span class="label label-success">filter</span><br>
</div>
<button class="btn btn-primary pull-left" onclick="doSelect()">Set recommended options</button><br>
<p id="info" ></p>
</div>
</form>
</div>
</div>
<script type="text/javascript">
function doSelect() {
document.getElementById("driver_image").value = '11';
document.getElementById("driver_jpeg").value = '17';
document.getElementById("driver_zlib").value = '20';
document.getElementById("driver_playback").value = '23';
document.getElementById("driver_streaming").value = '25';
document.getElementById("info").innerHTML = "<br><strong>Success! </strong> Changes will apply on next start";
}
</script>
Supports Markdown
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