Commit 585c0b74e94587397e049f5bd280d3ea79895771
1 parent
ff5a3340
Exists in
master
and in
2 other branches
Stop video on wizard
Showing
1 changed file
with
6 additions
and
6 deletions
Show diff stats
app/assets/javascripts/v_libras/requests/new.js
... | ... | @@ -7,7 +7,6 @@ $(function () { |
7 | 7 | enablePagination: true, |
8 | 8 | forceMoveForward: true, |
9 | 9 | |
10 | - onStepChanging: stepValidation, | |
11 | 10 | onStepChanged: stepChanged, |
12 | 11 | onFinished: finished, |
13 | 12 | |
... | ... | @@ -26,14 +25,17 @@ $(function () { |
26 | 25 | var totalSteps = $("#vlibras-wizard .content section").size(); |
27 | 26 | |
28 | 27 | if ((priorIndex === 0) && (currentIndex === 1)) { |
28 | + VLibrasVideo.stop(); | |
29 | 29 | VLibrasSubAudio.play(); |
30 | 30 | } |
31 | 31 | |
32 | 32 | if ((priorIndex === 1) && (currentIndex === 2)) { |
33 | + VLibrasSubAudio.stop(); | |
33 | 34 | VLibrasPosition.play(); |
34 | 35 | } |
35 | 36 | |
36 | 37 | if ((priorIndex === 2) && (currentIndex === 3)) { |
38 | + VLibrasPosition.stop(); | |
37 | 39 | VLibrasSize.play(); |
38 | 40 | } |
39 | 41 | |
... | ... | @@ -52,10 +54,6 @@ $(function () { |
52 | 54 | deactivateNextButton(); |
53 | 55 | } |
54 | 56 | |
55 | - function stepValidation(event, currentIndex, newIndex) { | |
56 | - return true; | |
57 | - } | |
58 | - | |
59 | 57 | $('#menu #btn-next').click(function() { |
60 | 58 | // Number of steps |
61 | 59 | var totalSteps = $("#vlibras-wizard .content section").size(); |
... | ... | @@ -66,6 +64,8 @@ $(function () { |
66 | 64 | } else { |
67 | 65 | $("#vlibras-wizard").steps('next'); |
68 | 66 | } |
67 | + | |
68 | + return false; | |
69 | 69 | }); |
70 | 70 | |
71 | 71 | function activateNextButton() { |
... | ... | @@ -103,7 +103,7 @@ $(function () { |
103 | 103 | console.debug("Serviço: video-legenda"); |
104 | 104 | |
105 | 105 | $("#vlibras-form").addHidden('service', 'video-legenda'); |
106 | - $("#subtitle-upload").parent().show(); | |
106 | + $("#subtitle-upload").parent().parent().show(); | |
107 | 107 | |
108 | 108 | $('html, body').animate({ |
109 | 109 | scrollTop: $("#subtitle-upload").offset().top | ... | ... |