40 lines
777 B
PHP
40 lines
777 B
PHP
<?php
|
|
/**
|
|
* @brief entryPhotoExifWidget, a plugin for Dotclear 2
|
|
*
|
|
* @package Dotclear
|
|
* @subpackage Plugin
|
|
*
|
|
* @author Jean-Christian Denis and contibutors
|
|
*
|
|
* @copyright Jean-Christian Denis
|
|
* @copyright GPL-2.0 https://www.gnu.org/licenses/gpl-2.0.html
|
|
*/
|
|
declare(strict_types=1);
|
|
|
|
namespace Dotclear\Plugin\entryPhotoExifWidget;
|
|
|
|
use dcCore;
|
|
use dcNsProcess;
|
|
|
|
class Backend extends dcNsProcess
|
|
{
|
|
public static function init(): bool
|
|
{
|
|
static::$init = defined('DC_CONTEXT_ADMIN');
|
|
|
|
return static::$init;
|
|
}
|
|
|
|
public static function process(): bool
|
|
{
|
|
if (!static::$init) {
|
|
return false;
|
|
}
|
|
|
|
dcCore::app()->addBehavior('initWidgets', [Widgets::class, 'initWidgets']);
|
|
|
|
return true;
|
|
}
|
|
}
|