[pLog-svn] r4708 - plog/branches/lifetype-1.2/js/ui

oscar at devel.lifetype.net oscar at devel.lifetype.net
Sat Feb 10 05:12:14 EST 2007


Author: oscar
Date: 2007-02-10 05:12:14 -0500 (Sat, 10 Feb 2007)
New Revision: 4708

Modified:
   plog/branches/lifetype-1.2/js/ui/core.js
Log:
This belongs to the previous commit


Modified: plog/branches/lifetype-1.2/js/ui/core.js
===================================================================
--- plog/branches/lifetype-1.2/js/ui/core.js	2007-02-10 10:11:49 UTC (rev 4707)
+++ plog/branches/lifetype-1.2/js/ui/core.js	2007-02-10 10:12:14 UTC (rev 4708)
@@ -13,6 +13,72 @@
 }
 
 /**
+ * Compatibility check
+ */
+Lifetype.prototypeCompatibabilityCheck = function( str )
+{
+    if ( str == '_each' ||
+	  	 str == '_reverse' ||
+         str == 'all' ||
+         str == 'any' ||
+         str == 'clear' ||
+         str == 'collect' ||
+         str == 'compact' ||
+         str == 'detect' ||
+         str == 'each' ||
+         str == 'entries' ||
+         str == 'extend' ||
+         str == 'find' ||
+         str == 'findAll' ||
+         str == 'first' ||
+         str == 'flatten' ||
+         str == 'grep' ||
+         str == 'include' ||
+         str == 'indices' ||
+         str == 'indexOf' ||
+         str == 'inject' ||
+         str == 'inspect' ||
+         str == 'invoke' ||
+         str == 'last' ||
+         str == 'map' ||
+         str == 'max' ||
+         str == 'member' ||
+         str == 'min' ||
+         str == 'partition' ||
+         str == 'pluck' ||
+         str == 'reject' ||
+         str == 'remove' ||
+         str == 'removeItem' ||
+         str == 'select' ||
+         str == 'shift' ||
+         str == 'sortBy' ||
+         str == 'toArray' ||
+         str == 'without' ||
+         str == 'zip')
+        return true;
+    else
+    	return false;
+}
+
+/**
+ * Return the base URL of the script
+ *
+ * @return Base URL
+ */
+Lifetype.getBaseURL = function()
+{
+	// Get document base path
+	documentBasePath = document.location.href;
+	if (documentBasePath.indexOf('?') != -1)
+		documentBasePath = documentBasePath.substring(0, documentBasePath.indexOf('?'));
+		
+	documentBasePath = documentBasePath.substring(0, documentBasePath.lastIndexOf('/'));
+
+	return( documentBasePath );
+}
+
+
+/**
  * Base UI class
  */
 Lifetype.UI = function() 



More information about the pLog-svn mailing list