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

Unified Diff: chrome/browser/ui/views/ash/launcher/launcher_app_tab_helper.cc

Issue 10855094: launcher: Remove old files and update DEPS whitelist. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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/views/ash/launcher/launcher_app_tab_helper.cc
diff --git a/chrome/browser/ui/views/ash/launcher/launcher_app_tab_helper.cc b/chrome/browser/ui/views/ash/launcher/launcher_app_tab_helper.cc
deleted file mode 100644
index 045334105835dcd048696a02f5f7f80dd256d754..0000000000000000000000000000000000000000
--- a/chrome/browser/ui/views/ash/launcher/launcher_app_tab_helper.cc
+++ /dev/null
@@ -1,47 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "chrome/browser/ui/views/ash/launcher/launcher_app_tab_helper.h"
-
-#include "chrome/browser/extensions/extension_service.h"
-#include "chrome/browser/profiles/profile.h"
-#include "chrome/browser/ui/tab_contents/tab_contents.h"
-#include "chrome/common/extensions/extension.h"
-#include "content/public/browser/web_contents.h"
-
-namespace {
-
-const extensions::Extension* GetExtensionForTab(Profile* profile,
- TabContents* tab) {
- ExtensionService* extension_service = profile->GetExtensionService();
- if (!extension_service)
- return NULL;
- return extension_service->GetInstalledApp(tab->web_contents()->GetURL());
-}
-
-const extensions::Extension* GetExtensionByID(Profile* profile,
- const std::string& id) {
- ExtensionService* service = profile->GetExtensionService();
- if (!service)
- return NULL;
- return service->extensions()->GetByID(id);
-}
-
-} // namespace
-
-LauncherAppTabHelper::LauncherAppTabHelper(Profile* profile)
- : profile_(profile) {
-}
-
-LauncherAppTabHelper::~LauncherAppTabHelper() {
-}
-
-std::string LauncherAppTabHelper::GetAppID(TabContents* tab) {
- const extensions::Extension* extension = GetExtensionForTab(profile_, tab);
- return extension ? extension->id() : std::string();
-}
-
-bool LauncherAppTabHelper::IsValidID(const std::string& id) {
- return GetExtensionByID(profile_, id) != NULL;
-}

Powered by Google App Engine
This is Rietveld 408576698