try to fix stream stopping

This commit is contained in:
Luke Pulverenti 2016-08-09 01:10:29 -04:00
parent e5525cd630
commit 9d8820cd93
2 changed files with 8 additions and 41 deletions

View File

@ -1,47 +1,14 @@
define(['focusManager', 'dom', 'scrollStyles'], function (focusManager, dom) {
function getOffsets(elems) {
function getBoundingClientRect(elem) {
var doc = document;
var results = [];
if (!doc) {
return results;
// Support: BlackBerry 5, iOS 3 (original iPhone)
// If we don't have gBCR, just use 0,0 rather than error
if (elem.getBoundingClientRect) {
return elem.getBoundingClientRect();
} else {
return { top: 0, left: 0 };
}
var docElem = doc.documentElement;
var docElemValues = {
clientTop: docElem.clientTop,
clientLeft: docElem.clientLeft
};
var win = doc.defaultView;
var winValues = {
pageXOffset: win.pageXOffset,
pageYOffset: win.pageYOffset
};
var box;
var elem;
for (var i = 0, length = elems.length; i < length; i++) {
elem = elems[i];
// Support: BlackBerry 5, iOS 3 (original iPhone)
// If we don't have gBCR, just use 0,0 rather than error
if (elem.getBoundingClientRect) {
box = elem.getBoundingClientRect();
} else {
box = { top: 0, left: 0 };
}
results[i] = {
top: box.top + winValues.pageYOffset - docElemValues.clientTop,
left: box.left + winValues.pageXOffset - docElemValues.clientLeft
};
}
return results;
}
function getPosition(scrollContainer, item, horizontal) {

View File

@ -163,7 +163,7 @@
html += '<div class="cardFooter">';
html += '<div class="cardText">' + user.Name + '</div>';
html += '<div class="cardText">';
html += '<div class="cardText cardText-secondary">';
var lastSeen = LoginPage.getLastSeenText(user.LastActivityDate);
if (lastSeen != "") {
html += lastSeen;