Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3896)

Unified Diff: chrome/browser/ui/ash/launcher/browser_status_monitor.cc

Issue 55303003: Fixing drag and drop visibility issues of tabs on a visiting desktop (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/ui/ash/multi_user_window_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/ash/launcher/browser_status_monitor.cc
diff --git a/chrome/browser/ui/ash/launcher/browser_status_monitor.cc b/chrome/browser/ui/ash/launcher/browser_status_monitor.cc
index 2a925bc60d7ac97f4ea9f6a509632ac8640aae5d..2f1b5262c16e98e429c81f7fa425fc400cf6c622 100644
--- a/chrome/browser/ui/ash/launcher/browser_status_monitor.cc
+++ b/chrome/browser/ui/ash/launcher/browser_status_monitor.cc
@@ -97,8 +97,10 @@ void BrowserStatusMonitor::UpdateAppItemState(
content::WebContents* contents,
ChromeLauncherController::AppState app_state) {
DCHECK(contents);
- if (launcher_controller_->IsBrowserFromActiveUser(
- chrome::FindBrowserWithWebContents(contents)))
+ // It is possible to come here from Browser::SwapTabContent where the contents
+ // cannot be associated with a browser.
+ Browser* browser = chrome::FindBrowserWithWebContents(contents);
+ if (browser && launcher_controller_->IsBrowserFromActiveUser(browser))
launcher_controller_->UpdateAppState(contents, app_state);
}
« no previous file with comments | « no previous file | chrome/browser/ui/ash/multi_user_window_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698