? jquery_ui.drush.inc
Index: README.txt
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/jquery_ui/README.txt,v
retrieving revision 1.5.2.3
diff -u -p -r1.5.2.3 README.txt
--- README.txt	7 Aug 2009 17:03:24 -0000	1.5.2.3
+++ README.txt	26 Dec 2009 22:08:19 -0000
@@ -23,21 +23,21 @@ To submit bug reports and feature sugges
 
 -- INSTALLATION --
 
-* Copy the jquery_ui module directory to your sites/all/modules directory.
+* Copy the libraries and jquery_ui modules to your sites/all/modules folder.
 
 * Download the latest jQuery UI 1.6 release from:
 
     http://code.google.com/p/jquery-ui/downloads/list?can=3&q=1.6
 
-* Extract it as a sub-directory called 'jquery.ui' in the jquery_ui folder:
+* Extract it to a folder in sites/all/libraries and name it 'jquery.ui':
 
-    /sites/all/modules/jquery_ui/jquery.ui/
+    /sites/all/libraries/jquery.ui/
 
   so the actual jQuery UI JavaScript files are located in:
 
-    /sites/all/modules/jquery_ui/jquery.ui/ui/*.js
+    /sites/all/libraries/jquery.ui/ui/*.js
 
-* Enable the module at Administer >> Site building >> Modules.
+* Enable the libraries and jquery_ui modules at admin/build/modules.
 
 
 -- JQUERY UI 1.7 --
Index: jquery_ui.info
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/jquery_ui/jquery_ui.info,v
retrieving revision 1.3
diff -u -p -r1.3 jquery_ui.info
--- jquery_ui.info	21 May 2009 22:03:30 -0000	1.3
+++ jquery_ui.info	26 Dec 2009 22:08:19 -0000
@@ -3,3 +3,4 @@ name = jQuery UI
 description = Provides the jQuery UI plug-in to other Drupal modules.
 package = User interface
 core = 6.x
+dependencies[] = libraries
Index: jquery_ui.install
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/jquery_ui/Attic/jquery_ui.install,v
retrieving revision 1.5.2.2
diff -u -p -r1.5.2.2 jquery_ui.install
--- jquery_ui.install	21 Jun 2009 03:43:03 -0000	1.5.2.2
+++ jquery_ui.install	26 Dec 2009 22:08:19 -0000
@@ -14,11 +14,9 @@ function jquery_ui_requirements($phase) 
   $t = get_t();
   $jquery_ui_version = 0;
 
-  if ($phase == 'install') {
-    // The jquery_ui_get_version() function is in the .module file, which isn't
-    // loaded yet.
-    include_once dirname(__FILE__) . '/jquery_ui.module';
-  }
+  // Ensure the Libraries API module is loaded.
+  drupal_load('module', 'libraries');
+  drupal_load('module', 'jquery_ui');
 
   $requirements['jquery_ui']['title'] = $t('jQuery UI');
   if ($jquery_ui_version = jquery_ui_get_version()) {
Index: jquery_ui.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/jquery_ui/jquery_ui.module,v
retrieving revision 1.6.2.2
diff -u -p -r1.6.2.2 jquery_ui.module
--- jquery_ui.module	21 Jun 2009 03:43:03 -0000	1.6.2.2
+++ jquery_ui.module	26 Dec 2009 22:08:19 -0000
@@ -11,20 +11,6 @@
  */
 
 /**
- * Path to jQuery UI library.
- *
- * During site installation, JQUERY_UI_PATH is the absolute path to the
- * jQuery UI library.  At all other times JQUERY_UI_PATH is relative, and
- * safe for use in URLs.
- */
-if (defined('MAINTENANCE_MODE') && MAINTENANCE_MODE == 'install') {
-  define('JQUERY_UI_PATH', dirname(__FILE__) . '/jquery.ui');
-}
-else {
-  define('JQUERY_UI_PATH', drupal_get_path('module', 'jquery_ui') . '/jquery.ui');
-}
-
-/**
  * Add the specified jQuery UI library files to this page.
  *
  * The ui.core file is always included automatically, as well as the
@@ -36,7 +22,7 @@ else {
  */
 function jquery_ui_add($files = array()) {
   static $loaded_files, $ui_core, $effects_core;
-  $jquery_ui_path = JQUERY_UI_PATH . '/ui';
+  $jquery_ui_path = libraries_get_path('jquery.ui') . '/ui';
   $compression = variable_get('jquery_update_compression_type', 'mini');
 
   // Convert file to an array if it's not one already, to compensate for
@@ -88,8 +74,9 @@ function jquery_ui_add($files = array())
 function jquery_ui_get_version() {
   $version = 0;
 
-  if (file_exists(JQUERY_UI_PATH . '/version.txt')) {
-    $version = file_get_contents(JQUERY_UI_PATH . '/version.txt');
+  $version_file = libraries_get_path('jquery.ui') . '/version.txt';
+  if (file_exists($version_file)) {
+    $version = file_get_contents($version_file);
   }
 
   return $version;
