1 |
Index: template_maxi/player_flv_maxi.swf |
2 |
=================================================================== |
3 |
Cannot display: file marked as a binary type. |
4 |
svn:mime-type = application/octet-stream |
5 |
Index: template_maxi/TemplateMaxi.as |
6 |
=================================================================== |
7 |
--- template_maxi/TemplateMaxi.as (revision 137) |
8 |
+++ template_maxi/TemplateMaxi.as (working copy) |
9 |
@@ -1666,6 +1666,10 @@ |
10 |
vertical, |
11 |
horizontal); |
12 |
} |
13 |
+ public function get getPosition() |
14 |
+ { |
15 |
+ return this.controller.getPosition(); |
16 |
+ } |
17 |
/*=================== FIN = CONTROLES JAVASCRIPT = FIN ===================*/ |
18 |
/*========================================================================*/ |
19 |
} |
20 |
\ No newline at end of file |
21 |
Index: template_maxi/compileTemplateMaxi.sh |
22 |
=================================================================== |
23 |
--- template_maxi/compileTemplateMaxi.sh (revision 137) |
24 |
+++ template_maxi/compileTemplateMaxi.sh (working copy) |
25 |
@@ -1,5 +1,5 @@ |
26 |
#!/bin/bash |
27 |
|
28 |
cp ../base/player.swf player_flv_maxi.swf |
29 |
-../mtasc/mtasc -version 8 -keep -v -main -cp ../classes -swf player_flv_maxi.swf TemplateMaxi.as |
30 |
+mtasc -version 8 -keep -v -main -cp ../classes -swf player_flv_maxi.swf TemplateMaxi.as |
31 |
|
32 |
Index: classes/PlayerDefault.as |
33 |
=================================================================== |
34 |
--- classes/PlayerDefault.as (revision 137) |
35 |
+++ classes/PlayerDefault.as (working copy) |
36 |
@@ -22,6 +22,9 @@ |
37 |
* @version 0.9.1 (08/09/2007) |
38 |
* @license http://creativecommons.org/licenses/by-sa/3.0/deed.fr |
39 |
*/ |
40 |
+ |
41 |
+import flash.external.ExternalInterface; |
42 |
+ |
43 |
class PlayerDefault extends PlayerBasic |
44 |
{ |
45 |
// ------------------------------ VARIABLES -------------------------------- |
46 |
@@ -152,13 +155,24 @@ |
47 |
* |
48 |
* @return Le sous-titre |
49 |
*/ |
50 |
+ var _last_subtitle:Number = -1; |
51 |
public function getSubtitle():String |
52 |
{ |
53 |
for (var i:Number=0; i<this._subtitles.length; i++) { |
54 |
if (this._ns.time*1000 >= this._subtitles[i].timeStart && this._ns.time*1000 <= this._subtitles[i].timeEnd) { |
55 |
+ if ( _last_subtitle != i ) { |
56 |
+ var subtitle = this._subtitles[i]; |
57 |
+ subtitle.i = i; |
58 |
+ ExternalInterface.call("flv_subtitle", subtitle, i ); |
59 |
+ _last_subtitle = i; |
60 |
+ } |
61 |
return this._subtitles[i].message; |
62 |
} |
63 |
} |
64 |
+ if ( _last_subtitle >= 0 ) { |
65 |
+ ExternalInterface.call("flv_subtitle", { timeStart: this._ns.time * 1000 }, _last_subtitle ); |
66 |
+ _last_subtitle = -1; |
67 |
+ } |
68 |
return ""; |
69 |
} |
70 |
/** |
71 |
@@ -174,4 +188,4 @@ |
72 |
} |
73 |
/*==================== FIN = METHODES PUBLIQUES = FIN ====================*/ |
74 |
/*========================================================================*/ |
75 |
-} |
76 |
\ No newline at end of file |
77 |
+} |