Skip to content

Commit

Permalink
improved processAnyIncomingEvents in social UI menu. moved events fil…
Browse files Browse the repository at this point in the history
…e to scripts/
  • Loading branch information
vishalxl committed Sep 29, 2024
1 parent cf3ef9f commit 522533d
Show file tree
Hide file tree
Showing 3 changed files with 1,530 additions and 10 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,6 @@ doc/api/
*.js.map
del*.txt
bin/nostr_console_win64.exe
all_nostr_events.txt
*.exe
*.zip
10 changes: 0 additions & 10 deletions lib/console_ui.dart
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand All @@ -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:
Expand Down Expand Up @@ -1416,7 +1412,6 @@ Future<void> socialMenuUi(Store node) async {
await sendReplyPostLike(node, replyToId, replyKind, content);
clearScreen();

await processAnyIncomingEvents(node, true);
break;

case 3:
Expand All @@ -1430,7 +1425,6 @@ Future<void> socialMenuUi(Store node) async {
print("No replies or likes.");
}

await processAnyIncomingEvents(node, true);
break;
case 4:
clearScreen();
Expand All @@ -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();
Expand All @@ -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:
Expand All @@ -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
Expand Down Expand Up @@ -1574,7 +1565,6 @@ Future<void> socialMenuUi(Store node) async {
}
}
}
await processAnyIncomingEvents(node, true);
break;


Expand Down
Loading

0 comments on commit 522533d

Please sign in to comment.