MCPcopy Create free account
hub / github.com/JsAaron/jQuery / fire

Function fire

2.0.3/2.0.3.js:2913–2938  ·  view source on GitHub ↗
( data )

Source from the content-addressed store, hash-verified

2911 stack = !options.once && [],
2912 // Fire callbacks
2913 fire = function( data ) {
2914 memory = options.memory && data;
2915 fired = true;
2916 firingIndex = firingStart || 0;
2917 firingStart = 0;
2918 firingLength = list.length;
2919 firing = true;
2920 for ( ; list && firingIndex < firingLength; firingIndex++ ) {
2921 if ( list[ firingIndex ].apply( data[ 0 ], data[ 1 ] ) === false && options.stopOnFalse ) {
2922 memory = false; // To prevent further calls using add
2923 break;
2924 }
2925 }
2926 firing = false;
2927 if ( list ) {
2928 if ( stack ) {
2929 if ( stack.length ) {
2930 fire( stack.shift() );
2931 }
2932 } else if ( memory ) {
2933 list = [];
2934 } else {
2935 self.disable();
2936 }
2937 }
2938 },
2939 // Actual Callbacks object
2940 self = {
2941 // Add a callback or a collection of callbacks to the list

Callers 1

2.0.3.jsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected