Keystrokes module: brainstorming

We encourage users to post events happening in the community to the community events group on https://www.drupal.org.
stefano73's picture

I'm working on a module that implements site-wide keystrokes. Keystrokes may execute specific actions on the site, like clear cache, show logs, etc... The reference is this project: http://rikrikrik.com/jquery/shortkeys/), and comments written here http://groups.drupal.org/node/1592#comment-5721 and below.

The initial release of this module simply shows javascript alert when you press specific keys on your keyboard. It sends an Ajax GET request and returns an output to the user.

This can be widely extended, defining more complex actions in the module itself, and also collecting more keystrokes/actions from other modules. The integration with other modules should be done with a hook_keystrokes() (in the module itself or a separate include). The functions called through keystrokes should be adapted for a keystroke call, without printing output or redirects. Those functions should have a proper status message that confirms the correct execution, and the theme should have a readily available div to display that message in the current page.

I'm also thinking about three user shells:
- a common shell, with basic site-wide actions, available for all users having the "access user keystrokes" permission;
- a personal shell, where users can customize keystrokes for the listed actions, available for all users having the "edit own keystrokes" permission;
- an admin shell, with admin actions, available for all users having the "access admin keystrokes" permission;

Users may also disabled shells, in case they don't need keystrokes.

If anyone is interested in this topic, please post your thoughts here.