Merge "QS tile lifecycle management" into nyc-dev
am: e59bbb0
* commit 'e59bbb0899e17710e9380b704141b100ddc2faa0':
QS tile lifecycle management
Change-Id: I44eb2611b3c66c547c2f67c48278a01b0fb24652
This commit is contained in:
@@ -148,13 +148,20 @@ public class TileLifecycleManager extends BroadcastReceiver implements
|
|||||||
if (DEBUG) Log.d(TAG, "onServiceConnected " + name);
|
if (DEBUG) Log.d(TAG, "onServiceConnected " + name);
|
||||||
// Got a connection, set the binding count to 0.
|
// Got a connection, set the binding count to 0.
|
||||||
mBindTryCount = 0;
|
mBindTryCount = 0;
|
||||||
mWrapper = new QSTileServiceWrapper(Stub.asInterface(service));
|
final QSTileServiceWrapper wrapper = new QSTileServiceWrapper(Stub.asInterface(service));
|
||||||
try {
|
try {
|
||||||
service.linkToDeath(this, 0);
|
service.linkToDeath(this, 0);
|
||||||
} catch (RemoteException e) {
|
} catch (RemoteException e) {
|
||||||
}
|
}
|
||||||
setQSService(mService);
|
if (!wrapper.setQSService(mService)) {
|
||||||
setQSTile(mTile);
|
handleDeath();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (!wrapper.setQSTile(mTile)) {
|
||||||
|
handleDeath();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
mWrapper = wrapper;
|
||||||
handlePendingMessages();
|
handlePendingMessages();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user