# Copyright (c) 2002-2007 Infrae. All rights reserved.
# See also LICENSE.txt
# $Revision: 1.23 $

import content
import codesource

from Products.Silva.fssite import registerDirectory
from Products.Silva.ExtensionRegistry import extensionRegistry
#from Products.Silva.upgrade import upgrade_registry
from Products.SilvaMetadata.Compatibility import registerTypeForMetadata
import install

from Products.SilvaExternalSources import ExternalSource
import os

from AccessControl import allow_module

here = os.path.abspath(os.path.dirname(__file__))

def initialize(context):
    registerDirectory('views', globals())

    context.registerClass(
        codesource.MailingSubscriptionForm,
        constructors = (codesource.manage_addMailingSubscriptionFormForm,
                        codesource.manage_addMailingSubscriptionForm),
        icon = os.path.join(os.path.join(here, 'www', 'codesource.png')),
    )

allow_module('Products.SilvaMailing.i18n')
