diff --git a/CHANGELOG.md b/CHANGELOG.md index 8f7ebc7a..cc4499cc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -22,6 +22,7 @@ - Bugfix: Fixed highlights triggering from own resub messages. (#3707) - Bugfix: Fixed existing emote popups not being raised from behind other windows when refocusing them on macOS (#3713) - Bugfix: Fixed automod queue pubsub topic persisting after user change. (#3718) +- Bugfix: Fixed viewer list not closing after pressing escape key. (#3734) - Dev: Use Game Name returned by Get Streams instead of querying it from the Get Games API. (#3662) ## 2.3.5 diff --git a/src/widgets/splits/Split.cpp b/src/widgets/splits/Split.cpp index b67b8c56..8ee377f4 100644 --- a/src/widgets/splits/Split.cpp +++ b/src/widgets/splits/Split.cpp @@ -1067,6 +1067,27 @@ void Split::showViewerList() listDoubleClick(resultList->currentItem()->text()); }); + HotkeyController::HotkeyMap actions{ + {"delete", + [viewerDock](std::vector) -> QString { + viewerDock->close(); + return ""; + }}, + {"accept", nullptr}, + {"reject", nullptr}, + {"scrollPage", nullptr}, + {"openTab", nullptr}, + {"search", + [searchBar](std::vector) -> QString { + searchBar->setFocus(); + searchBar->selectAll(); + return ""; + }}, + }; + + getApp()->hotkeys->shortcutsForCategory(HotkeyCategory::PopupWindow, + actions, viewerDock); + dockVbox->addWidget(searchBar); dockVbox->addWidget(loadingLabel); dockVbox->addWidget(chattersList);