plone/plone.multilingualbehavior — pull request #3 by pysailor (2013-04-07 12:08:38+00:00)
Title: Added test & event handler for manually added behavior

On content types that do not natively provide the multilingual behavior, it may still be added at a later stage via the @@behaviors view in the Dexterity Types configuration.

Currently, existing objects of such a type can't be accessed any more TTW, because no Translation Group is present. See plone/plone.app.multilingual/issues/44

This pull request adds 2 things:

* a new test "doctest_manualbehavior.txt" that tests adding the behavior to a content type TTW
* an event handler that listens to changes on `BehaviorConfigurationAdapter`, and if the multilingual behavior got activated, updates all existing items of that type so that they receive a Translation Group