public ExtensionEnableFlowDelegate,
public app_list::AppContextMenuDelegate {
public:
+ static const char kItemType[];
+
ExtensionAppItem(Profile* profile,
const app_list::AppListSyncableService::SyncItem* sync_item,
const std::string& extension_id,
// it gray.
void UpdateIcon();
+ // Only updates the icon if the overlay needs to be added/removed.
+ void UpdateIconOverlay();
+
// Update page and app launcher ordinals to put the app in between |prev| and
// |next|. Note that |prev| and |next| could be NULL when the app is put at
// the beginning or at the end.
const std::string& extension_id() const { return extension_id_; }
const std::string& extension_name() const { return extension_name_; }
- static const char kItemType[];
-
private:
// Gets extension associated with this model. Returns NULL if extension
// no longer exists.
// Private equivalent to Activate(), without refocus for already-running apps.
void Launch(int event_flags);
- // Whether or not the app item has an overlay.
- bool HasOverlay() const;
+ // Whether or not the app item needs an overlay.
+ bool NeedsOverlay() const;
// Overridden from extensions::IconImage::Observer:
virtual void OnExtensionIconImageChanged(
// Whether or not this app is a platform app.
bool is_platform_app_;
+ // Whether this app item has an overlay.
+ bool has_overlay_;
+
DISALLOW_COPY_AND_ASSIGN(ExtensionAppItem);
};