File tree Expand file tree Collapse file tree 1 file changed +8
-12
lines changed Expand file tree Collapse file tree 1 file changed +8
-12
lines changed Original file line number Diff line number Diff line change 4
4
5
5
var
6
6
that ,
7
- oldSource ,
8
7
isStopped = true ,
9
8
isLoaded = false ,
10
9
isLoading = false ,
16
15
api . video = that = {
17
16
18
17
// Manipulating the src="" attribute.
19
- unLoad : function ( ) {
20
- isLoaded = false ;
21
- jqVideo . attr ( "src" , "" ) ;
22
- if ( api . playlist . selectedFile ( ) . mediaType === "video" ) {
23
- jqVideoThumb . attr ( "src" , "" ) ;
24
- }
25
- return that ;
26
- } ,
27
18
load : function ( url ) {
28
- oldSource = url ;
29
19
jqVideo . attr ( "src" , url ) ;
30
- jqVideoThumb . attr ( "src" , api . playlist . selectedFile ( ) . mediaType === "video" ? url : "" ) ;
20
+ if ( api . playlist . selectedFile ( ) . mediaType === "video" ) {
21
+ jqVideoThumb . attr ( "src" , url ) ;
22
+ }
31
23
isLoading = true ;
32
24
return that ;
33
25
} ,
@@ -75,8 +67,12 @@ api.video = that = {
75
67
} ,
76
68
stop : function ( ) {
77
69
if ( ! isStopped ) {
70
+ that
71
+ . pause ( )
72
+ . currentTime ( 0 )
73
+ ;
78
74
isStopped = true ;
79
- that . unLoad ( "" ) ;
75
+ isLoaded = false ;
80
76
jqVideo . trigger ( "stop" ) ;
81
77
}
82
78
return that ;
You can’t perform that action at this time.
0 commit comments