add contents
This commit is contained in:
40
lib/plugins/odt/MenuItemODTPDF.php
Normal file
40
lib/plugins/odt/MenuItemODTPDF.php
Normal file
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
|
||||
namespace dokuwiki\plugin\odt;
|
||||
|
||||
use dokuwiki\Menu\Item\AbstractItem;
|
||||
|
||||
/**
|
||||
* Class MenuItemODT
|
||||
*
|
||||
* Implements the ODT export button for DokuWiki's menu system
|
||||
*
|
||||
* @package dokuwiki\plugin\odt
|
||||
*/
|
||||
class MenuItemODTPDF extends AbstractItem {
|
||||
|
||||
/** @var string do action for this plugin */
|
||||
protected $type = 'export_odt_pdf';
|
||||
|
||||
/** @var string icon file */
|
||||
protected $svg = DOKU_INC . 'lib/plugins/odt/menu-odt-pdf.svg';
|
||||
|
||||
/**
|
||||
* MenuItem constructor.
|
||||
*/
|
||||
public function __construct() {
|
||||
parent::__construct();
|
||||
global $REV;
|
||||
if($REV) $this->params['rev'] = $REV;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get label from plugin language file
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getLabel() {
|
||||
$hlp = plugin_load('action', 'odt_export');
|
||||
return $hlp->getLang('export_odt_pdf_button');
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user