[gnome-shell] search: Cancel search provider operations on clear
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] search: Cancel search provider operations on clear
- Date: Mon, 3 Sep 2018 23:06:28 +0000 (UTC)
commit c47a740c834d39a69cf0a828ade25738d8ab92ce
Author: Marco Trevisan (Treviño) <mail 3v1n0 net>
Date: Thu Aug 23 18:14:38 2018 +0200
search: Cancel search provider operations on clear
Ensure that the search provider operations (just getResultMetas requests
in the current implementation) in progress are properly cancelled when we
clear the UI, otherwise returned results might still be added when not
needed.
This is triggered for each provider by the SearchResults reset.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/205
js/ui/search.js | 1 +
1 file changed, 1 insertion(+)
---
diff --git a/js/ui/search.js b/js/ui/search.js
index 1fb54b4c9..804be9593 100644
--- a/js/ui/search.js
+++ b/js/ui/search.js
@@ -192,6 +192,7 @@ var SearchResultsBase = new Lang.Class({
},
clear() {
+ this._cancellable.cancel();
for (let resultId in this._resultDisplays)
this._resultDisplays[resultId].actor.destroy();
this._resultDisplays = {};
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]