mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-11-17 09:47:37 +00:00
refactor manager var out to _manager, comment update
This commit is contained in:
parent
b773811eac
commit
20fdcf4817
2 changed files with 6 additions and 5 deletions
|
@ -46,12 +46,16 @@ class _OrdinalsViewState extends ConsumerState<OrdinalsView> {
|
|||
late final FocusNode searchFocus;
|
||||
|
||||
String _searchTerm = "";
|
||||
dynamic _manager;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
searchController = TextEditingController();
|
||||
searchFocus = FocusNode();
|
||||
|
||||
_manager = ref.watch(walletsChangeNotifierProvider
|
||||
.select((value) => value.getManager(widget.walletId)));
|
||||
|
||||
super.initState();
|
||||
}
|
||||
|
||||
|
@ -91,10 +95,7 @@ class _OrdinalsViewState extends ConsumerState<OrdinalsView> {
|
|||
.topNavIconPrimary,
|
||||
),
|
||||
onPressed: () async {
|
||||
final manager = ref.watch(walletsChangeNotifierProvider
|
||||
.select((value) => value.getManager(widget.walletId)));
|
||||
|
||||
(manager.wallet as OrdinalsInterface).refreshInscriptions();
|
||||
(_manager.wallet as OrdinalsInterface).refreshInscriptions();
|
||||
},
|
||||
),
|
||||
),
|
||||
|
|
|
@ -52,7 +52,7 @@ mixin OrdinalsInterface {
|
|||
final utxos = await _db.getUTXOs(_walletId).findAll();
|
||||
final uniqueAddresses = getUniqueAddressesFromUTXOs(utxos);
|
||||
_inscriptions = await getInscriptionsFromAddresses(uniqueAddresses);
|
||||
// TODO save inscriptions to isar which gets watched by a StreamBuilder
|
||||
// TODO save inscriptions to isar which gets watched by a FutureBuilder/StreamBuilder
|
||||
}
|
||||
|
||||
List<String> getUniqueAddressesFromUTXOs(List<UTXO> utxos) {
|
||||
|
|
Loading…
Reference in a new issue