import android.content.res.Resources;
import android.os.AsyncTask;
-import android.os.Handler;
-import android.os.Looper;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
return (position == 0) ? ITEM_TYPE_HEADER : ITEM_TYPE_ACCOUNT;
}
public void setAccounts(List<AccountListItem> newList) {
- new Handler(Looper.getMainLooper()).post(() -> listDiffer.submitList(newList));
+ Misc.onMainThread(() -> listDiffer.submitList(newList));
}
static class Change {
static final int NAME = 1;
if (changes.has(Change.LEVEL)) {
ConstraintLayout.LayoutParams lp =
- (ConstraintLayout.LayoutParams) b.accountNameLayout.getLayoutParams();
+ (ConstraintLayout.LayoutParams) b.flowWrapper.getLayoutParams();
lp.setMarginStart(
acc.getLevel() * rm.getDimensionPixelSize(R.dimen.thumb_row_height) / 3);
}