QS Footer: Don't update icon from wrong thread. am: f9c6026a7d
am: b10b51277f
Change-Id: If585197223ec5767c2f63dce8717eda82d482a30
This commit is contained in:
@@ -126,8 +126,8 @@ public class QSFooter implements OnClickListener, DialogInterface.OnClickListene
|
||||
? R.drawable.ic_qs_branded_vpn
|
||||
: R.drawable.ic_qs_vpn);
|
||||
if (mFooterIconId != footerIconId) {
|
||||
mFooterIcon.setImageResource(footerIconId);
|
||||
mFooterIconId = footerIconId;
|
||||
mMainHandler.post(mUpdateIcon);
|
||||
}
|
||||
mIsVisible = mIsIconVisible;
|
||||
}
|
||||
@@ -207,6 +207,13 @@ public class QSFooter implements OnClickListener, DialogInterface.OnClickListene
|
||||
}
|
||||
}
|
||||
|
||||
private final Runnable mUpdateIcon = new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
mFooterIcon.setImageResource(mFooterIconId);
|
||||
}
|
||||
};
|
||||
|
||||
private final Runnable mUpdateDisplayState = new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
|
||||
Reference in New Issue
Block a user