<?php
/*
sudo apt-get install libemail-outlook-message-perl
sudo apt-get install php-mailparse
sudo apachectl restart
*/

use FileRun\Files\Plugin;

class custom_email_viewer extends Plugin {

	static $localeSection = "Custom Actions: Message Viewer";

	function init() {

		$this->JSconfig = [
			"title" => self::t('Message Viewer'),
			'iconCls' => 'fa-envelope-o',
			'extensions' => ['msg', 'eml'],
			'popup' => true,
			'requiredUserPerms' => ['download'],
			'requires' => ['download']
		];
	}

	function run() {
		require $this->path."/display.php";
	}
}