| OLD | NEW |
| 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_EXTENSIONS_EXTENSION_INSTALL_UI_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_UI_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_UI_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_UI_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| 11 | 11 |
| 12 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
| 13 #include "base/string16.h" | 13 #include "base/string16.h" |
| 14 #include "chrome/browser/extensions/image_loading_tracker.h" | 14 #include "chrome/browser/extensions/image_loading_tracker.h" |
| 15 #include "chrome/common/extensions/url_pattern.h" | 15 #include "chrome/common/extensions/url_pattern.h" |
| 16 #include "third_party/skia/include/core/SkBitmap.h" | 16 #include "third_party/skia/include/core/SkBitmap.h" |
| 17 #include "ui/gfx/image/image.h" | 17 #include "ui/gfx/image/image.h" |
| 18 #include "ui/gfx/image/image_skia.h" |
| 18 #include "ui/gfx/native_widget_types.h" | 19 #include "ui/gfx/native_widget_types.h" |
| 19 | 20 |
| 20 class Browser; | 21 class Browser; |
| 21 class ExtensionPermissionSet; | 22 class ExtensionPermissionSet; |
| 22 class MessageLoop; | 23 class MessageLoop; |
| 23 class Profile; | 24 class Profile; |
| 24 class InfoBarDelegate; | 25 class InfoBarDelegate; |
| 25 class TabContents; | 26 class TabContents; |
| 26 typedef TabContents TabContentsWrapper; | 27 typedef TabContents TabContentsWrapper; |
| 27 | 28 |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 string16 GetAbortButtonLabel() const; | 74 string16 GetAbortButtonLabel() const; |
| 74 string16 GetPermissionsHeading() const; | 75 string16 GetPermissionsHeading() const; |
| 75 | 76 |
| 76 // Getters for webstore metadata. Only populated when the type is | 77 // Getters for webstore metadata. Only populated when the type is |
| 77 // INLINE_INSTALL_PROMPT. | 78 // INLINE_INSTALL_PROMPT. |
| 78 | 79 |
| 79 // The star display logic replicates the one used by the webstore (from | 80 // The star display logic replicates the one used by the webstore (from |
| 80 // components.ratingutils.setFractionalYellowStars). Callers pass in an | 81 // components.ratingutils.setFractionalYellowStars). Callers pass in an |
| 81 // "appender", which will be repeatedly called back with the star images | 82 // "appender", which will be repeatedly called back with the star images |
| 82 // that they append to the star display area. | 83 // that they append to the star display area. |
| 83 typedef void(*StarAppender)(const SkBitmap*, void*); | 84 typedef void(*StarAppender)(const gfx::ImageSkia*, void*); |
| 84 void AppendRatingStars(StarAppender appender, void* data) const; | 85 void AppendRatingStars(StarAppender appender, void* data) const; |
| 85 string16 GetRatingCount() const; | 86 string16 GetRatingCount() const; |
| 86 string16 GetUserCount() const; | 87 string16 GetUserCount() const; |
| 87 size_t GetPermissionCount() const; | 88 size_t GetPermissionCount() const; |
| 88 string16 GetPermission(size_t index) const; | 89 string16 GetPermission(size_t index) const; |
| 89 | 90 |
| 90 // Populated for BUNDLE_INSTALL_PROMPT. | 91 // Populated for BUNDLE_INSTALL_PROMPT. |
| 91 const extensions::BundleInstaller* bundle() const { return bundle_; } | 92 const extensions::BundleInstaller* bundle() const { return bundle_; } |
| 92 void set_bundle(const extensions::BundleInstaller* bundle) { | 93 void set_bundle(const extensions::BundleInstaller* bundle) { |
| 93 bundle_ = bundle; | 94 bundle_ = bundle; |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 298 | 299 |
| 299 // Whether to show an installed bubble on app install, or use the default | 300 // Whether to show an installed bubble on app install, or use the default |
| 300 // action of opening a new tab page. | 301 // action of opening a new tab page. |
| 301 bool use_app_installed_bubble_; | 302 bool use_app_installed_bubble_; |
| 302 | 303 |
| 303 // Whether or not to show the default UI after completing the installation. | 304 // Whether or not to show the default UI after completing the installation. |
| 304 bool skip_post_install_ui_; | 305 bool skip_post_install_ui_; |
| 305 }; | 306 }; |
| 306 | 307 |
| 307 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_UI_H_ | 308 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_INSTALL_UI_H_ |
| OLD | NEW |