Index: chrome/browser/ui/views/app_list/win/activation_tracker_win.cc |
diff --git a/chrome/browser/ui/views/app_list/win/activation_tracker_win.cc b/chrome/browser/ui/views/app_list/win/activation_tracker_win.cc |
index f4ab2fe2bbae529a653286fba1bc3f0e75d62970..df652d74f7faefa61a81c5199c593f67d7bce7fa 100644 |
--- a/chrome/browser/ui/views/app_list/win/activation_tracker_win.cc |
+++ b/chrome/browser/ui/views/app_list/win/activation_tracker_win.cc |
@@ -7,6 +7,7 @@ |
#include "base/time/time.h" |
#include "chrome/browser/ui/app_list/app_list_shower_views.h" |
#include "chrome/browser/ui/views/app_list/win/app_list_service_win.h" |
+#include "ui/app_list/app_list_switches.h" |
#include "ui/app_list/views/app_list_view.h" |
#include "ui/views/widget/widget.h" |
@@ -59,10 +60,14 @@ bool ActivationTrackerWin::ShouldDismissAppList() { |
// necessary to allow the launcher to be pinned or closed via the taskbar |
// context menu. This will return true to dismiss the app launcher unless one |
// of the following conditions are met: |
+ // - the switch preventing app list dismissal on blur is active, or |
// - the app launcher is focused, or |
// - the taskbar's jump list is focused, or |
// - the taskbar is focused with the right mouse button pressed. |
+ if (app_list::switches::ShouldNotDismissOnBlur()) |
+ return false; |
+ |
// Remember if the taskbar had focus without the right mouse button being |
// down. |
bool taskbar_had_focus = taskbar_has_focus_; |