lbryio / lbry-android

The LBRY Android app
MIT License
2.44k stars 113 forks source link

Use total wallet balance instead of spendable #1162

Closed kekkyojin closed 3 years ago

kekkyojin commented 3 years ago

PR Checklist

Please check all that apply to this PR using "x":

PR Type

What kind of change does this PR introduce?

Fixes

Issue Number: #1147

What is the current behavior?

Spendable wallet balance is shown instead of total one

What is the new behavior?

Now total wallet balance will be shown. Also the breakdown is shown in a expandable view which will animate a little bit when expanding.

Other information

A new custom view to show LBRY Credits has been created. This is mostly only usable on the wallet fragment, but it reduces complexity on the layout files as they only need a single widget to be added or edited instead of a couple of them. Also the view can now be edited only once and will be updated wherever it would be used.

Balance breakdown has been implemented as a listview. This way, new items can be added as a Java object instead of using hard-coded views on the balance layout.

kekkyojin commented 3 years ago

There is a UI problem when unlocking tips, @akinwale . This code unlocks tips even when there were more than 400, but UI is not updated accordingly as expected.

Don't review it yet.