summaryrefslogtreecommitdiffstats
path: root/plugins/55/edittable/action/jsinfo.php
blob: de80c4fe038e8aba46ea0a07cfc9221789aa9f0c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<?php

/**
 * handles the data that has to be written into jsinfo
 *
 * like displaying the editor and adding custom edit buttons
 */
class action_plugin_edittable_jsinfo extends DokuWiki_Action_Plugin
{
    /**
     * Register its handlers with the DokuWiki's event controller
     */
    public function register(Doku_Event_Handler $controller)
    {
        // register custom edit buttons
        $controller->register_hook('DOKUWIKI_STARTED', 'BEFORE', $this, 'fill_jsinfo');
    }

    public function fill_jsinfo()
    {
        global $JSINFO;
        $JSINFO['plugins']['edittable']['default columnwidth'] = $this->getConf('default colwidth');
    }
}