Changeset 629
- Timestamp:
- 03/05/06 13:54:26 (2 years ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
mochikit/branches/scriptaculous/MochiKit/Signal.js
r628 r629 361 361 _getSlot: function (slot, func) { 362 362 if (typeof(func) == 'string' || typeof(func) == 'function') { 363 if (typeof(func) == 'string' && typeof(slot[func]) == 'undefined') {364 throw new Error('Invalid function slot');365 }366 363 slot = [slot, func]; 367 364 } else if (!func && typeof(slot) == 'function') { … … 458 455 459 456 slot = MochiKit.Signal._getSlot(slot, func); 460 //alert(slot + " " + slot.length + " " + typeof(slot[1]) + " " + slot[0][slot[1]]);461 457 462 458 // Find the signal, attach the slot. … … 470 466 } 471 467 472 // Add the signal connector if it hasn t been done already.468 // Add the signal connector if it hasn't been done already. 473 469 if (!src.__listeners[sig]) { 474 470 var listener = function (nativeEvent) { … … 542 538 } 543 539 } 544 } else {545 throw new Error("Invalid signal to disconnect");546 540 } 547 541
