This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getStyle(elem) | |
{ | |
return (elem.currentStyle || window.getComputedStyle(elem, false)); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function setStyle( elem, propertyObject ) | |
{ | |
for (var property in propertyObject) | |
{ | |
elem.style[property] = propertyObject[property]; | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function scrollbarWidth() | |
{ | |
var $inner = jQuery('<div style="width: 100%; height:200px;">test</div>'), | |
$outer = jQuery('<div style="width:200px;height:150px; position: absolute; top: 0; left: 0; visibility: hidden; overflow:hidden;"></div>').append($inner), | |
inner = $inner[0], | |
outer = $outer[0]; | |
jQuery('body').append(outer); | |
var width1 = inner.offsetWidth; | |
$outer.css('overflow', 'scroll'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var add = function(strNumOne, strNumTwo) | |
{ | |
var first; | |
var second; | |
var tempNumber = new Array(); | |
if(strNumOne.length >= strNumTwo.length) | |
{ | |
first = strNumOne; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isFlashEnabled() | |
{ | |
var hasFlash = false; | |
try | |
{ | |
var flashObject = new ActiveXObject('ShockwaveFlash.ShockwaveFlash'); | |
if(flashObject) hasFlash = true; | |
} | |
catch(e) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var filePath = function() | |
{ | |
//grab the path of this js file (must include name of file) | |
var _scripts = document.getElementsByTagName("script"); | |
var _pattern = /^(.*?)\/js\/filePath.js/i; | |
var _path; | |
for (var i = _scripts.length - 1; i >= 0; i--) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//polyfill window.offsetWidth and window.offsetHeight | |
var windowOffset = function() | |
{ | |
var getOffset = function() | |
{ | |
if(typeof(_cacheResize) === "function") | |
{ | |
_cacheResize | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fillViewList = {}; | |
var fillViewAdd = function(element) | |
{ | |
element.style.width = "auto"; | |
element.style.height = "auto"; | |
var _width = element.offsetWidth; | |
var _height = element.offsetHeight; | |
fillViewList[element] = {width: _width, height: _height}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function parallelShuffleArrays(arrays) | |
{ | |
var itemsLeft; | |
var selectedItemIndex; | |
var temporaryItem; | |
var array; | |
function useObject() | |
{ | |
//check to see if all arrays are equal lengths |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getNumberItemsObject(arrays) | |
{ | |
var itemsLeft; | |
for (property in arrays) | |
{ | |
if (typeof(itemsLeft) === "undefined") | |
{ | |
itemsLeft = arrays[property].length; | |
} |
OlderNewer