- add sources.
[platform/framework/web/crosswalk.git] / src / chrome / browser / ui / cocoa / download / download_shelf_context_menu_controller.h
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 #import <Cocoa/Cocoa.h>
6
7 #import "ui/base/cocoa/menu_controller.h"
8 #include "base/mac/scoped_nsobject.h"
9
10 @class DownloadItemController;
11
12 // MenuController that retains a DownloadItemController and instantiates a menu
13 // based on the contextMenuModel from the DownloadItemController.
14 @interface DownloadShelfContextMenuController : MenuController {
15  @private
16   base::scoped_nsobject<DownloadItemController> itemController_;
17   id<NSMenuDelegate> menuDelegate_;
18 }
19
20 // Initializes the MenuController using [itemController contextMenuModel].
21 // menuDelegate will be sent a menuDidClose message when the menu closes.
22 - (id)initWithItemController:(DownloadItemController*)itemController
23                 withDelegate:(id<NSMenuDelegate>)menuDelegate;
24
25 - (void)menuDidClose:(NSMenu*)menu;
26 @end