#1229352 by Les Lim: Load addthis_widget.js from the footer to work around a bug...
[project/addthis.git] / addthis.views.inc
1 <?php
2
3 /**
4 * @file
5 * Provide views data and handlers for addthis.module
6 */
7
8 /**
9 * Implementation of hook_views_data().
10 */
11 function addthis_views_data() {
12 // We're registering the 'custom_teasers' table.
13 $data['node']['addthis_button'] = array(
14 'title' => t('AddThis button'),
15 'help' => t('An AddThis button, associated with this node.'),
16 'field' => array(
17 'handler' => 'addthis_handler_field_button',
18 ),
19 );
20 $data['node']['addthis_toolbox'] = array(
21 'title' => t('AddThis toolbox'),
22 'help' => t('An AddThis toolbox, associated with this node.'),
23 'field' => array(
24 'handler' => 'addthis_handler_field_toolbox',
25 ),
26 );
27 return $data;
28 }
29
30 /**
31 * Implementation of hook_views_handlers().
32 */
33 function addthis_views_handlers() {
34 return array(
35 'info' => array(
36 'path' => drupal_get_path('module', 'addthis'),
37 ),
38 'handlers' => array(
39 'addthis_handler_field_button' => array(
40 'parent' => 'views_handler_field',
41 'file' => 'addthis_handler_field.inc',
42 ),
43 'addthis_handler_field_toolbox' => array(
44 'parent' => 'views_handler_field',
45 'file' => 'addthis_handler_field.inc',
46 ),
47 ),
48 );
49 }