LalitMaganti / HoloIRC

Open source IRC client for Android.
GNU General Public License v3.0
131 stars 32 forks source link

Fix up service lifecycle #131

Closed maniac103 closed 8 years ago

maniac103 commented 8 years ago

Stop making the service run permanently, even if not connected to any server. Now, the service runs only if either a server is connected or the main activity is running.

LalitMaganti commented 8 years ago

I'm presuming this works although I'm worried about NPEs when the activity is rotated because the connection to the service will be lost.

maniac103 commented 8 years ago

Yeah, it will be lost and restarted - but both the activity and the fragment are recreated anyway. I just tried explicitly testing rotation again, it was fine.