Skip to content

Commit 1fba49d

Browse files
author
Brendon
committed
* Documentation fixes
1 parent 8b277c1 commit 1fba49d

File tree

3 files changed

+38
-3
lines changed

3 files changed

+38
-3
lines changed

README

Lines changed: 28 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
##
44

55
Author: Brendon Crawford
6-
Date: 2008-12-21
6+
Date: 2009-01-11
77
Homepage: http://drupal.org/project/ajax
88
IRC: irc://freenode.net/#drupy
99

@@ -49,7 +49,7 @@
4949
messages appear at the top of the form near-instantaniously.
5050

5151
##
52-
## DEVELOPERS
52+
## DEVELOPERS: PHP API
5353
##
5454

5555
The AJAX Forms module will properly handle MOST forms out of the box. If,
@@ -101,6 +101,32 @@
101101
For more developer information, please see the example AJAX Forms plugins
102102
which are provided in the "ajax/plugins" directory.
103103

104+
##
105+
## Developers: JavaScript API
106+
##
107+
108+
The Ajax Forms JavaScript plugin provides the following plugin callbacks(s):
109+
110+
Drupal.Ajax.plugins.FOO(hook, args)
111+
112+
Where FOO is the name of your plugin.
113+
114+
hook String
115+
A Drupal form object
116+
args Assoc/Object
117+
A keyed object/associative-array of args which are specific to this hook.
118+
119+
hook can be one of:
120+
121+
scrollFind
122+
Executes as window scrolls up after Ajax response.
123+
init
124+
On page load.
125+
126+
For Ajax Forms plugins usage examples, please see the "thickbox" and
127+
"tinymce" plugins which are provided with the Ajax Forms module in the
128+
"ajax/plugins" directory.
129+
104130
##
105131
## NOTES
106132
##

plugins/thickbox/ajax_thickbox.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,13 @@
1616
*
1717
*/
1818

19+
/**
20+
* Ajax Forms plugin for thickbox
21+
*
22+
* @param {String} hook
23+
* @param {Object} args
24+
* @return {Bool}
25+
*/
1926
Drupal.Ajax.plugins.thickbox = function(hook, args) {
2027
var tb_init_original;
2128
if (hook === 'scrollFind') {

plugins/tinymce/ajax_tinymce.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,10 @@
1010
*/
1111

1212
/**
13-
* TinyMCE Trigger
13+
* Ajax Forms plugin for tinymce
1414
*
15+
* @param {String} hook
16+
* @param {Object} args
1517
* @return {Bool}
1618
*/
1719
Drupal.Ajax.plugins.tinyMCE = function(hook, args) {

0 commit comments

Comments
 (0)