mirror of
https://github.com/M66B/FairEmail.git
synced 2026-04-08 01:53:25 +02:00
Moved PGP debugging to encryption options
This commit is contained in:
@@ -136,7 +136,6 @@ import org.jsoup.nodes.Node;
|
||||
import org.jsoup.nodes.TextNode;
|
||||
import org.jsoup.select.Elements;
|
||||
import org.jsoup.select.NodeFilter;
|
||||
import org.openintents.openpgp.IOpenPgpService2;
|
||||
import org.openintents.openpgp.OpenPgpError;
|
||||
import org.openintents.openpgp.util.OpenPgpApi;
|
||||
import org.openintents.openpgp.util.OpenPgpServiceConnection;
|
||||
@@ -885,20 +884,7 @@ public class FragmentCompose extends FragmentBase {
|
||||
|
||||
final String pkg = Helper.getOpenKeychainPackage(getContext());
|
||||
Log.i("PGP binding to " + pkg);
|
||||
pgpService = new OpenPgpServiceConnection(getContext(), pkg, new OpenPgpServiceConnection.OnBound() {
|
||||
@Override
|
||||
public void onBound(IOpenPgpService2 service) {
|
||||
Log.i("PGP bound to " + pkg);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onError(Exception ex) {
|
||||
if ("bindService() returned false!".equals(ex.getMessage()))
|
||||
Log.i("PGP " + ex.getMessage());
|
||||
else
|
||||
Log.e("PGP", ex);
|
||||
}
|
||||
});
|
||||
pgpService = new OpenPgpServiceConnection(getContext(), pkg);
|
||||
pgpService.bindToService();
|
||||
|
||||
return view;
|
||||
@@ -1016,8 +1002,10 @@ public class FragmentCompose extends FragmentBase {
|
||||
public void onDestroyView() {
|
||||
adapter = null;
|
||||
|
||||
if (pgpService != null && pgpService.isBound())
|
||||
if (pgpService != null && pgpService.isBound()) {
|
||||
Log.i("PGP unbinding");
|
||||
pgpService.unbindFromService();
|
||||
}
|
||||
pgpService = null;
|
||||
|
||||
super.onDestroyView();
|
||||
|
||||
Reference in New Issue
Block a user