improved processAnyIncomingEvents in social UI menu. moved events file to scripts/

This commit is contained in:
vishalxl 2024-09-29 22:59:26 +05:30
parent cf3ef9fe63
commit 522533d444
3 changed files with 1530 additions and 10 deletions

1
.gitignore vendored
View File

@ -21,5 +21,6 @@ doc/api/
*.js.map
del*.txt
bin/nostr_console_win64.exe
all_nostr_events.txt
*.exe
*.zip

View File

@ -1351,9 +1351,7 @@ Future<void> socialMenuUi(Store node) async {
while(socialMenuContinue) {
if( !firstTime) {
//stdout.write("calling paie");
await processAnyIncomingEvents(node); // this takes 300 ms
//stdout.write("returned from paie");
}
firstTime = false;
@ -1378,8 +1376,6 @@ Future<void> socialMenuUi(Store node) async {
bool selectorTrees_followActionsNoNotifications (Tree t) => t.treeSelectorUserPostAndLike(getFollows( userPublicKey).union(gDefaultFollows).union({userPublicKey}), enableNotifications: false);
node.printStoreTrees(0, DateTime.now().subtract(Duration(hours:gHoursDefaultPrint)), selectorTrees_followActionsNoNotifications, true);
await processAnyIncomingEvents(node, true);
break;
case 2:
@ -1416,7 +1412,6 @@ Future<void> socialMenuUi(Store node) async {
await sendReplyPostLike(node, replyToId, replyKind, content);
clearScreen();
await processAnyIncomingEvents(node, true);
break;
case 3:
@ -1430,7 +1425,6 @@ Future<void> socialMenuUi(Store node) async {
print("No replies or likes.");
}
await processAnyIncomingEvents(node, true);
break;
case 4:
clearScreen();
@ -1441,7 +1435,6 @@ Future<void> socialMenuUi(Store node) async {
print("No posts made by you in last $gHoursDefaultPrint hours.");
}
await processAnyIncomingEvents(node, true);
break;
case 5:
clearScreen();
@ -1452,7 +1445,6 @@ Future<void> socialMenuUi(Store node) async {
} else {
print("No replies/likes made by you in last $gHoursDefaultPrint hours.");
}
await processAnyIncomingEvents(node, true);
break;
case 6:
@ -1464,7 +1456,6 @@ Future<void> socialMenuUi(Store node) async {
} else {
print("No threads to show where your follows participated in last $gHoursDefaultPrint hours.");
}
await processAnyIncomingEvents(node, true);
break;
case 7: // search word or event id
@ -1574,7 +1565,6 @@ Future<void> socialMenuUi(Store node) async {
}
}
}
await processAnyIncomingEvents(node, true);
break;

File diff suppressed because one or more lines are too long