? .DS_Store ? ctools_d7.patch Index: ctools_plugin_example/ctools_plugin_example.pages_default.inc =================================================================== RCS file: /cvs/drupal/contributions/modules/ctools/ctools_plugin_example/ctools_plugin_example.pages_default.inc,v retrieving revision 1.1 diff -u -p -r1.1 ctools_plugin_example.pages_default.inc --- ctools_plugin_example/ctools_plugin_example.pages_default.inc 17 Aug 2009 22:07:14 -0000 1.1 +++ ctools_plugin_example/ctools_plugin_example.pages_default.inc 20 Oct 2009 02:28:30 -0000 @@ -69,7 +69,6 @@ function ctools_plugin_example_default_p $handler->weight = 0; $handler->conf = array( 'title' => 'Panel', - 'no_blocks' => FALSE, 'css_id' => '', 'css' => '', 'contexts' => array( @@ -377,7 +376,6 @@ function ctools_plugin_example_default_p $handler->weight = 0; $handler->conf = array( 'title' => 'Panel', - 'no_blocks' => FALSE, 'css_id' => '', 'css' => '', 'contexts' => array(), Index: ctools_plugin_example/plugins/panels.pages.inc =================================================================== RCS file: /cvs/drupal/contributions/modules/ctools/ctools_plugin_example/plugins/panels.pages.inc,v retrieving revision 1.3 diff -u -p -r1.3 panels.pages.inc --- ctools_plugin_example/plugins/panels.pages.inc 17 Oct 2009 22:58:26 -0000 1.3 +++ ctools_plugin_example/plugins/panels.pages.inc 20 Oct 2009 02:28:30 -0000 @@ -40,7 +40,6 @@ function ctools_plugin_example_default_p 'keyword' => 'relcontext', ), ); - $page->no_blocks = '0'; $page->switcher_options = array(); $page->menu = '0'; $page->contexts = array(); Index: includes/context-task-handler.inc =================================================================== RCS file: /cvs/drupal/contributions/modules/ctools/includes/context-task-handler.inc,v retrieving revision 1.26 diff -u -p -r1.26 context-task-handler.inc --- includes/context-task-handler.inc 17 Oct 2009 22:58:25 -0000 1.26 +++ includes/context-task-handler.inc 20 Oct 2009 02:28:30 -0000 @@ -90,14 +90,7 @@ function ctools_context_handler_render($ drupal_set_title($info['title']); } - // Only directly output if $page was set to true. - if (!empty($info['no_blocks'])) { - print theme('page', $info['content'], FALSE); - return; - } - else { - return $info['content']; - } + return $info['content']; } } } Index: includes/menu.inc =================================================================== RCS file: /cvs/drupal/contributions/modules/ctools/includes/menu.inc,v retrieving revision 1.5 diff -u -p -r1.5 menu.inc --- includes/menu.inc 17 Oct 2009 22:58:25 -0000 1.5 +++ includes/menu.inc 20 Oct 2009 02:28:30 -0000 @@ -449,17 +449,15 @@ function ctools_menu_get_active_help() { $arg = drupal_help_arg(arg(NULL)); $empty_arg = drupal_help_arg(); - foreach (module_list() as $name) { - if (module_hook($name, 'help')) { - // Lookup help for this path. - if ($help = module_invoke($name, 'help', $router_path, $arg)) { - $output .= $help ."\n"; - } - // Add "more help" link on admin pages if the module provides a - // standalone help page. - if ($arg[0] == "admin" && module_exists('help') && module_invoke($name, 'help', 'admin/help#'. $arg[2], $empty_arg) && $help) { - $output .= theme("more_help_link", url('admin/help/'. $arg[2])); - } + foreach (module_implements('help') as $name) { + // Lookup help for this path. + if ($help = module_invoke($name, 'help', $router_path, $arg)) { + $output .= $help ."\n"; + } + // Add "more help" link on admin pages if the module provides a + // standalone help page. + if ($arg[0] == "admin" && module_exists('help') && module_invoke($name, 'help', 'admin/help#'. $arg[2], $empty_arg) && $help) { + $output .= theme("more_help_link", url('admin/help/'. $arg[2])); } } return $output; Index: includes/plugins.inc =================================================================== RCS file: /cvs/drupal/contributions/modules/ctools/includes/plugins.inc,v retrieving revision 1.22 diff -u -p -r1.22 plugins.inc --- includes/plugins.inc 17 Oct 2009 22:58:25 -0000 1.22 +++ includes/plugins.inc 20 Oct 2009 02:28:30 -0000 @@ -112,9 +112,9 @@ function ctools_plugin_api_include($owne if (!isset($plugin_info['file'])) { $plugin_info['file'] = "$module.$api.inc"; } - if (file_exists("./$plugin_info[path]/$plugin_info[file]")) { + if (file_exists(DRUPAL_ROOT . "/$plugin_info[path]/$plugin_info[file]")) { $plugin_info[$module]['included'] = TRUE; - require_once "./$plugin_info[path]/$plugin_info[file]"; + require_once DRUPAL_ROOT . "/$plugin_info[path]/$plugin_info[file]"; } $info[$module] = $plugin_info; } Index: js/collapsible-div.js =================================================================== RCS file: /cvs/drupal/contributions/modules/ctools/js/collapsible-div.js,v retrieving revision 1.9 diff -u -p -r1.9 collapsible-div.js --- js/collapsible-div.js 12 Oct 2009 12:42:53 -0000 1.9 +++ js/collapsible-div.js 20 Oct 2009 02:28:30 -0000 @@ -230,9 +230,11 @@ /** * Support Drupal's 'behaviors' system for binding. */ - Drupal.behaviors.CToolsCollapsible = function(context) { - $('.ctools-collapsible-container:not(.ctools-collapsible-processed)', context) - .each(Drupal.CTools.bindCollapsible) - .addClass('ctools-collapsible-processed'); - } + Drupal.behaviors.CToolsCollapsible = { + attach: function(context) { + $('.ctools-collapsible-container:not(.ctools-collapsible-processed)', context) + .each(Drupal.CTools.bindCollapsible) + .addClass('ctools-collapsible-processed'); + } + }; })(jQuery); Index: js/dependent.js =================================================================== RCS file: /cvs/drupal/contributions/modules/ctools/js/dependent.js,v retrieving revision 1.6 diff -u -p -r1.6 dependent.js --- js/dependent.js 12 Oct 2009 12:42:53 -0000 1.6 +++ js/dependent.js 20 Oct 2009 02:28:30 -0000 @@ -180,23 +180,25 @@ } } - Drupal.behaviors.CToolsDependent = function (context) { - Drupal.CTools.dependent.autoAttach(); + Drupal.behaviors.CToolsDependent = { + attach: function (context) { + Drupal.CTools.dependent.autoAttach(); - // Really large sets of fields are too slow with the above method, so this - // is a sort of hacked one that's faster but much less flexible. - $("select.ctools-master-dependent:not(.ctools-processed)") - .addClass('ctools-processed') - .change(function() { - var val = $(this).val(); - if (val == 'all') { - $('.ctools-dependent-all').show(0); - } - else { - $('.ctools-dependent-all').hide(0); - $('.ctools-dependent-' + val).show(0); - } - }) - .trigger('change'); - } + // Really large sets of fields are too slow with the above method, so this + // is a sort of hacked one that's faster but much less flexible. + $("select.ctools-master-dependent:not(.ctools-processed)") + .addClass('ctools-processed') + .change(function() { + var val = $(this).val(); + if (val == 'all') { + $('.ctools-dependent-all').show(0); + } + else { + $('.ctools-dependent-all').hide(0); + $('.ctools-dependent-' + val).show(0); + } + }) + .trigger('change'); + } + }; })(jQuery); Index: js/dropdown.js =================================================================== RCS file: /cvs/drupal/contributions/modules/ctools/js/dropdown.js,v retrieving revision 1.5 diff -u -p -r1.5 dropdown.js --- js/dropdown.js 12 Oct 2009 12:42:53 -0000 1.5 +++ js/dropdown.js 20 Oct 2009 02:28:31 -0000 @@ -23,64 +23,66 @@ */ (function ($) { - Drupal.behaviors.CToolsDropdown = function() { - $('div.ctools-dropdown:not(.ctools-dropdown-processed)') - .removeClass('ctools-dropdown-no-js') - .addClass('ctools-dropdown-processed') - .each(function() { - var $dropdown = $(this); - var open = false; - var hovering = false; - var timerID = 0; - - var toggle = function(close) { - // if it's open or we're told to close it, close it. - if (open || close) { - // If we're just toggling it, close it immediately. - if (!close) { - open = false; - $("div.ctools-dropdown-container", $dropdown).slideUp(100); + Drupal.behaviors.CToolsDropdown = { + attach: function() { + $('div.ctools-dropdown:not(.ctools-dropdown-processed)') + .removeClass('ctools-dropdown-no-js') + .addClass('ctools-dropdown-processed') + .each(function() { + var $dropdown = $(this); + var open = false; + var hovering = false; + var timerID = 0; + + var toggle = function(close) { + // if it's open or we're told to close it, close it. + if (open || close) { + // If we're just toggling it, close it immediately. + if (!close) { + open = false; + $("div.ctools-dropdown-container", $dropdown).slideUp(100); + } + else { + // If we were told to close it, wait half a second to make + // sure that's what the user wanted. + // Clear any previous timer we were using. + if (timerID) { + clearTimeout(timerID); + } + timerID = setTimeout(function() { + if (!hovering) { + open = false; + $("div.ctools-dropdown-container", $dropdown).slideUp(100); + }}, 500); + } } else { - // If we were told to close it, wait half a second to make - // sure that's what the user wanted. - // Clear any previous timer we were using. - if (timerID) { - clearTimeout(timerID); - } - timerID = setTimeout(function() { - if (!hovering) { - open = false; - $("div.ctools-dropdown-container", $dropdown).slideUp(100); - }}, 500); + // open it. + open = true; + $("div.ctools-dropdown-container", $dropdown) + .animate({height: "show", opacity: "show"}, 100); } } - else { - // open it. - open = true; - $("div.ctools-dropdown-container", $dropdown) - .animate({height: "show", opacity: "show"}, 100); - } - } - $("a.ctools-dropdown-link", $dropdown).click(function() { - toggle(); - return false; - }); - - $dropdown.hover( - function() { - hovering = true; - }, // hover in - function() { // hover out - hovering = false; - toggle(true); - return false; - }); - // @todo -- just use CSS for this noise. - $("div.ctools-dropdown-container a").hover( - function() { $(this).addClass('ctools-dropdown-hover'); }, - function() { $(this).removeClass('ctools-dropdown-hover'); } - ); - }); + $("a.ctools-dropdown-link", $dropdown).click(function() { + toggle(); + return false; + }); + + $dropdown.hover( + function() { + hovering = true; + }, // hover in + function() { // hover out + hovering = false; + toggle(true); + return false; + }); + // @todo -- just use CSS for this noise. + $("div.ctools-dropdown-container a").hover( + function() { $(this).addClass('ctools-dropdown-hover'); }, + function() { $(this).removeClass('ctools-dropdown-hover'); } + ); + }); + } }; })(jQuery); Index: js/modal.js =================================================================== RCS file: /cvs/drupal/contributions/modules/ctools/js/modal.js,v retrieving revision 1.20 diff -u -p -r1.20 modal.js --- js/modal.js 13 Oct 2009 20:06:56 -0000 1.20 +++ js/modal.js 20 Oct 2009 02:28:31 -0000 @@ -189,39 +189,41 @@ /** * Bind links that will open modals to the appropriate function. */ - Drupal.behaviors.CToolsModal = function(context) { - // Bind links - $('a.ctools-use-modal:not(.ctools-use-modal-processed)', context) - .addClass('ctools-use-modal-processed') - .click(Drupal.CTools.Modal.clickAjaxLink); - - // Bind buttons - $('input.ctools-use-modal:not(.ctools-use-modal-processed), button.ctools-use-modal:not(.ctools-use-modal-processed)', context) - .addClass('ctools-use-modal-processed') - .click(Drupal.CTools.Modal.clickAjaxButton); - - if ($(context).attr('id') == 'modal-content') { - // Bind submit links in the modal form. - $('form:not(.ctools-use-modal-processed)', context) + Drupal.behaviors.CToolsModal = { + attach: function(context) { + // Bind links + $('a.ctools-use-modal:not(.ctools-use-modal-processed)', context) .addClass('ctools-use-modal-processed') - .submit(Drupal.CTools.Modal.submitAjaxForm); - // add click handlers so that we can tell which button was clicked, - // because the AJAX submit does not set the values properly. - - $('input[type="submit"]:not(.ctools-use-modal-processed), button:not(.ctools-use-modal-processed)', context) + .click(Drupal.CTools.Modal.clickAjaxLink); + + // Bind buttons + $('input.ctools-use-modal:not(.ctools-use-modal-processed), button.ctools-use-modal:not(.ctools-use-modal-processed)', context) .addClass('ctools-use-modal-processed') - .click(function() { - if (Drupal.autocompleteSubmit && !Drupal.autocompleteSubmit()) { - return false; - } - - // Make sure it knows our button. - if (!$(this.form).hasClass('ctools-ajaxing')) { - this.form.clk = this; - $(this).after('