wenhongquan 8 лет назад
Родитель
Сommit
91a0ca801b
2 измененных файлов с 13 добавлено и 7 удалено
  1. 8 5
      VisualInspection/js/mytask/check.js
  2. 5 2
      VisualInspection/js/util/video.js

+ 8 - 5
VisualInspection/js/mytask/check.js

@@ -116,8 +116,8 @@ function fullscreen() {
         '                                    <!--<i class="icon icon-spin icon-spinner  icon-5x" style="margin-top:100px"></i>-->' +
         '                                </div>' +
         '                                <div class="row" class="col-md-12" style="padding:5px 10px 5px 10px;text-align:center;margin:0px">' +
-        '                                    <input id="full_ex1" class="col-md-12" type="text" data-slider-min="0" data-slider-max="100" data-slider-step="1" data-slider-value="0"' +
-        '                                    />' +
+        '                                    <input id="full_ex1" class="col-md-12" type="text" data-slider-min="0" data-slider-max="100" data-slider-step="1" data-slider-value="0"/>' +
+        '                                    ' +
         '                                </div>' +
         '                                <div class="row" style="padding:0px 5px 0px 5px;text-align:center;margin:0px">' +
         '                                    <select class="form-control" id="full_video_list" style="width:200px;float:left;display:none;"></select>' +
@@ -150,16 +150,19 @@ function fullscreen() {
         shadeClose: false,
         content: "<div id='layer_content' >" + contenthtml + "</div>",
         success: function(layero, index) {
-
+    
+            // slider_current_value = 90;
             $("#full_video_pos").val($("#video_pos").val());
 
             $('#full_ex1').slider({ tooltip: 'hide' });
             $("#full_ex1").on("slideStop", function(slideEvt) {
                 setVideoProcess(slideEvt.value);
             });
-            $("#full_ex1").val($("#ex1").value)
             $("#full_ex1").slider({ step: 5, min: 0, max: maxVV });
-
+            
+             $("#full_ex1").slider('setValue',slider_current_value);
+          
+            
 
             $("#full_fast_info").html($("#fast_info").html());
             $("#full_slow_info").html($("#slow_info").html());

+ 5 - 2
VisualInspection/js/util/video.js

@@ -34,8 +34,10 @@ function setVideoPos(){
    if($("#full_video_pos").length >0){
        pos = $("#full_video_pos").val();
    }
+  
    
    if(/^(\+|-)?\d+($|\.\d+$)/.test(pos)){
+       slider_current_value = pos;
        callFunc("video_pos", pos);
    }
 
@@ -87,17 +89,18 @@ function setProcessValue(maxValue){
     // console.log(max);
     maxVV = maxValue;
     $("#ex1").slider({step: 5, min: 0, max: maxValue});
-    if($("#full_ex1")){
+    if($("#full_ex1").length>0){
          $("#full_ex1").slider({step: 5, min: 0, max: maxValue});
     }
 }
 
+var slider_current_value = 0;
 function setCurrentProcessValue(value){
     // alert("ddd"+value);
     // console.log(value);
     
     var vv =maxVV*(value/100)
-
+    slider_current_value = parseInt(vv);
     $("#ex1").slider('setValue',parseInt(vv));
      if($("#full_ex1").length>0){
          $("#full_ex1").slider('setValue',parseInt(vv));