MCPcopy Create free account
hub / github.com/sql-js/sql.js / toggler

Function toggler

documentation/javascript/application.js:4515–4525  ·  view source on GitHub ↗
( event )

Source from the content-addressed store, hash-verified

4513 guid = fn.guid || jQuery.guid++,
4514 i = 0,
4515 toggler = function( event ) {
4516 // Figure out which function to execute
4517 var lastToggle = ( jQuery._data( this, "lastToggle" + fn.guid ) || 0 ) % i;
4518 jQuery._data( this, "lastToggle" + fn.guid, lastToggle + 1 );
4519
4520 // Make sure that clicks stop
4521 event.preventDefault();
4522
4523 // and execute the function
4524 return args[ lastToggle ].apply( this, arguments ) || false;
4525 };
4526
4527 // link all the functions, so any of them can unbind this click handler
4528 toggler.guid = guid;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…