Observable preferences F (GuiPreferences, Proxy and Remote)#8166
Conversation
# Conflicts: # src/main/java/org/jabref/preferences/JabRefPreferences.java
| storeRemoteSettings(); | ||
| storeProxySettings(); | ||
|
|
||
| storeProxySettings(new ProxyPreferences( |
There was a problem hiding this comment.
It's late so I might missing something obvious here, but: You create a new ProxyPreference object here and storeProxySettings only calls the set* methods. Since there are no bindings of that proxypreference object to JabRefPreferences, this will essentially do nothing?!
There was a problem hiding this comment.
You're missing something. I think.
storeProxyPreferences takes just the members one by one of the newly created object and stores them in the original preferences object, that was supplied by JabRefPreferences. See NetworkTabViewModel::storeProxySettings:
private void storeProxySettings(ProxyPreferences newProxyPreferences) {
if (!newProxyPreferences.equals(proxyPreferences)) {
ProxyRegisterer.register(newProxyPreferences);
}
proxyPreferences.setUseProxy(newProxyPreferences.shouldUseProxy());
proxyPreferences.setHostname(newProxyPreferences.getHostname());
proxyPreferences.setPort(newProxyPreferences.getPort());
proxyPreferences.setUseAuthentication(newProxyPreferences.shouldUseAuthentication());
proxyPreferences.setUsername(newProxyPreferences.getUsername());
proxyPreferences.setPassword(newProxyPreferences.getPassword());
}
The reason for creating a new preferences object here is to keep the test proxy button.
There was a problem hiding this comment.
Okay thanks, I missed that indeed.
|
l10n fails: |
|
Thanks, just started IntelliJ a second ago to fix it, but you were quicker. :-) |
Follow up to #8165
CHANGELOG.mddescribed in a way that is understandable for the average user (if applicable)