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

Side by Side Diff: chrome/browser/banners/app_banner_manager.h

Issue 2611623003: Use exact pixel sizes instead of dip in webapp/WebAPK installability code (Closed)
Patch Set: Rebased version of pkotwicz@'s original patch 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_BANNERS_APP_BANNER_MANAGER_H_ 5 #ifndef CHROME_BROWSER_BANNERS_APP_BANNER_MANAGER_H_
6 #define CHROME_BROWSER_BANNERS_APP_BANNER_MANAGER_H_ 6 #define CHROME_BROWSER_BANNERS_APP_BANNER_MANAGER_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 109
110 // Return a string describing what type of banner is being created. Used when 110 // Return a string describing what type of banner is being created. Used when
111 // alerting websites that a banner is about to be created. 111 // alerting websites that a banner is about to be created.
112 virtual std::string GetBannerType(); 112 virtual std::string GetBannerType();
113 113
114 // Returns a string parameter for a devtools console message corresponding to 114 // Returns a string parameter for a devtools console message corresponding to
115 // |code|. Returns the empty string if |code| requires no parameter. 115 // |code|. Returns the empty string if |code| requires no parameter.
116 std::string GetStatusParam(InstallableStatusCode code); 116 std::string GetStatusParam(InstallableStatusCode code);
117 117
118 // Returns the ideal and minimum icon sizes required for being installable. 118 // Returns the ideal and minimum icon sizes required for being installable.
119 virtual int GetIdealIconSizeInDp(); 119 virtual int GetIdealIconSizeInPx();
120 virtual int GetMinimumIconSizeInDp(); 120 virtual int GetMinimumIconSizeInPx();
121 121
122 // Returns a WeakPtr to this object. Exposed so subclasses/infobars may 122 // Returns a WeakPtr to this object. Exposed so subclasses/infobars may
123 // may bind callbacks without needing their own WeakPtrFactory. 123 // may bind callbacks without needing their own WeakPtrFactory.
124 base::WeakPtr<AppBannerManager> GetWeakPtr(); 124 base::WeakPtr<AppBannerManager> GetWeakPtr();
125 125
126 // Returns true if |is_debug_mode_| is true or the 126 // Returns true if |is_debug_mode_| is true or the
127 // kBypassAppBannerEngagementChecks flag is set. 127 // kBypassAppBannerEngagementChecks flag is set.
128 virtual bool IsDebugMode() const; 128 virtual bool IsDebugMode() const;
129 129
130 // Returns true if the webapp at |start_url| has already been installed. 130 // Returns true if the webapp at |start_url| has already been installed.
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 // scoped to the WebContents which they are observing. This allows us to use 274 // scoped to the WebContents which they are observing. This allows us to use
275 // weak pointers for callbacks. 275 // weak pointers for callbacks.
276 base::WeakPtrFactory<AppBannerManager> weak_factory_; 276 base::WeakPtrFactory<AppBannerManager> weak_factory_;
277 277
278 DISALLOW_COPY_AND_ASSIGN(AppBannerManager); 278 DISALLOW_COPY_AND_ASSIGN(AppBannerManager);
279 }; 279 };
280 280
281 } // namespace banners 281 } // namespace banners
282 282
283 #endif // CHROME_BROWSER_BANNERS_APP_BANNER_MANAGER_H_ 283 #endif // CHROME_BROWSER_BANNERS_APP_BANNER_MANAGER_H_
OLDNEW
« no previous file with comments | « chrome/browser/android/webapps/add_to_homescreen_manager.cc ('k') | chrome/browser/banners/app_banner_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698