Skip to content
This repository was archived by the owner on Jun 27, 2020. It is now read-only.

Commit abce7ca

Browse files
author
Evgeniy Kanivets
committed
Added line to report listview
1 parent 728918a commit abce7ca

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

app/src/main/java/com/blogspot/e_kanivets/moneytracker/adapter/RecordAdapter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ public View getView(final int position, View convertView, ViewGroup parent) {
7474
tvTime.setText(dateFormat.format(new Date(records.get(position).getTime())));
7575

7676
tvPrice.setText((records.get(position).isIncome() ? "+ " : "- ")
77-
+ "$" + Integer.toString(records.get(position).getPrice()));
77+
+ Integer.toString(records.get(position).getPrice()));
7878
tvTitle.setText(records.get(position).getTitle());
7979
tvCategory.setText(records.get(position).getCategory());
8080

app/src/main/java/com/blogspot/e_kanivets/moneytracker/adapter/ReportItemAdapter.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ public View getView(int i, View view, ViewGroup viewGroup) {
5151
if(i == getCount()-1) {
5252
view.findViewById(R.id.line).setVisibility(View.VISIBLE);
5353
}
54+
if(i == getCount()-3) {
55+
view.findViewById(R.id.line).setVisibility(View.VISIBLE);
56+
}
5457
view.setBackgroundColor(records.get(i).second < 0 ? context.getResources().getColor(R.color.white_red) :
5558
context.getResources().getColor(R.color.white_green));
5659

0 commit comments

Comments
 (0)