Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

49 lines (45 sloc) 1.665 kb
<?php
// $Id$
function jquery_hotkeys_schema() {
$schema['jquery_hotkeys'] = array(
'description' => 'A list of jQuery Hotkey bindings',
'fields' => array(
'jhid' => array(
'description' => 'Primary ID for a hotkey setup',
'type' => 'serial',
'unsigned' => TRUE,
'not null' => TRUE),
'visibility' => array(
'description' => 'How the pages attribute will be interpreted',
'type' => 'int',
'size' => 'tiny'),
'name' => array(
'description' => 'Identifier for this hotkey',
'type' => 'varchar',
'length' => '128'),
'hotkey' => array(
'description' => 'The activation hotkey',
'type' => 'varchar',
'length' => '16'),
'javascript' => array(
'description' => 'JavaScript code to be executed for this hotkey',
'type' => 'text',
'size' => 'normal'),
'pages' => array(
'description' => 'Pages to be matched against to determine application of this hotkey',
'type' => 'text',
'size' => 'normal')
),
'primary key' => array('jhid')
);
return $schema;
}
function jquery_hotkeys_install() {
drupal_install_schema('jquery_hotkeys');
}
function jquery_hotkeys_enable() {
drupal_set_message(t('jQuery hotkeys installed. Please <a href="@perms">set permissions</a> and view the <a href="@settings">configuration settings</a>.', array('@perms' => url('admin/user/permissions',array('fragment' => 'module-jquery-hotkeys')), '@settings' => url('admin/settings/jquery_hotkeys'))));
}
function jquery_hotkeys_uninstall() {
drupal_uninstall_schema('jquery_hotkeys');
}
Jump to Line
Something went wrong with that request. Please try again.