[ Index ] |
|
Code source de LifeType 1.2.4 |
1 /** 2 * This will be the base class for all Lifetype Javascript code. Right 3 * now only the TableEffects class extends this, but in the future all code 4 * will be moved to this framework. 5 */ 6 7 /** 8 * Base Lifetype class 9 */ 10 Lifetype = function() 11 { 12 // nothing yet 13 } 14 15 /** 16 * Compatibility check 17 */ 18 Lifetype.prototypeCompatibabilityCheck = function( str ) 19 { 20 if ( str == '_each' || 21 str == '_reverse' || 22 str == 'all' || 23 str == 'any' || 24 str == 'clear' || 25 str == 'collect' || 26 str == 'compact' || 27 str == 'detect' || 28 str == 'each' || 29 str == 'entries' || 30 str == 'extend' || 31 str == 'find' || 32 str == 'findAll' || 33 str == 'first' || 34 str == 'flatten' || 35 str == 'grep' || 36 str == 'include' || 37 str == 'indices' || 38 str == 'indexOf' || 39 str == 'inject' || 40 str == 'inspect' || 41 str == 'invoke' || 42 str == 'last' || 43 str == 'map' || 44 str == 'max' || 45 str == 'member' || 46 str == 'min' || 47 str == 'partition' || 48 str == 'pluck' || 49 str == 'reject' || 50 str == 'remove' || 51 str == 'removeItem' || 52 str == 'select' || 53 str == 'shift' || 54 str == 'sortBy' || 55 str == 'toArray' || 56 str == 'without' || 57 str == 'zip') 58 return true; 59 else 60 return false; 61 } 62 63 /** 64 * Return the base URL of the script 65 * 66 * @return Base URL 67 */ 68 Lifetype.getBaseURL = function() 69 { 70 // Get document base path 71 documentBasePath = document.location.href; 72 if (documentBasePath.indexOf('?') != -1) 73 documentBasePath = documentBasePath.substring(0, documentBasePath.indexOf('?')); 74 75 documentBasePath = documentBasePath.substring(0, documentBasePath.lastIndexOf('/')); 76 77 return( documentBasePath ); 78 } 79 80 81 /** 82 * Base UI class 83 */ 84 Lifetype.UI = function() 85 { 86 // nothing yet 87 }
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Mon Nov 26 21:04:15 2007 | par Balluche grâce à PHPXref 0.7 |
![]() |