[vlc-commits] web intf: mobile: delay loading of flowplayer
Francois Cartegnie
git at videolan.org
Fri Oct 21 22:47:14 CEST 2011
vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Fri Oct 21 20:58:44 2011 +0200| [dee4c92582a61fa4afe215896786effce9757d76] | committer: Francois Cartegnie
web intf: mobile: delay loading of flowplayer
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=dee4c92582a61fa4afe215896786effce9757d76
---
share/lua/http/mobile_view.html | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/share/lua/http/mobile_view.html b/share/lua/http/mobile_view.html
index 0e6231e..52b65b6 100644
--- a/share/lua/http/mobile_view.html
+++ b/share/lua/http/mobile_view.html
@@ -32,15 +32,16 @@
<script type="text/javascript" src="js/jquery-1.5.1.min.js"></script>
<script type="text/javascript" src="js/jquery-ui-1.8.13.custom.min.js"></script>
<script type="text/javascript" src="js/jquery.jstree.js"></script>
- <script type="text/javascript" src="http://static.flowplayer.org/js/flowplayer-3.2.6.min.js"></script>
<script type="text/javascript" src="js/controlers.js"></script>
<script type="text/javascript" src="js/ui.js"></script>
<script type="text/javascript">
var pollStatus = false;
- $(function(){
+ /* delay script loading so we won't block if we have no net access */
+ $.getScript('http://static.flowplayer.org/js/flowplayer-3.2.6.min.js', function(data, textStatus){
$('#player').empty();
$('#player').attr('href',$('#stream_protocol').val()+'://'+$('#stream_host').val()+':'+$('#stream_port').val()+'/'+$('#stream_file').val());
flowplayer("player", "http://releases.flowplayer.org/swf/flowplayer-3.2.7.swf");
+ /* .getScript only handles success() */
});
</script>
</head>
More information about the vlc-commits
mailing list