/** * The platform should invoke this function for locale changing */ void javanotify_change_locale(short languageCode, short regionCode) { const char tmp[6]; midp_jc_event_union e; REPORT_INFO(LC_CORE, "javanotify_change_locale() >>\n"); e.eventType = MIDP_JC_EVENT_CHANGE_LOCALE; setSystemProperty(LOCALE, tmp); midp_jc_event_send(&e); }
/** * Initializes the configuration sub-system. * * @return <tt>0</tt> for success, otherwise a non-zero value */ int initializeConfig(void) { if (implementationProperties != NULL) { /* Already initialized. */ return 0; } if (initProps(&implementationProperties, &IMPL_PROPERTY_FILE, storage_get_config_root(INTERNAL_STORAGE_ID)) != 0) { return -1; } if (initProps(&applicationProperties, &APPL_PROPERTY_FILE, storage_get_config_root(INTERNAL_STORAGE_ID)) != 0) { finalizeConfig(); return -1; } /* * Make sure the configuration was specified, because * some older code requires it in the CLDC classes. */ if (getSystemProperty(DEFAULT_CONFIGURATION) == NULL) { setSystemProperty(DEFAULT_CONFIGURATION, DEFAULT_CLDC); } if (getSystemProperty(PROFILES_PROP_NAME) == NULL) { setSystemProperty(PROFILES_PROP_NAME, DEFAULT_PROFILE); } if (getSystemProperty(ENCODING_PROP_NAME) == NULL) { setSystemProperty(ENCODING_PROP_NAME, DEFAULT_CHARACTER_ENCODING); } return 0; }