Skip to content

Commit

Permalink
Rebuild and Merge remote-tracking branch 'wet-boew/master' into featu…
Browse files Browse the repository at this point in the history
…re-table-parser

Conflicts:
	build/js/css/pe-ap-ie-min.css
	build/js/css/pe-ap-min.css
	build/js/pe-ap-min.js
  • Loading branch information
duboisp committed Aug 23, 2012
2 parents f254046 + f7ffad0 commit c852975
Show file tree
Hide file tree
Showing 8 changed files with 36 additions and 27 deletions.
2 changes: 1 addition & 1 deletion build/js/css/pe-ap-ie-min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion build/js/css/pe-ap-min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion build/js/pe-ap-min.js

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions build/js/polyfills/progress-min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 12 additions & 6 deletions src/js/polyfills/progress.js
@@ -1,18 +1,24 @@
/*! HTML5 Progress polyfill | Jonathan Stipe | https://github.com/jonstipe/progress-polyfill*/
/* Updated by Laurent Goderre | https://github.com/LaurentGoderre/progress-polyfill */
/*!
* Web Experience Toolkit (WET) / Boîte à outils de l'expérience Web (BOEW)
* www.tbs.gc.ca/ws-nw/wet-boew/terms / www.sct.gc.ca/ws-nw/wet-boew/conditions
*/
/*
* Progress
*/
/*global jQuery: false*/
(function ($) {
$.fn.progress = function () {
return $(this).each(function () {
var $this = $(this),
progress = $this.children('.progress-frame, .progress-undefined'),
progress = $this.children('.wb-progress-outer, .wb-progress-undefined'),
params,
amt,
attr = {'role': 'progressbar'};

$this.off('DOMAttrModified propertychange');
if ($this.is('[value]')) {
if (progress.length < 1) {
progress = $('<div class="progress-frame"><div class="progress-bar"/></div>');
progress = $('<div class="wb-progress-outer"><div class="wb-progress-inner"/></div>');
$this.append(progress);
}
params = $([$this.attr('max') || '1.0', $this.attr('value')]).map(function () {
Expand All @@ -26,10 +32,10 @@

if (attr['aria-valuenow'] > attr['aria-valuemax']) {attr['aria-valuenow'] = attr['aria-valuemax']; }
amt = (attr['aria-valuenow'] / attr['aria-valuemax']) * 100.0;
progress.children('.progress-bar').css('width', amt + '%');
progress.children('.wb-progress-inner').css('width', amt + '%');

} else if ($this.not('[value]') && progress.length < 1) {
progress = $('<div class="progress-undefined"/>');
progress = $('<div class="wb-progress-undefined"/>');
$this.append(progress);
}

Expand Down
4 changes: 2 additions & 2 deletions src/js/sass/multimedia.scss
Expand Up @@ -93,12 +93,12 @@ $progress-color: #000;
background: $progress-color;
}
/* Polyfill */
div.progress-frame {
div.wb-progress-outer {
border:none;
background-color:transparent!important;
padding:0;
}
div.progress-bar {
div.wb-progress-inner {
background-color:$progress-color!important;
padding:0;
}
Expand Down
26 changes: 13 additions & 13 deletions src/js/sass/progress.scss
Expand Up @@ -13,19 +13,19 @@
}

progress {
display:inline-block;
display:inline-block;

div.progress-frame {
@include progress(#FFF);
}

div.progress-undefined {
@include progress(#FF9999);
}
div.wb-progress-outer {
@include progress(#FFF);
}

div.progress-bar {
height: 100%;
border: none;
background-color: #009900;
}
div.wb-progress-undefined {
@include progress(#FF9999);
}

div.wb-progress-inner {
height: 100%;
border: none;
background-color: #009900;
}
}
2 changes: 1 addition & 1 deletion src/js/workers/multimedia.js
Expand Up @@ -147,7 +147,7 @@
this.setMuted(!this.getMuted());
}

if ($target.is('progress') || $target.hasClass('progress-frame') || $target.hasClass('progress-bar')) {
if ($target.is('progress') || $target.hasClass('wb-progress-inner') || $target.hasClass('wb-progress-outer')) {
p = (e.pageX - $target.offset().left) / $target.width();
this.setCurrentTime(this.getDuration() * p);
}
Expand Down

0 comments on commit c852975

Please sign in to comment.