Moved viewlet manager interface to PyAMS default theme
authorThierry Florac <thierry.florac@onf.fr>
Thu, 03 Jan 2019 15:30:15 +0100
changeset 1204 4eaa52289a1a
parent 1203 4537690c026b
child 1205 e5f1d2e240ff
Moved viewlet manager interface to PyAMS default theme
src/pyams_content/shared/common/portlet/interfaces.py
src/pyams_content/shared/common/portlet/interfaces/__init__.py
src/pyams_content/shared/common/portlet/skin/__init__.py
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/pyams_content/shared/common/portlet/interfaces.py	Thu Jan 03 15:30:15 2019 +0100
@@ -0,0 +1,48 @@
+#
+# Copyright (c) 2008-2017 Thierry Florac <tflorac AT ulthar.net>
+# All Rights Reserved.
+#
+# This software is subject to the provisions of the Zope Public License,
+# Version 2.1 (ZPL).  A copy of the ZPL should accompany this distribution.
+# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
+# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
+# FOR A PARTICULAR PURPOSE.
+#
+
+__docformat__ = 'restructuredtext'
+
+from zope.schema import Bool
+
+from pyams_portal.interfaces import IPortletSettings
+
+from pyams_content import _
+
+
+class ISharedContentHeaderPortletSettings(IPortletSettings):
+    """Shared content header portlet settings"""
+
+    display_breadcrumbs = Bool(title=_("Display breadcrumbs?"),
+                               required=True,
+                               default=True)
+
+    display_title = Bool(title=_("Display title?"),
+                         required=True,
+                         default=True)
+
+    display_tags = Bool(title=_("Display tags?"),
+                        required=True,
+                        default=True)
+
+    display_header = Bool(title=_("Display header?"),
+                          required=True,
+                          default=True)
+
+    display_specificities = Bool(title=_("Display specificities?"),
+                                 description=_("If 'no', specific content's informations won't be displayed..."),
+                                 required=True,
+                                 default=True)
+
+
+class ISharedContentTitlePortletSettings(IPortletSettings):
+    """Shared content title portlet settings"""
--- a/src/pyams_content/shared/common/portlet/interfaces/__init__.py	Wed Jan 02 20:20:37 2019 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,52 +0,0 @@
-#
-# Copyright (c) 2008-2017 Thierry Florac <tflorac AT ulthar.net>
-# All Rights Reserved.
-#
-# This software is subject to the provisions of the Zope Public License,
-# Version 2.1 (ZPL).  A copy of the ZPL should accompany this distribution.
-# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
-# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
-# FOR A PARTICULAR PURPOSE.
-#
-
-__docformat__ = 'restructuredtext'
-
-from zope.interface import Interface
-from zope.schema import Bool
-
-from pyams_content import _
-from pyams_portal.interfaces import IPortletSettings
-
-
-class ISharedContentHeaderPortletSettings(IPortletSettings):
-    """Shared content header portlet settings"""
-
-    display_breadcrumbs = Bool(title=_("Display breadcrumbs?"),
-                               required=True,
-                               default=True)
-
-    display_title = Bool(title=_("Display title?"),
-                         required=True,
-                         default=True)
-
-    display_tags = Bool(title=_("Display tags?"),
-                        required=True,
-                        default=True)
-
-    display_header = Bool(title=_("Display header?"),
-                          required=True,
-                          default=True)
-
-    display_specificities = Bool(title=_("Display specificities?"),
-                                 description=_("If 'no', specific content's informations won't be displayed..."),
-                                 required=True,
-                                 default=True)
-
-
-class ISharedContentHeadViewletManager(Interface):
-    """Shared content head viewlet manager marker interface"""
-
-
-class ISharedContentTitlePortletSettings(IPortletSettings):
-    """Shared content title portlet settings"""
--- a/src/pyams_content/shared/common/portlet/skin/__init__.py	Wed Jan 02 20:20:37 2019 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,25 +0,0 @@
-#
-# Copyright (c) 2008-2018 Thierry Florac <tflorac AT ulthar.net>
-# All Rights Reserved.
-#
-# This software is subject to the provisions of the Zope Public License,
-# Version 2.1 (ZPL).  A copy of the ZPL should accompany this distribution.
-# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
-# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
-# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
-# FOR A PARTICULAR PURPOSE.
-#
-
-__docformat__ = 'restructuredtext'
-
-from zope.interface import Interface, implementer
-
-from pyams_content.shared.common.portlet.interfaces import ISharedContentHeadViewletManager
-from pyams_skin.layer import IPyAMSUserLayer
-from pyams_viewlet.manager import viewletmanager_config, WeightOrderedViewletManager
-
-
-@viewletmanager_config(name='pyams_content.head', layer=IPyAMSUserLayer, view=Interface)
-@implementer(ISharedContentHeadViewletManager)
-class SharedContentHeadViewletManager(WeightOrderedViewletManager):
-    """Shared content head viewlet manager"""