Extended translation layers need to create placeholders before translateability (e.g. with l10n_client) is possible.
i18nviews won't create translateable strings on translation request. They're only created explicitly on write call.
This leads to fundamental speedup of readonly output, limit accidental creation of placeholders and better cacheability.

In order to optimally support this behaviour, views should trigger a localization save() on every view save.

$view->save_locale_strings();

Certain conditions such as check for enabled translation layer makes sense. Note i discourage to check for count() of enabled languages, since there might be reasons where development language is different to (single) presentation language where translation layer should still work.

CommentFileSizeAuthor
#1 views_1031948_1_localesave.patch594 bytesmiro_dietiker

Comments

miro_dietiker’s picture

Status: Active » Needs review
StatusFileSize
new594 bytes

Attaching patch to add the locale save.

merlinofchaos’s picture

Status: Needs review » Fixed

Committed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.