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

Unified Diff: chrome/browser/ui/toolbar/component_toolbar_actions_factory.cc

Issue 2332693003: Show media router toolbar icon ephemerally for active local routes and issues (Closed)
Patch Set: Created 4 years, 3 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/ui/toolbar/component_toolbar_actions_factory.cc
diff --git a/chrome/browser/ui/toolbar/component_toolbar_actions_factory.cc b/chrome/browser/ui/toolbar/component_toolbar_actions_factory.cc
index 487a59a88d9ba57f538fb13f71c930c0a21db8ee..f5caf416c39ac2acde264880c6604e5153579d8a 100644
--- a/chrome/browser/ui/toolbar/component_toolbar_actions_factory.cc
+++ b/chrome/browser/ui/toolbar/component_toolbar_actions_factory.cc
@@ -8,6 +8,7 @@
#include "base/lazy_instance.h"
#include "chrome/browser/extensions/component_migration_helper.h"
#include "chrome/browser/media/router/media_router_feature.h"
+#include "chrome/browser/media/router/media_router_ui_service.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/toolbar/toolbar_action_view_controller.h"
@@ -94,3 +95,8 @@ void ComponentToolbarActionsFactory::HandleComponentMigrations(
}
}
+void ComponentToolbarActionsFactory::InitializeComponentActionControllers(
+ Profile* profile) {
+ if (media_router::MediaRouterEnabled(profile))
+ media_router::MediaRouterUIService::Get(profile);
Devlin 2016/09/15 21:19:17 Would this same effect be achieved by KeyedService
takumif 2016/09/16 21:19:22 Yes, using ServiceIsCreatedWithContext() (didn't k
+}

Powered by Google App Engine
This is Rietveld 408576698