Skip to content

Commit

Permalink
fix: Close Applictions on Main.overview.hide()
Browse files Browse the repository at this point in the history
This seems to work more correctly. It still closes on clicking an app
icon or search result, but also on "New Window", "Show Details", etc.

Fixes pop-os/beta#319.
  • Loading branch information
ids1024 authored and jackpot51 committed Nov 30, 2021
1 parent 2e54364 commit b39a3ef
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions extension.js
Original file line number Diff line number Diff line change
Expand Up @@ -451,15 +451,9 @@ function gnome_40_enable() {

applications.enable();

const appIcon_activate = AppDisplay.AppIcon.prototype.activate;
inject(AppDisplay.AppIcon.prototype, 'activate', function(button) {
appIcon_activate.call(this, button);
applications.hide();
});

const searchResult_activate = Search.SearchResult.prototype.activate;
inject(Search.SearchResult.prototype, 'activate', function() {
searchResult_activate.call(this);
const overview_hide = Main.overview.hide;
inject(Main.overview, 'hide', function() {
overview_hide.call(this);
applications.hide();
});
}
Expand Down

0 comments on commit b39a3ef

Please sign in to comment.