Adjustments to EAC Gui Service Binding
@@ -70,6 +70,8 @@ public abstract class EacActivity extends NfcActivity implements BindingTaskResu
super.onDestroy();
if (alreadyBinded) {
mEacGuiConnection.stopService();
+ unbindEacGui();
+ alreadyBinded = false;
}
}
@@ -103,6 +105,10 @@ public abstract class EacActivity extends NfcActivity implements BindingTaskResu
bindService(new Intent(getApplicationContext(), EacGuiService.class), con, Context.BIND_AUTO_CREATE);
}
+ public synchronized void unbindEacGui() {
+ unbindService(getServiceConnection());
+ }
+
public synchronized EacServiceConnection getServiceConnection() {
return mEacGuiConnection;
}
