1
0
Fork 0
mirror of https://github.com/syncthing/syncthing-android.git synced 2024-12-23 11:21:29 +00:00

Fix chromium running multiple times in the background (fixes #1064)

This commit is contained in:
Catfriend1 2018-05-07 09:47:07 +02:00 committed by Audrius Butkevicius
parent d5da9d7883
commit cb1575b890

View file

@ -162,10 +162,32 @@ public class WebGuiActivity extends StateDialogActivity
if (mWebView.canGoBack()) { if (mWebView.canGoBack()) {
mWebView.goBack(); mWebView.goBack();
} else { } else {
finish();
super.onBackPressed(); super.onBackPressed();
} }
} }
@Override
public void onPause() {
mWebView.onPause();
mWebView.pauseTimers();
super.onPause();
}
@Override
public void onResume() {
super.onResume();
mWebView.resumeTimers();
mWebView.onResume();
}
@Override
protected void onDestroy() {
mWebView.destroy();
mWebView = null;
super.onDestroy();
}
/** /**
* Reads the SyncthingService.HTTPS_CERT_FILE Ca Cert key and loads it in memory * Reads the SyncthingService.HTTPS_CERT_FILE Ca Cert key and loads it in memory
*/ */