- Added support for on-the-fly routerconsole.lang changes to desktopgui and routerconsole (routerconsole now commits changes to the I2PAppContext).

- Added desktopgui support for detecting if it's running in the same JVM as I2P (without commandline arguments).
This commit is contained in:
mathiasdm
2011-01-03 18:40:18 +00:00
parent 2a6c763c31
commit 9b0c42ca6f
6 changed files with 54 additions and 9 deletions

View File

@ -18,7 +18,21 @@ public class ContentHelper extends HelperBase {
public void setStartAtBeginning(String moo) {
_startAtBeginning = Boolean.valueOf(""+moo).booleanValue();
}
public void setLang(String l) { _lang = l; }
public void setLang(String l) {
if(_lang == null || !_lang.equals(l)) {
//Set language for router console
_lang = l;
if(_context == null) {
setContextId(null);
}
//Set language persistently throughout I2P
_context.router().setConfigSetting(Messages.PROP_LANG, _lang);
_context.router().saveConfig();
_context.setProperty(Messages.PROP_LANG, _lang);
}
}
public void setMaxLines(String lines) {
if (lines != null) {