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

Side by Side Diff: chrome/browser/apps/drive/drive_app_mapping.h

Issue 308003005: app_list: Drive app integration. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: move to c/b/apps, add OWNERS Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_APPS_DRIVE_DRIVE_APP_MAPPING_H_
6 #define CHROME_BROWSER_APPS_DRIVE_DRIVE_APP_MAPPING_H_
7
8 #include <set>
9 #include <string>
10
11 #include "base/macros.h"
12
13 namespace user_prefs {
14 class PrefRegistrySyncable;
15 }
16
17 class PrefService;
18
19 namespace extensions {
20
21 // DriveAppMapping tracks the mapping between Drive apps and corresponding
22 // Chrome apps. The data is backed by kAppLauncherDriveAppMapping pref.
23 class DriveAppMapping {
24 public:
25 explicit DriveAppMapping(PrefService* prefs);
26 ~DriveAppMapping();
27
28 static void RegisterProfilePrefs(user_prefs::PrefRegistrySyncable* registry);
29
30 void Add(const std::string& drive_app_id, const std::string& chrome_app_id);
31 void Remove(const std::string& drive_app_id);
32
33 std::string GetChromeApp(const std::string& drive_app_id) const;
34 std::string GetDriveApp(const std::string& chrome_app_id) const;
35
36 std::set<std::string> GetDriveAppIds() const;
37
38 private:
39 PrefService* prefs_;
40
41 DISALLOW_COPY_AND_ASSIGN(DriveAppMapping);
42 };
43
44 } // namespace extensions
45
46 #endif // CHROME_BROWSER_APPS_DRIVE_DRIVE_APP_MAPPING_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698