Refine onServiceDisconnected

This commit is contained in:
Mygod
2016-04-25 12:53:38 +08:00
parent 1d295b28bb
commit 0503eeac41
@@ -17,10 +17,7 @@ trait ServiceBoundContext extends Context {
ServiceBoundContext.this.onServiceConnected() ServiceBoundContext.this.onServiceConnected()
} }
override def onServiceDisconnected(name: ComponentName) { override def onServiceDisconnected(name: ComponentName) {
if (callback != null) { unregisterCallback
unregisterCallback
callback = null
}
ServiceBoundContext.this.onServiceDisconnected() ServiceBoundContext.this.onServiceDisconnected()
bgService = null bgService = null
} }