app_list_view_controller.h revision c2e0dbddbe15c98d52c4786dac06cb8952a8ae6d
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_COCOA_APP_LIST_VIEW_CONTROLLER_H_ 6#define UI_APP_LIST_COCOA_APP_LIST_VIEW_CONTROLLER_H_ 7 8#import <Cocoa/Cocoa.h> 9 10#include "base/memory/scoped_nsobject.h" 11#include "base/memory/scoped_ptr.h" 12#include "ui/app_list/app_list_export.h" 13#import "ui/app_list/cocoa/apps_pagination_model_observer.h" 14 15namespace app_list { 16class AppListViewDelegate; 17} 18 19@class AppsGridController; 20 21// Controller for the top-level view of the app list UI. It creates and hosts an 22// AppsGridController (displaying an AppListModel), and pager control for 23// navigating between pages in the grid. 24APP_LIST_EXPORT 25@interface AppListViewController : 26 NSViewController<AppsPaginationModelObserver> { 27 @private 28 scoped_nsobject<AppsGridController> appsGridController_; 29 scoped_nsobject<NSSegmentedControl> pagerControl_; 30 scoped_ptr<app_list::AppListViewDelegate> delegate_; 31} 32 33- (AppsGridController*)appsGridController; 34 35- (NSSegmentedControl*)pagerControl; 36 37- (app_list::AppListViewDelegate*)delegate; 38 39- (void)setDelegate:(scoped_ptr<app_list::AppListViewDelegate>)newDelegate; 40 41@end 42 43#endif // UI_APP_LIST_COCOA_APP_LIST_VIEW_CONTROLLER_H_ 44