OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #import "chrome/browser/ui/cocoa/download/download_item_controller.h" | 5 #import "chrome/browser/ui/cocoa/download/download_item_controller.h" |
6 | 6 |
7 #include "base/mac/bundle_locations.h" | 7 #include "base/mac/bundle_locations.h" |
8 #include "base/metrics/histogram.h" | 8 #include "base/metrics/histogram.h" |
9 #include "base/strings/string16.h" | 9 #include "base/strings/string16.h" |
10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 [contentView setAutoresizesSubviews:YES]; | 68 [contentView setAutoresizesSubviews:YES]; |
69 } | 69 } |
70 } | 70 } |
71 | 71 |
72 } // namespace | 72 } // namespace |
73 | 73 |
74 class DownloadShelfContextMenuMac : public DownloadShelfContextMenu { | 74 class DownloadShelfContextMenuMac : public DownloadShelfContextMenu { |
75 public: | 75 public: |
76 DownloadShelfContextMenuMac(DownloadItem* downloadItem, | 76 DownloadShelfContextMenuMac(DownloadItem* downloadItem, |
77 content::PageNavigator* navigator) | 77 content::PageNavigator* navigator) |
78 : DownloadShelfContextMenu(downloadItem, navigator) { } | 78 : DownloadShelfContextMenu(downloadItem) { } |
79 | 79 |
80 // DownloadShelfContextMenu::GetMenuModel is protected. | 80 // DownloadShelfContextMenu::GetMenuModel is protected. |
81 using DownloadShelfContextMenu::GetMenuModel; | 81 using DownloadShelfContextMenu::GetMenuModel; |
82 }; | 82 }; |
83 | 83 |
84 @interface DownloadItemController (Private) | 84 @interface DownloadItemController (Private) |
85 - (void)themeDidChangeNotification:(NSNotification*)aNotification; | 85 - (void)themeDidChangeNotification:(NSNotification*)aNotification; |
86 - (void)updateTheme:(ui::ThemeProvider*)themeProvider; | 86 - (void)updateTheme:(ui::ThemeProvider*)themeProvider; |
87 - (void)setState:(DownloadItemState)state; | 87 - (void)setState:(DownloadItemState)state; |
88 - (void)initExperienceSamplingEvent:(const char*)event; | 88 - (void)initExperienceSamplingEvent:(const char*)event; |
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
373 base::scoped_nsobject<DownloadShelfContextMenuController> menuController( | 373 base::scoped_nsobject<DownloadShelfContextMenuController> menuController( |
374 [[DownloadShelfContextMenuController alloc] | 374 [[DownloadShelfContextMenuController alloc] |
375 initWithItemController:self | 375 initWithItemController:self |
376 withDelegate:nil]); | 376 withDelegate:nil]); |
377 [NSMenu popUpContextMenu:[menuController menu] | 377 [NSMenu popUpContextMenu:[menuController menu] |
378 withEvent:[NSApp currentEvent] | 378 withEvent:[NSApp currentEvent] |
379 forView:[self view]]; | 379 forView:[self view]]; |
380 } | 380 } |
381 | 381 |
382 @end | 382 @end |
OLD | NEW |