From e58b124d24607e0fbf6caee43c98807073c80c96 Mon Sep 17 00:00:00 2001
From: Jean-Paul Smets <jp@nexedi.com>
Date: Tue, 25 Sep 2007 16:17:35 +0000
Subject: [PATCH] Dynamic editor type parameters.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@16611 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 .../WebPage_viewEditor/my_text_content.xml    | 32 ++++++++++++++++---
 1 file changed, 27 insertions(+), 5 deletions(-)

diff --git a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebPage_viewEditor/my_text_content.xml b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebPage_viewEditor/my_text_content.xml
index 814b216edf..13b962f0cc 100644
--- a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebPage_viewEditor/my_text_content.xml
+++ b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebPage_viewEditor/my_text_content.xml
@@ -3,11 +3,8 @@
   <record id="1" aka="AAAAAAAAAAE=">
     <pickle>
       <tuple>
-        <tuple>
-          <string>Products.ERP5Form.EditorField</string>
-          <string>EditorField</string>
-        </tuple>
-        <none/>
+        <global name="EditorField" module="Products.ERP5Form.EditorField"/>
+        <tuple/>
       </tuple>
     </pickle>
     <pickle>
@@ -190,6 +187,12 @@
                     <key> <string>required</string> </key>
                     <value> <string></string> </value>
                 </item>
+                <item>
+                    <key> <string>text_editor</string> </key>
+                    <value>
+                      <persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
+                    </value>
+                </item>
                 <item>
                     <key> <string>title</string> </key>
                     <value> <string></string> </value>
@@ -310,4 +313,23 @@
       </dictionary>
     </pickle>
   </record>
+  <record id="3" aka="AAAAAAAAAAM=">
+    <pickle>
+      <tuple>
+        <tuple>
+          <string>Products.Formulator.TALESField</string>
+          <string>TALESMethod</string>
+        </tuple>
+        <none/>
+      </tuple>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>_text</string> </key>
+            <value> <string>python:(here.getTextFormat() == \'text/html\' and here.portal_preferences.getPreferredTextEditor()) or \'text_area\'</string> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
 </ZopeData>
-- 
2.30.9