Skip to content
This repository has been archived by the owner on Oct 26, 2021. It is now read-only.

Commit

Permalink
Merge pull request #569 from balancemymoney/bug/278/institution-cell-…
Browse files Browse the repository at this point in the history
…background

Fix dragging a section (institution) in the accounts view has no background #278
  • Loading branch information
Ben Baron committed Feb 13, 2018
2 parents 981d624 + db7347e commit dddc2e4
Showing 1 changed file with 10 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,16 @@ class AccountsTabGroupCell: View {

self.setAccessibilityLabel("Section: " + updatedModel.name)
self.needsDisplay = true

updateBackgroundColors()
}

func updateBackgroundColors() {
if let color = model?.source.color {
self.layerBackgroundColor = color
amountField.backgroundColor = color
nameField.backgroundColor = color
}
}
}

Expand Down Expand Up @@ -136,7 +146,6 @@ class AccountsTabAccountCell: View {

init() {
super.init(frame: NSZeroRect)
self.layerBackgroundColor = CurrentTheme.defaults.cell.backgroundColor

self.addSubview(topContainer)
topContainer.snp.makeConstraints { make in
Expand Down

0 comments on commit dddc2e4

Please sign in to comment.