<?php 

defined('C5_EXECUTE') or die("Access Denied.");

class AddonsListBlockController extends BlockController
{

	protected $btTable = "btAddonsList";
	protected $btInterfaceWidth = "420";
	protected $btInterfaceHeight = "200";
	protected $btCacheBlockOutput = true;
	protected $btCacheBlockOutputOnPost = true;
	protected $btCacheBlockOutputForRegisteredUsers = true;

	public function getBlockTypeDescription()
	{
		return t("Create a list of installed packages with their icons");
	}

	public function getBlockTypeName()
	{
		return t("Addons List");
	}

	public function save($args)
	{
		$boolKeys = array( 'showIcons', 'showNames', 'linkToMarketplace' );
		foreach ( $boolKeys as $key )
		{
			if ( !isset( $args[$key] ) ) $args[$key] = 0;
		}

		parent::save($args);
	}
}

// vim: set noexpandtab ts=4 :
