Refinement to display of account balances
Fixes 5A03CFC3-1A76-4F93-A1FE-555F98438C5A
This commit is contained in:
parent
092bda1435
commit
e97b59b006
2 changed files with 5 additions and 3 deletions
|
|
@ -140,7 +140,7 @@ string account_t::partial_name(bool flat) const
|
||||||
if (! flat) {
|
if (! flat) {
|
||||||
std::size_t count = acct->children_with_flags(ACCOUNT_EXT_TO_DISPLAY);
|
std::size_t count = acct->children_with_flags(ACCOUNT_EXT_TO_DISPLAY);
|
||||||
assert(count > 0);
|
assert(count > 0);
|
||||||
if (count > 1)
|
if (count > 1 || acct->has_flags(ACCOUNT_EXT_TO_DISPLAY))
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
pname = acct->name + ":" + pname;
|
pname = acct->name + ":" + pname;
|
||||||
|
|
@ -202,7 +202,7 @@ namespace {
|
||||||
acct = acct->parent) {
|
acct = acct->parent) {
|
||||||
std::size_t count = acct->children_with_flags(ACCOUNT_EXT_TO_DISPLAY);
|
std::size_t count = acct->children_with_flags(ACCOUNT_EXT_TO_DISPLAY);
|
||||||
assert(count > 0);
|
assert(count > 0);
|
||||||
if (count > 1)
|
if (count > 1 || acct->has_flags(ACCOUNT_EXT_TO_DISPLAY))
|
||||||
depth++;
|
depth++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -179,7 +179,9 @@ format_accounts::mark_accounts(account_t& account, const bool flat)
|
||||||
(account.has_flags(ACCOUNT_EXT_VISITED) || (! flat && visited > 0))) {
|
(account.has_flags(ACCOUNT_EXT_VISITED) || (! flat && visited > 0))) {
|
||||||
bind_scope_t bound_scope(report, account);
|
bind_scope_t bound_scope(report, account);
|
||||||
if ((! flat && to_display > 1) ||
|
if ((! flat && to_display > 1) ||
|
||||||
(disp_pred(bound_scope) && (flat || to_display != 1))) {
|
((flat || to_display != 1 ||
|
||||||
|
account.has_flags(ACCOUNT_EXT_VISITED)) &&
|
||||||
|
disp_pred(bound_scope))) {
|
||||||
account.xdata().add_flags(ACCOUNT_EXT_TO_DISPLAY);
|
account.xdata().add_flags(ACCOUNT_EXT_TO_DISPLAY);
|
||||||
DEBUG("account.display", "Marking account as TO_DISPLAY");
|
DEBUG("account.display", "Marking account as TO_DISPLAY");
|
||||||
to_display = 1;
|
to_display = 1;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue