# Copyright (c) 2007 gocept gmbh & co. kg
# See also LICENSE.txt
# $Id$

import zope.formlib.form

import zeit.cms.browser.form
import zeit.cms.syndication.feed
import zeit.cms.syndication.interfaces


class FeedFormBase(object):
    pass


class AddForm(FeedFormBase, zeit.cms.browser.form.AddForm):

    form_fields = (
        zope.formlib.form.Fields(
            zeit.cms.interfaces.ICMSContent,
            omit_readonly=False).omit('uniqueId') +
        zope.formlib.form.Fields(
            zeit.cms.syndication.interfaces.IFeed))


    def create(self, data):
        return zeit.cms.syndication.feed.Feed(**data)


class EditForm(FeedFormBase, zeit.cms.browser.form.EditForm):

    form_fields = zope.formlib.form.Fields(
        zeit.cms.syndication.interfaces.IFeed,
        render_context=True)

@@ -193,16 +193,63 @@
 erfaces%0A
+from zeit.cms.i18n import MessageFactory as _%0A%0A
 %0A%0Aclass 
@@ -334,32 +334,62 @@
 form.AddForm):%0A%0A
+    title = _(%22Add Channel%22)%0A%0A
     form_fields 
@@ -754,24 +754,55 @@
 EditForm):%0A%0A
+    title = _(%22Edit Channel%22)%0A%0A
     form_fie

set tile for feed forms (alled it channel)