spec/dummy/tmp/cache/assets/D4E/1B0/sprockets%2Ff7cbd26ba1d28d48de824f0e94586655 in woople-theme-0.8.6 vs spec/dummy/tmp/cache/assets/D4E/1B0/sprockets%2Ff7cbd26ba1d28d48de824f0e94586655 in woople-theme-0.8.7
- old
+ new
@@ -1,12 +1,50 @@
-o: ActiveSupport::Cache::Entry :@compressedF:@expires_in0:@created_atf1354220049.486217:@value"_{I"
+o: ActiveSupport::Cache::Entry :@compressedF:@expires_in0:@created_atf1354292278.132121:@value"
+{I"
class:EFI"ProcessedAsset; FI"logical_path; FI"application.js; FI"
pathname; FI"0$root/app/assets/javascripts/application.js; FI"content_type; FI"application/javascript; FI"
-mtime; FI"2012-11-29T15:10:24-05:00; FI"length; FiXI"digest; F"%88bce38d77ed7b155d5f47a85438fbb2I"source; FI"X
+mtime; FI"2012-09-24T10:20:19-04:00; FI"length; FiI"digest; F"%4017c337190c668fac7ec995024ee924I"source; FI"
var showingPlayer;
+function showMobile() {
+ var modalContents = $('#myModal').html();
+ var selectedRow = $('#video_0_0');
+ var playerRow = selectedRow.after('<tr><td colspan=3>' + modalContents + '</td></tr>');
+
+ $('#myModal').remove();
+
+ var offset = selectedRow.offset();
+ window.scrollTo(offset.left, offset.top);
+
+ initPlayer();
+}
+
+function showDesktop() {
+ $('#myModal').modal();
+ $('#myModal').on('hide', function() {
+ window.location.href = '/course';
+ });
+
+ initPlayer();
+}
+
+function playerResizeListener() {
+ $(window).bind('resize orientationchange', resizePlayer);
+}
+
+function resizePlayer() {
+ var parentHeight = $('.modal-video-box').height();
+ var parentWidth = $('.modal-video-box').width();
+
+ $('#theme_video').css({'width': parentWidth, 'height': parentHeight});
+
+ // assume we are parsing a decimal -- http://stackoverflow.com/questions/850341/workarounds-for-javascript-parseint-octal-bug
+ $('#theme_video').attr('width', parseInt(parentWidth, 10));
+ $('#theme_video').attr('height', parseInt(parentHeight, 10));
+}
+
function initPlayer() {
jwplayer("theme_video").setup({
image: '/assets/woople-theme/poster.jpg',
controlbar: {
position: 'bottom'
@@ -15,28 +53,31 @@
file: videoOptions.desktopSrc,
height: '100%',
modes: [{
type: "flash",
src: "/assets/jwplayer/player.swf"
- },{
- type: "html5",
- config: {
- file: videoOptions.mobileSrc
- }
}],
provider: "video",
width: '100%',
plugins: {
"gapro-2":{}
}
});
}
$(document).ready(function() {
+
if (showingPlayer) {
- initPlayer();;
+ if ($(window).width() < 768) {
+ showMobile();
+ } else {
+ showDesktop();
+ }
+
+ playerResizeListener();
+ resizePlayer();
}
});
-; FI"dependency_digest; F"%73ea53c610027068c0ef1683af7a4a49I"required_paths; F[I"0$root/app/assets/javascripts/application.js; FI"4$root/app/assets/javascripts/stay-standalone.js; FI"dependency_paths; F[{I" path; FI"!$root/app/assets/javascripts; TI"
-mtime; FI"2012-11-29T15:10:24-05:00; FI"digest; F"%f62b323934dc14fb7a6ac09a77ff80bb{I" path; FI"0$root/app/assets/javascripts/application.js; FI"
-mtime; FI"2012-11-29T15:10:24-05:00; FI"digest; F"%72a03ee4155006a494b8be1b5915b534{I" path; FI"4$root/app/assets/javascripts/stay-standalone.js; FI"
-mtime; FI"2012-11-13T14:50:14-05:00; FI"digest; F"%d0aef16e49b2e0b2652f7aae13b0e8c2I"
_version; F"%9f3b95dd7ea3030dc35985c0a8020862
+; FI"dependency_digest; F"%3c34e0f0e94d7600d47d30519499739dI"required_paths; F[I"0$root/app/assets/javascripts/application.js; FI"4$root/app/assets/javascripts/stay-standalone.js; TI"dependency_paths; F[{I" path; FI"!$root/app/assets/javascripts; TI"
+mtime; FI"2012-11-08T15:08:42-05:00; FI"digest; F"%f62b323934dc14fb7a6ac09a77ff80bb{I" path; FI"0$root/app/assets/javascripts/application.js; FI"
+mtime; FI"2012-09-24T10:20:19-04:00; FI"digest; F"%6305acaf0445fca222e1c5afab828d50{I" path; FI"4$root/app/assets/javascripts/stay-standalone.js; TI"
+mtime; FI"2012-11-08T15:08:42-05:00; FI"digest; F"%d0aef16e49b2e0b2652f7aae13b0e8c2I"
_version; F"%9f3b95dd7ea3030dc35985c0a8020862
\ No newline at end of file