Updates the locale message files
331548
def makemessages(application, locale):
    
    from django.core.management import call_command

    if not locale:
        locale = 'en'
    with work_in(application):
        call_command('makemessages', locale=(locale,))
1189292
private void loadLocalizationFromXmlBundle(Locale locale) {

        CmsXmlContentValueSequence messages = m_xmlBundle.getValueSequence("Message", locale);
        SortedProperties props = new SortedProperties();
        if (null != messages) {
            for (I_CmsXmlContentValue msg : messages.getValues()) {
                String msgpath = msg.getPath();
                props.put(
                    m_xmlBundle.getStringValue(m_cms, msgpath + "/Key", locale),
                    m_xmlBundle.getStringValue(m_cms, msgpath + "/Value", locale));
            }
        }
        m_localizations.put(locale, props);
    }
183485
public void actionChangeElementLanguage() {

        // save eventually changed content of the editor
        Locale oldLocale = CmsLocaleManager.getLocale(getParamOldelementlanguage());
        Locale newLocale = getElementLocale();
        try {
            setEditorValues(oldLocale);
            if (!m_content.validate(getCms()).hasErrors(oldLocale)) {
                // no errors found in content
                if (!m_content.hasLocale(newLocale)) {
                    // check if we should copy the content from a default locale
                    boolean addNew = true;
                    List<Locale> locales = OpenCms.getLocaleManager().getDefaultLocales(getCms(), getParamResource());
                    if (locales.size() > 1) {
                        // default locales have been set, try to find a match
                        try {
                            m_content.copyLocale(locales, newLocale);
                            addNew = false;
                        } catch (CmsXmlException e) {
                            // no matching default locale was available, we will create a new one later
                        }
                    }
                    if (addNew) {
                        // create new element if selected language element is not present
                        try {
                            m_content.addLocale(getCms(), newLocale);
                        } catch (CmsXmlException e) {
                            if (LOG.isErrorEnabled()) {
                                LOG.error(e.getLocalizedMessage(), e);
                            }
                        }
                    }
                }
                //save to temporary file
                writeContent();
                // set default action to suppress error messages
                setAction(ACTION_DEFAULT);
            } else {
                // errors found, switch back to old language to show errors
                setParamElementlanguage(getParamOldelementlanguage());
                // set stored locale to null to reinitialize it
                m_elementLocale = null;
            }
        } catch (Exception e) {
            // should usually never happen
            if (LOG.isInfoEnabled()) {
                LOG.info(e.getLocalizedMessage(), e);
            }
        }
    }
1081618
private String getLocalizationMessages(CmsMessages messages) {

        JSONObject result = new JSONObject();
        try {
            result.put("search", messages.key(Messages.GUI_CODEMIRROR_LANG_SEARCH_0));
            result.put("hint", messages.key(Messages.GUI_CODEMIRROR_LANG_HINT_0));
            result.put("replace", messages.key(Messages.GUI_CODEMIRROR_LANG_REPLACE_0));
            result.put("replacewith", messages.key(Messages.GUI_CODEMIRROR_LANG_REPLACE_WITH_0));
            result.put("replaceconfirm", messages.key(Messages.GUI_CODEMIRROR_LANG_REPLACE_CONFIRM_0));
            result.put("replaceyes", messages.key(Messages.GUI_CODEMIRROR_LANG_REPLACE_YES_0));
            result.put("replaceno", messages.key(Messages.GUI_CODEMIRROR_LANG_RELACE_NO_0));
            result.put("replacestop", messages.key(Messages.GUI_CODEMIRROR_LANG_REPLACE_STOP_0));

            result.put("fontsize", messages.key(Messages.GUI_CODEMIRROR_LANG_FONT_SIZE_0));
        } catch (org.opencms.json.JSONException e) {
            // should never happen
        }
        return result.toString();
    }
963242
public function resetMessages($locale = null)
    {
        if ($locale === null) {
            $this->messages = [];

            return true;
        }

        foreach ($this->getDirectories() as $directory) {
            $directory = rtrim($directory, '\\/');
            if (file_exists($filename = "$directory/$locale.php")) {
                $this->messages[$locale] = require $filename;
                $this->addResource('array', $this->messages[$locale], $locale);

                return true;
            }
        }

        return false;
    }
620917
def update(self, new_data: Dict[Text, Dict[Text, Text]]):
        

        for locale, data in new_data.items():
            if locale not in self.dict:
                self.dict[locale] = {}

            self.dict[locale].update(data)
976135
public @Nonnull StaticMessageSource addMessage(@Nonnull Locale locale, @Nonnull String code, @Nonnull String message) {
        ArgumentUtils.requireNonNull("locale", locale);
        if (StringUtils.isNotEmpty(code) && StringUtils.isNotEmpty(message)) {
            messageMap.put(new MessageKey(locale, code), message);
        }
        return this;
    }
900969
def make_po_file(self, potfile, locale):
        
        pofile = self._get_po_path(potfile, locale)

        msgs = self._get_unique_messages(potfile)
        msgs = self._merge_messages(potfile, pofile, msgs)
        msgs = self._strip_package_version(msgs)

        with open(pofile, 'w') as fp:
            fp.write(msgs)

        self._remove_obsolete_messages(pofile)
829693
function writeLocales (locales, params, callback) {
  try {
    var jsonPath, json;
    for (var key in locales) {
      if (locales.hasOwnProperty(key)) {
        json = locales[key];
        jsonPath = path.join(params.dirPath, json.localeName, 'messages.json');

        // remove empty messages
        for (var msg_key in json.messages) {
          if (json.messages.hasOwnProperty(msg_key)) {
            if (json.messages[msg_key]['message'] == undefined) {
              delete json.messages[msg_key];
            }
          }
        }

        fs.outputJsonSync(jsonPath, json.messages);
        if (params.debug) {
          log('Created file', jsonPath, json.messages);
        }
      }
    }
    callback(null);
  } catch (err) {
    callback(err);
  }
}
103373
def update_translations(ctx, module_list):
    
    modules.update_translations(ctx, module_list)
    ctx.log_line(u'Deprecated: use anthem.lyrics.modules.update_translations'
                 'instead of anthem.lyrics.loaders.update_translations')
596197
def refresh_existing_encodings(self, encodings_from_file):
        
        update = False

        for msg in self.table_model.protocol.messages:
            i = next((i for i, d in enumerate(encodings_from_file) if d.name == msg.decoder.name), 0)
            if msg.decoder != encodings_from_file[i]:
                update = True
                msg.decoder = encodings_from_file[i]
                msg.clear_decoded_bits()
                msg.clear_encoded_bits()

        if update:
            self.refresh_table()
            self.refresh_estimated_time()
404713
function updateGlobalTypographyMixin() {

		$languages = $this->_getRequiredLanguages();

		// Auto-create SCSS files

		// TODO: Use self::getThemeFontStacks() to parse if stack has $serif or $sans-serif strings

		foreach ( [ 'prince', 'epub', 'web' ] as $type ) {
			$this->_sassify( $type, $languages );
		}

		$this->getFonts( $languages );

	}
1225391
function replaceLocale(context, payload) {
      context.commit({
        type: 'REPLACE_LOCALE',
        locale: payload.locale,
        translations: payload.translations
      });
    }
720513
function update(message) {
	clearLine(stdout, 0); // Clear current STDOUT line
	cursorTo(stdout, 0); // Place cursor at the start
	stdout.write(message.toString());
}
238722
def update_bundle(data_bundle_path, locale):
    
    import rqalpha.utils.bundle_helper
    rqalpha.utils.bundle_helper.update_bundle(data_bundle_path, locale)
276091
private void notifyLanguageChanged() {
        sendOnBeforeLocaleChangedEvent();
        activity.getIntent().putExtra(KEY_ACTIVITY_LOCALE_CHANGED, true);
        callDummyActivity();
        activity.recreate();
    }
430670
def refresh_existing_encodings(self):
        
        update = False

        for msg in self.proto_analyzer.messages:
            i = next((i for i, d in enumerate(self.decodings) if d.name == msg.decoder.name), 0)
            if msg.decoder != self.decodings[i]:
                update = True
                msg.decoder = self.decodings[i]
                msg.clear_decoded_bits()
                msg.clear_encoded_bits()

        if update:
            self.protocol_model.update()
            self.label_value_model.update()