Home | History | Annotate | Download | only in views
      1 // Copyright 2013 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.
      4 
      5 #ifndef UI_APP_LIST_VIEWS_FOLDER_HEADER_VIEW_DELEGATE_H_
      6 #define UI_APP_LIST_VIEWS_FOLDER_HEADER_VIEW_DELEGATE_H_
      7 
      8 #include <string>
      9 
     10 namespace ui {
     11 class Event;
     12 }
     13 
     14 namespace app_list {
     15 
     16 class AppListFolderItem;
     17 
     18 class FolderHeaderViewDelegate {
     19  public:
     20   // Invoked when the back button on the folder header view is clicked.
     21   // |item| is the folder item which FolderHeaderview represents.
     22   // |event_flags| contains the flags of the keyboard/mouse event that triggers
     23   // the request.
     24   virtual void NavigateBack(AppListFolderItem* item,
     25                             const ui::Event& event_flags) = 0;
     26 
     27   // Gives back the focus to the search box.
     28   virtual void GiveBackFocusToSearchBox() = 0;
     29 
     30   // Tells the model to set the name of |item|.
     31   virtual void SetItemName(AppListFolderItem* item,
     32                            const std::string& name) = 0;
     33 
     34   virtual ~FolderHeaderViewDelegate() {}
     35 };
     36 
     37 }  // namespace app_list
     38 
     39 #endif  // UI_APP_LIST_VIEWS_FOLDER_HEADER_VIEW_DELEGATE_H_
     40