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

Side by Side Diff: chrome/browser/web_applications/web_app.h

Issue 12881003: ShortcutInfo::favicon is now a gfx::ImageFamily instead of gfx::Image. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebase to HEAD. Created 7 years, 8 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_H_ 5 #ifndef CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_H_
6 #define CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_H_ 6 #define CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/files/file_path.h" 11 #include "base/files/file_path.h"
12 #include "build/build_config.h" 12 #include "build/build_config.h"
13 #include "chrome/browser/shell_integration.h" 13 #include "chrome/browser/shell_integration.h"
14 #include "chrome/common/web_apps.h" 14 #include "chrome/common/web_apps.h"
15 15
16 namespace extensions { 16 namespace extensions {
17 class Extension; 17 class Extension;
18 } 18 }
19 19
20 namespace gfx {
21 class ImageFamily;
22 }
23
20 namespace web_app { 24 namespace web_app {
21 25
22 // Gets the user data directory for given web app. The path for the directory is 26 // Gets the user data directory for given web app. The path for the directory is
23 // based on |extension_id|. If |extension_id| is empty then |url| is used 27 // based on |extension_id|. If |extension_id| is empty then |url| is used
24 // to construct a unique ID. 28 // to construct a unique ID.
25 base::FilePath GetWebAppDataDirectory(const base::FilePath& profile_path, 29 base::FilePath GetWebAppDataDirectory(const base::FilePath& profile_path,
26 const std::string& extension_id, 30 const std::string& extension_id,
27 const GURL& url); 31 const GURL& url);
28 32
29 // Gets the user data directory to use for |extension| located inside 33 // Gets the user data directory to use for |extension| located inside
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 #if defined(TOOLKIT_GTK) 87 #if defined(TOOLKIT_GTK)
84 // GTK+ windows that correspond to web apps need to have a deterministic (and 88 // GTK+ windows that correspond to web apps need to have a deterministic (and
85 // different) WMClass than normal chrome windows so the window manager groups 89 // different) WMClass than normal chrome windows so the window manager groups
86 // them as a separate application. 90 // them as a separate application.
87 std::string GetWMClassFromAppName(std::string app_name); 91 std::string GetWMClassFromAppName(std::string app_name);
88 #endif 92 #endif
89 93
90 namespace internals { 94 namespace internals {
91 95
92 #if defined(OS_WIN) 96 #if defined(OS_WIN)
93 bool CheckAndSaveIcon(const base::FilePath& icon_file, const SkBitmap& image); 97 bool CheckAndSaveIcon(const base::FilePath& icon_file,
98 const gfx::ImageFamily& image);
94 #endif 99 #endif
95 100
96 // Implemented for each platform, does the platform specific parts of creating 101 // Implemented for each platform, does the platform specific parts of creating
97 // shortcuts. Used internally by CreateShortcutsOnFileThread. 102 // shortcuts. Used internally by CreateShortcutsOnFileThread.
98 // |shortcut_data_path| is where to store any resources created for the 103 // |shortcut_data_path| is where to store any resources created for the
99 // shortcut, and is also used as the UserDataDir for platform app shortcuts. 104 // shortcut, and is also used as the UserDataDir for platform app shortcuts.
100 // |shortcut_info| contains info about the shortcut to create, and 105 // |shortcut_info| contains info about the shortcut to create, and
101 // |creation_locations| contains information about where to create them. 106 // |creation_locations| contains information about where to create them.
102 bool CreatePlatformShortcuts( 107 bool CreatePlatformShortcuts(
103 const base::FilePath& shortcut_data_path, 108 const base::FilePath& shortcut_data_path,
(...skipping 16 matching lines...) Expand all
120 125
121 // Sanitizes |name| and returns a version of it that is safe to use as an 126 // Sanitizes |name| and returns a version of it that is safe to use as an
122 // on-disk file name . 127 // on-disk file name .
123 base::FilePath GetSanitizedFileName(const string16& name); 128 base::FilePath GetSanitizedFileName(const string16& name);
124 129
125 } // namespace internals 130 } // namespace internals
126 131
127 } // namespace web_app 132 } // namespace web_app
128 133
129 #endif // CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_H_ 134 #endif // CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698