| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 #ifndef UI_MESSAGE_CENTER_COCOA_TRAY_VIEW_CONTROLLER_H_ | 5 #ifndef UI_MESSAGE_CENTER_COCOA_TRAY_VIEW_CONTROLLER_H_ |
| 6 #define UI_MESSAGE_CENTER_COCOA_TRAY_VIEW_CONTROLLER_H_ | 6 #define UI_MESSAGE_CENTER_COCOA_TRAY_VIEW_CONTROLLER_H_ |
| 7 | 7 |
| 8 #import <Cocoa/Cocoa.h> | 8 #import <Cocoa/Cocoa.h> |
| 9 | 9 |
| 10 #include <list> | 10 #include <list> |
| (...skipping 28 matching lines...) Expand all Loading... |
| 39 @private | 39 @private |
| 40 // Controller of the notifications, where action messages are forwarded. Weak. | 40 // Controller of the notifications, where action messages are forwarded. Weak. |
| 41 message_center::MessageCenter* messageCenter_; | 41 message_center::MessageCenter* messageCenter_; |
| 42 | 42 |
| 43 // The back button shown while the settings are open. | 43 // The back button shown while the settings are open. |
| 44 base::scoped_nsobject<HoverImageButton> backButton_; | 44 base::scoped_nsobject<HoverImageButton> backButton_; |
| 45 | 45 |
| 46 // The "Notifications" label at the top. | 46 // The "Notifications" label at the top. |
| 47 base::scoped_nsobject<NSTextField> title_; | 47 base::scoped_nsobject<NSTextField> title_; |
| 48 | 48 |
| 49 // The 1px horizontal divider between the scroll view and the title bar. |
| 50 base::scoped_nsobject<NSBox> divider_; |
| 51 |
| 52 // The "Nothing to see here" label in an empty message center. |
| 53 base::scoped_nsobject<NSTextField> emptyDescription_; |
| 54 |
| 49 // The scroll view that contains all the notifications in its documentView. | 55 // The scroll view that contains all the notifications in its documentView. |
| 50 base::scoped_nsobject<NSScrollView> scrollView_; | 56 base::scoped_nsobject<NSScrollView> scrollView_; |
| 51 | 57 |
| 52 // The clip view that manages how scrollView_'s documentView is clipped. | 58 // The clip view that manages how scrollView_'s documentView is clipped. |
| 53 base::scoped_nsobject<MCClipView> clipView_; | 59 base::scoped_nsobject<MCClipView> clipView_; |
| 54 | 60 |
| 55 // Array of MCNotificationController objects, which the array owns. | 61 // Array of MCNotificationController objects, which the array owns. |
| 56 base::scoped_nsobject<NSMutableArray> notifications_; | 62 base::scoped_nsobject<NSMutableArray> notifications_; |
| 57 | 63 |
| 58 // Map of notification IDs to weak pointers of the view controllers in | 64 // Map of notification IDs to weak pointers of the view controllers in |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 150 + (CGFloat)maxTrayClientHeight; | 156 + (CGFloat)maxTrayClientHeight; |
| 151 | 157 |
| 152 // Returns the width of the notifications tray. | 158 // Returns the width of the notifications tray. |
| 153 + (CGFloat)trayWidth; | 159 + (CGFloat)trayWidth; |
| 154 | 160 |
| 155 @end | 161 @end |
| 156 | 162 |
| 157 // Testing API ///////////////////////////////////////////////////////////////// | 163 // Testing API ///////////////////////////////////////////////////////////////// |
| 158 | 164 |
| 159 @interface MCTrayViewController (TestingAPI) | 165 @interface MCTrayViewController (TestingAPI) |
| 166 - (NSBox*)divider; |
| 167 - (NSTextField*)emptyDescription; |
| 160 - (NSScrollView*)scrollView; | 168 - (NSScrollView*)scrollView; |
| 161 - (HoverImageButton*)pauseButton; | 169 - (HoverImageButton*)pauseButton; |
| 162 - (HoverImageButton*)clearAllButton; | 170 - (HoverImageButton*)clearAllButton; |
| 163 | 171 |
| 164 // Setter for changing the animation duration. The testing code could set it | 172 // Setter for changing the animation duration. The testing code could set it |
| 165 // to a very small value to expedite the test running. | 173 // to a very small value to expedite the test running. |
| 166 - (void)setAnimationDuration:(NSTimeInterval)duration; | 174 - (void)setAnimationDuration:(NSTimeInterval)duration; |
| 167 | 175 |
| 168 // Setter for changing the clear-all animation delay. The testing code could set | 176 // Setter for changing the clear-all animation delay. The testing code could set |
| 169 // it to a very small value to expedite the test running. | 177 // it to a very small value to expedite the test running. |
| 170 - (void)setAnimateClearingNextNotificationDelay:(NSTimeInterval)delay; | 178 - (void)setAnimateClearingNextNotificationDelay:(NSTimeInterval)delay; |
| 171 | 179 |
| 172 // Setter for testingAnimationEndedCallback_. The testing code could set it | 180 // Setter for testingAnimationEndedCallback_. The testing code could set it |
| 173 // to get called back when the animation ends. | 181 // to get called back when the animation ends. |
| 174 - (void)setAnimationEndedCallback: | 182 - (void)setAnimationEndedCallback: |
| 175 (message_center::TrayAnimationEndedCallback)callback; | 183 (message_center::TrayAnimationEndedCallback)callback; |
| 176 @end | 184 @end |
| 177 | 185 |
| 178 #endif // UI_MESSAGE_CENTER_COCOA_TRAY_VIEW_CONTROLLER_H_ | 186 #endif // UI_MESSAGE_CENTER_COCOA_TRAY_VIEW_CONTROLLER_H_ |
| OLD | NEW |