[Zope-Checkins] SVN: Zope/trunk/ No longer depend on `zope.app.locales`. Zope2 uses almost none of the translations provided in the package and is not required for most projects. The decision to include locales is left to the application developer now.
Hanno Schlichting
hannosch at hannosch.eu
Sun Apr 26 12:52:05 EDT 2009
Log message for revision 99529:
No longer depend on `zope.app.locales`. Zope2 uses almost none of the translations provided in the package and is not required for most projects. The decision to include locales is left to the application developer now.
Changed:
U Zope/trunk/doc/CHANGES.rst
U Zope/trunk/setup.py
U Zope/trunk/src/Products/Five/form/tests/forms.txt
U Zope/trunk/src/Products/Five/i18n.zcml
-=-
Modified: Zope/trunk/doc/CHANGES.rst
===================================================================
--- Zope/trunk/doc/CHANGES.rst 2009-04-26 16:45:44 UTC (rev 99528)
+++ Zope/trunk/doc/CHANGES.rst 2009-04-26 16:52:05 UTC (rev 99529)
@@ -11,6 +11,10 @@
Restructuring
+++++++++++++
+- No longer depend on `zope.app.locales`. Zope2 uses almost none of the
+ translations provided in the package and is not required for most projects.
+ The decision to include locales is left to the application developer now.
+
- Removed the dependency on `zope.app.testing` in favor of providing a more
minimal placeless setup as part of ZopeTestCase for our own tests.
Modified: Zope/trunk/setup.py
===================================================================
--- Zope/trunk/setup.py 2009-04-26 16:45:44 UTC (rev 99528)
+++ Zope/trunk/setup.py 2009-04-26 16:52:05 UTC (rev 99529)
@@ -147,7 +147,6 @@
'zope.app.component',
'zope.app.container',
'zope.app.form',
- 'zope.app.locales',
'zope.app.pagetemplate',
'zope.app.publication',
'zope.app.publisher',
Modified: Zope/trunk/src/Products/Five/form/tests/forms.txt
===================================================================
--- Zope/trunk/src/Products/Five/form/tests/forms.txt 2009-04-26 16:45:44 UTC (rev 99528)
+++ Zope/trunk/src/Products/Five/form/tests/forms.txt 2009-04-26 16:52:05 UTC (rev 99529)
@@ -480,89 +480,6 @@
...
-i18n:
------
-
-Let's set up a German testbrowser:
-
- >>> from Products.Five.testbrowser import Browser
- >>> browser = Browser()
- >>> browser.addHeader('Accept-Language', 'de')
- >>> browser.addHeader('Authorization', 'Basic manager:r00t')
-
-And now the add form in German:
-
- >>> browser.open("http://localhost/test_folder_1_/ftf/+/addfieldcontent.html")
- >>> print browser.contents
- <html>
- ...Felderinhalt hinzuf...
- ...Eine kurz...Titel...
- ...Eine ausf...Beschreibung...
- ...Irgendeine Zahl...
- ...Irgendeine Liste...
- ...hinzuf...
- ...Auffrischen...
- ...Hinzuf...
- ...Objektname...
-
-The same with an input error:
-
- >>> ctl = browser.getControl(name="field.somenumber")
- >>> ctl.value = '0'
- >>> browser.getControl(name="UPDATE_SUBMIT").click()
- >>> print browser.contents
- <html>
- ...Felderinhalt hinzuf...
- ...Ein Fehler ist aufgetreten...
- ...Es gab <strong>1</strong> Eingabefehler...
- ...Eine kurz...Titel...
- ...Erforderliche Eingabe fehlt...
- ...Eine ausf...Beschreibung...
- ...Irgendeine Zahl...
- ...Irgendeine Liste...
- ...hinzuf...
- ...Auffrischen...
- ...Hinzuf...
- ...Objektname...
-
-And now the translated edit form:
-
- >>> from Products.Five.form.tests.schemacontent import \
- ... manage_addFieldContent
- >>> dummy = manage_addFieldContent(self.folder.ftf, 'i18ntest', 'titel')
-
- >>> browser.open("http://localhost/test_folder_1_/ftf/i18ntest/edit.html")
- >>> print browser.contents
- <html>
- ...Felderinhalt bearbeiten...
- ...Eine kurz...Titel...
- ...Eine ausf...Beschreibung...
- ...Irgendeine Zahl...
- ...Irgendeine Liste...
- ...hinzuf...
- ...Auffrischen...
- ...Abschicken...
-
-Again with an input error:
-
- >>> ctl = browser.getControl(name="field.title")
- >>> ctl.value = ''
- >>> browser.getControl(name="UPDATE_SUBMIT").click()
- >>> print browser.contents
- <html>
- ...Felderinhalt bearbeiten...
- ...Ein Fehler ist aufgetreten...
- ...Es gab <strong>1</strong> Eingabefehler...
- ...Eine kurz...Titel...
- ...Erforderliche Eingabe fehlt...
- ...Eine ausf...Beschreibung...
- ...Irgendeine Zahl...
- ...Irgendeine Liste...
- ...hinzuf...
- ...Auffrischen...
- ...Abschicken...
-
-
Clean up
--------
Modified: Zope/trunk/src/Products/Five/i18n.zcml
===================================================================
--- Zope/trunk/src/Products/Five/i18n.zcml 2009-04-26 16:45:44 UTC (rev 99528)
+++ Zope/trunk/src/Products/Five/i18n.zcml 2009-04-26 16:52:05 UTC (rev 99529)
@@ -20,8 +20,4 @@
factory="zope.publisher.http.HTTPCharsets"
/>
- <configure package="zope.app.locales">
- <i18n:registerTranslations directory="."/>
- </configure>
-
</configure>
More information about the Zope-Checkins
mailing list