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.
5 #ifndef UI_APP_LIST_VIEWS_TILE_ITEM_VIEW_H_
6 #define UI_APP_LIST_VIEWS_TILE_ITEM_VIEW_H_
8 #include "ui/views/controls/button/button.h"
9 #include "ui/views/controls/button/custom_button.h"
20 // The view for a tile in the app list on the start/search page.
21 class TileItemView
: public views::CustomButton
, public views::ButtonListener
{
24 virtual ~TileItemView();
26 void SetAppListItem(AppListItem
* item
);
29 class TileItemBackground
;
31 // Overridden from views::View:
32 virtual gfx::Size
GetPreferredSize() const OVERRIDE
;
34 // Overridden from views::ButtonListener:
35 virtual void ButtonPressed(views::Button
* sender
,
36 const ui::Event
& event
) OVERRIDE
;
38 // Owned by the model provided by the AppListViewDelegate.
41 views::ImageView
* icon_
; // Owned by views hierarchy.
42 views::Label
* title_
; // Owned by views hierarchy.
44 TileItemBackground
* background_
;
46 DISALLOW_COPY_AND_ASSIGN(TileItemView
);
49 } // namespace app_list
51 #endif // UI_APP_LIST_VIEWS_TILE_ITEM_VIEW_H_