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