Skip to content
This repository was archived by the owner on Jul 3, 2024. It is now read-only.

Commit

Permalink
Added ability for extensions to dynamically redefine themselves
Browse files Browse the repository at this point in the history
Cleaned up some leaky variables (thanks to EmissionsTest.js)
Removed embedded QUnit in favor of making it a submodule
Added EmissionsTest.js as a submodule to catch variable leaks (/test/leaks.html)
Moved jQuery to the vendors directory
  • Loading branch information
aarongustafson committed Jul 20, 2010
1 parent 368e813 commit 027cc9b
Showing 14 changed files with 253 additions and 5,346 deletions.
6 changes: 6 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
[submodule "vendors/QUnit"]
path = vendors/QUnit
url = git://github.com/jquery/qunit.git
[submodule "vendors/EmissionsTest"]
path = vendors/EmissionsTest
url = git://github.com/easy-designs/EmissionsTest.js.git
4 changes: 4 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
*v1.2.6.1* (2010-07-20)
* Added ability for extensions to dynamically redefine themselves
* cleaned up some leaky variables (thanks to EmissionsTest.js)

*v1.2.6* (2010-07-13)
* overhauled eCSStender::isSupported() so it can accept
- assignment of support info into the cache and
4 changes: 2 additions & 2 deletions min/eCSStender.js

Large diffs are not rendered by default.

34 changes: 20 additions & 14 deletions src/eCSStender.js
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@
Function: eCSStender()
Author: Aaron Gustafson (aaron at easy-designs dot net)
Creation Date: 2006-12-03
Version: 1.2.6
Version: 1.2.6.1
Homepage: http://eCSStender.org
License: MIT License (see homepage)
------------------------------------------------------------------------------*/
@@ -129,7 +129,7 @@ License: MIT License (see homepage)
// eCSStender Object
eCSStender = {
name: ECSSTENDER,
version: '1.2.6',
version: '1.2.6.1',
fonts: [],
pages: {},
at: {},
@@ -201,7 +201,7 @@ License: MIT License (see homepage)
{
if ( __no_cache || __local ){ return; }
// check the xhr headers against what we read from the cache
var key, cached = __local_cache.xhr, i=j=0;
var key, cached = __local_cache.xhr, i=0, j=0;
eCSStender.cache = TRUE;
for ( key in __modified )
{
@@ -368,17 +368,18 @@ License: MIT License (see homepage)
properties = extractProperties( e[1], e[2], extension[PROPERTIES] );
result = extension[CALLBACK]( e[2], properties, e[1], specificity );
// allow on-the-fly re-definition of callback
// if ( is( result, FUNCTION ) )
// {
// __eCSStensions[e[0]][CALLBACK] = result;
// }
if ( is( result, FUNCTION ) )
{
__eCSStensions[e[0]][CALLBACK] = result;
}
__eCSStensions[e[0]][PROCESSED].push( selector_id );
}
}
}
function triggerOnCompletes()
{
for ( var o = __on_complete.length-1; o >= 0; o-- )
var o = __on_complete.length;
while ( o-- )
{
__on_complete[o]();
}
@@ -495,8 +496,9 @@ License: MIT License (see homepage)
actual_path = stylesheet.actual_path,
css_path = actual_path || stylesheet.href,
parent = stylesheet.parentStyleSheet,
curr_path, path_last_slash, file_name,
parent_path = prefix = EMPTY;
parent_path = EMPTY,
prefix = EMPTY,
curr_path, path_last_slash, file_name;
if ( ! css_path ) { css_path = NULL; }
// we only want sheets
if ( ! actual_path &&
@@ -743,7 +745,8 @@ License: MIT License (see homepage)
}
function collapseAtMedia( css, match, id )
{
media = match[1].split(REGEXP_COMMA);
var
media = match[1].split(REGEXP_COMMA),
styles = match[2];
createMediaContainers( media );
__media_groups[id] = {
@@ -763,7 +766,8 @@ License: MIT License (see homepage)
media = arrayify(media);
// parse it into blocks & remove the last item (which is empty)
var blocks = css.split(CLOSE_CURLY),
b=m=a=0, bLen, mLen=media.length, props, prop, selector, medium, arr, aLen;
b=0, m=0, a=0, bLen, mLen = media.length,
props, prop, selector, medium, arr, aLen;
blocks.pop();
// loop
for ( bLen=blocks.length; b<bLen; b++ )
@@ -1733,10 +1737,11 @@ License: MIT License (see homepage)
l_fragment = lookup[FRAGMENT],
l_prefix = lookup[PREFIX],
l_media = lookup[MEDIA],
props, property,
min, max,
medium, e_media,
sLoop, styles, sorted_styles,
s, sLen, selector, found,
s, sLen, selector, block, found,
i, iLen, test, matches = [];
// figure out specificity params
if ( defined( l_specificity ) )
@@ -2037,7 +2042,8 @@ License: MIT License (see homepage)
aLen = arg.length,
// global test vars
what = arg[1],
value = html = arg[2] || NULL,
value = arg[2] || NULL,
html = value,
el = arg[3] || NULL,
// property test vars
property, settable = TRUE, i,
Loading
Oops, something went wrong.

0 comments on commit 027cc9b

Please sign in to comment.