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

Unified Diff: chrome/browser/chromeos/arc/arc_support_host.cc

Issue 2615793002: arc: Fix situation when ARC cannot be disabled safely. (Closed)
Patch Set: Created 3 years, 11 months 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
Index: chrome/browser/chromeos/arc/arc_support_host.cc
diff --git a/chrome/browser/chromeos/arc/arc_support_host.cc b/chrome/browser/chromeos/arc/arc_support_host.cc
index ec1bbfd5352c1237908ce253255b60c22f7a423c..b3ba94a88d08204d1314496e25d24326b1c722f3 100644
--- a/chrome/browser/chromeos/arc/arc_support_host.cc
+++ b/chrome/browser/chromeos/arc/arc_support_host.cc
@@ -365,9 +365,16 @@ void ArcSupportHost::SetMessageHost(arc::ArcSupportMessageHost* message_host) {
void ArcSupportHost::UnsetMessageHost(
arc::ArcSupportMessageHost* message_host) {
- if (message_host_ != message_host)
- return;
- DisconnectMessageHost();
+ if (message_host_ == message_host)
+ DisconnectMessageHost();
+
+ // There is possible scenario when page is requested to close and then
+ // requested to show again soon. In this case OpenApplication may be ignored
hidehiko 2017/01/05 08:18:02 Who ignores the OpenApplication()? I couldn't find
khmel 2017/01/05 22:55:53 Sorry, I don't exactly know code that prevents run
hidehiko 2017/01/06 14:25:36 I'm not against fixing ArcSupportHost, rather if t
khmel 2017/01/10 02:17:12 Acknowledged.
+ // because app is still
+ // active. Now, when app is finally closed and pending request is open,
+ // try to open app again.
+ if (app_start_pending_)
+ request_open_app_callback_.Run(profile_);
}
void ArcSupportHost::DisconnectMessageHost() {

Powered by Google App Engine
This is Rietveld 408576698