summaryrefslogtreecommitdiff
path: root/modules/shortcut
diff options
context:
space:
mode:
Diffstat (limited to 'modules/shortcut')
-rw-r--r--modules/shortcut/shortcut.admin.js10
-rw-r--r--modules/shortcut/shortcut.module2
2 files changed, 6 insertions, 6 deletions
diff --git a/modules/shortcut/shortcut.admin.js b/modules/shortcut/shortcut.admin.js
index 453a40231..5554e5a7c 100644
--- a/modules/shortcut/shortcut.admin.js
+++ b/modules/shortcut/shortcut.admin.js
@@ -52,7 +52,7 @@ Drupal.behaviors.shortcutDrag = {
// status to be disabled and mark it also as changed.
var changedRowObject = new tableDrag.row(changedRow, 'mouse', self.indentEnabled, self.maxDepth, true);
changedRowObject.markChanged();
- rowStatusChange(changedRowObject);
+ tableDrag.rowStatusChange(changedRowObject);
}
}
else if (total != visibleLength) {
@@ -71,18 +71,18 @@ Drupal.behaviors.shortcutDrag = {
// Add a handler so when a row is dropped, update fields dropped into new regions.
tableDrag.onDrop = function () {
- rowStatusChange(this.rowObject);
+ tableDrag.rowStatusChange(this.rowObject);
return true;
};
- function rowStatusChange(rowObject) {
+ tableDrag.rowStatusChange = function (rowObject) {
// Use "status-message" row instead of "status" row because
// "status-{status_name}-message" is less prone to regexp match errors.
var statusRow = $(rowObject.element).prevAll('tr.shortcut-status').get(0);
var statusName = statusRow.className.replace(/([^ ]+[ ]+)*shortcut-status-([^ ]+)([ ]+[^ ]+)*/, '$2');
var statusField = $('select.shortcut-status-select', rowObject.element);
statusField.val(statusName);
- }
+ };
tableDrag.restripeTable = function () {
// :even and :odd are reversed because jQuery counts from 0 and
@@ -106,7 +106,7 @@ Drupal.behaviors.shortcutDrag = {
Drupal.behaviors.newSet = {
attach: function (context, settings) {
var selectDefault = function() {
- $($(this).parents('div.form-item').get(1)).find('> label > input').attr('checked', 'checked');
+ $(this).closest('form').find('.form-item-set .form-type-radio:last input').attr('checked', 'checked');
};
$('div.form-item-new input').focus(selectDefault).keyup(selectDefault);
}
diff --git a/modules/shortcut/shortcut.module b/modules/shortcut/shortcut.module
index f8ddcc24f..4c67a1416 100644
--- a/modules/shortcut/shortcut.module
+++ b/modules/shortcut/shortcut.module
@@ -22,7 +22,7 @@ function shortcut_help($path, $arg) {
switch ($path) {
case 'admin/help#shortcut':
$output = '<h3>' . t('About') . '</h3>';
- $output .= '<p>' . t('The Shortcut module allows users to create sets of <em>shortcut</em> links to commonly-visited pages of the site. Shortcuts are contained within <em>sets</em>. Each user with <em>Select any shortcut set</em> permission can select a shortcut set created by anyone at the site. For more information, see the online handbook entry for <a href="@shortcut">Shortcut module</a>.', array('@shortcut' => 'http://drupal.org/handbook/modules/shortcut/')) . '</p>';
+ $output .= '<p>' . t('The Shortcut module allows users to create sets of <em>shortcut</em> links to commonly-visited pages of the site. Shortcuts are contained within <em>sets</em>. Each user with <em>Select any shortcut set</em> permission can select a shortcut set created by anyone at the site. For more information, see the online handbook entry for <a href="@shortcut">Shortcut module</a>.', array('@shortcut' => 'http://drupal.org/documentation/modules/shortcut/')) . '</p>';
$output .= '<h3>' . t('Uses') . '</h3>';
$output .= '<dl><dt>' . t('Administering shortcuts') . '</dt>';
$output .= '<dd>' . t('Users with the <em>Administer shortcuts</em> permission can manage shortcut sets and edit the shortcuts within sets from the <a href="@shortcuts">Shortcuts administration page</a>.', array('@shortcuts' => url('admin/config/user-interface/shortcut'))) . '</dd>';