? LICENSE.txt
Index: drupal_tweaks.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/drupal_tweaks/Attic/drupal_tweaks.module,v
retrieving revision 1.1.2.35
diff -r1.1.2.35 drupal_tweaks.module
259a260,267
>   $items['admin/drupal_tweaks/autocomplete/filter_modules'] = array(
>     'title' => 'Filter the module.',
>     'page callback' => 'drupal_tweaks_filter_modules',
>     'access callback' => 'user_access',
>     'access arguments' => array('administer drupal_tweaks'),
>     'type' => MENU_CALLBACK,
>     'file' => 'includes/drupal_tweaks.ajax.inc',
>   );
Index: includes/drupal_tweaks.admin.modules.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/drupal_tweaks/includes/Attic/drupal_tweaks.admin.modules.inc,v
retrieving revision 1.1.2.5
diff -r1.1.2.5 drupal_tweaks.admin.modules.inc
69a70,162
>   $form['filters']['current'][] = array(
>      '#type' => 'textfield',
>      '#title' => t('Name contains'),
>      '#attributes' => array(
>       //'onkeydown' => "return filter_modules(this, event);",
>       'onkeyup' => "return filter_modules_keyup(this, event);",
>       'onblur' => "return filter_modules_blur(this);"
>       ),
>      '#description' => t('Type part of module name.'),
>      //'#autocomplete_path' => 'admin/drupal_tweaks/autocomplete/filter_modules',
>      '#size' => 30,
>      '#maxlength' => 60,
>    );
> 
>   $js_code = "
>         function filter_modules_blur(input)
>         {
>             if (input.value.length > 0)
>                 find_mod_matches(input.value);
>             else
>                 set_mod_matches('table-row');
>         }
> 
>         function filter_modules_keyup(input, e)
>         {
>             if (!e) {
>                 e = window.event;
>             }
>             switch (e.keyCode) {
>                 case 16: // shift
>                 case 17: // ctrl
>                 case 18: // alt
>                 case 20: // caps lock
>                 case 33: // page up
>                 case 34: // page down
>                 case 35: // end
>                 case 36: // home
>                 case 37: // left arrow
>                 case 38: // up arrow
>                 case 39: // right arrow
>                 case 40: // down arrow
>                 case 9:  // tab
>                 case 13: // enter
>                 case 27: // esc
>                     return true;
> 
>                 default: // all other keys
>                     if (input.value.length > 0)
>                         find_mod_matches(input.value);
>                     else
>                         set_mod_matches('table-row');
>                     return true;
>             }
>         }
> 
>         function set_mod_matches(display)
>         {
>             $('tbody').children('tr').each(function() {
>                 $(this).css('display', display);
>             });
>         }
> 
>         var timer = null;
> 
>         function find_mod_matches(value)
>         {
>             if (this.timer) {
>                 clearTimeout(this.timer);
>             }
>             this.timer = setTimeout(function() {
>                 $.ajax({
>                     type: 'GET',
>                     url: '". check_url(url("admin/drupal_tweaks/autocomplete/filter_modules/", array('absolute' => TRUE))) ."' + value,
>                     dataType: 'json',
>                     success: function (matches) {
>                         set_mod_matches('none');
> 
>                         $.each(matches, function(index, value) {
>                           if($( '#' + value ).length)
>                              $( '#' + value ).parent().parent().css('display', 'table-row');
>                         });
>                     },
>                     error: function (xmlhttp) {
>                         alert(Drupal.ahahError(xmlhttp, 'URL'));
>                     }
>                 });
> 
>             }, 500);
>         }
>         ";
> 
>   drupal_add_js($js_code, 'inline');
> 
137a231
> 
160c254
<     $form['raw_name'][$module->name] =  array('#value' => $module->name);
---
>     $form['raw_name'][$module->name] =  array('#value' => $module->name, "#prefix" => '<div id="'. $module->name .'">', "#suffix" => "</div>");
168c262
<   $form['pager'] = array('#value' => theme('pager', NULL, 50, 0));
---
>   //$form['pager'] = array('#value' => theme('pager', NULL, 50, 0));
Index: includes/drupal_tweaks.ajax.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/drupal_tweaks/includes/Attic/drupal_tweaks.ajax.inc,v
retrieving revision 1.1.2.4
diff -r1.1.2.4 drupal_tweaks.ajax.inc
31a32,46
> function drupal_tweaks_filter_modules($string = '')
> {
>   $matches = array();
>   if ($string) {
>     $result = db_query_range("SELECT name, info FROM {system} WHERE type = 'module'", 0, 10000);
>     while ($row = db_fetch_object($result)) {
>       $info = unserialize($row->info);
>       if( !(strpos(strtolower($info['name']), strtolower($string)) === false) )
>         $matches[] = check_plain($row->name);
>     }
>   }
>   
>   drupal_json($matches);
> }
> 
