Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#871 use inherited account color in left strip #873

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@
import android.content.Intent;
import android.content.res.Configuration;
import android.database.Cursor;
import android.graphics.Color;
import android.os.AsyncTask;
import android.os.Build;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.support.v4.app.LoaderManager.LoaderCallbacks;
Expand Down Expand Up @@ -499,11 +497,11 @@ public void onBindViewHolderCursor(final AccountViewHolder holder, final Cursor

// add a summary of transactions to the account view

// Make sure the balance task is truly multithread
// Make sure the balance task is truly multithread
new AccountBalanceTask(holder.accountBalance).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR, accountUID);

String accountColor = cursor.getString(cursor.getColumnIndexOrThrow(DatabaseSchema.AccountEntry.COLUMN_COLOR_CODE));
int colorCode = accountColor == null ? Color.TRANSPARENT : Color.parseColor(accountColor);
// #871 Display inherited color from ancestor's account on the Strip View
int colorCode = AccountsDbAdapter.getActiveAccountColorResource(accountUID);
holder.colorStripView.setBackgroundColor(colorCode);

boolean isPlaceholderAccount = mAccountsDbAdapter.isPlaceholderAccount(accountUID);
Expand Down