Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11)

Side by Side Diff: ash/system/tray/system_tray_item.h

Issue 10332152: Add TraySms for SMS messages. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix bubble sizing code Created 8 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ash/system/tray/system_tray_bubble.cc ('k') | ash/system/tray/system_tray_item.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef ASH_SYSTEM_TRAY_SYSTEM_TRAY_ITEM_H_ 5 #ifndef ASH_SYSTEM_TRAY_SYSTEM_TRAY_ITEM_H_
6 #define ASH_SYSTEM_TRAY_SYSTEM_TRAY_ITEM_H_ 6 #define ASH_SYSTEM_TRAY_SYSTEM_TRAY_ITEM_H_
7 #pragma once 7 #pragma once
8 8
9 #include "ash/ash_export.h" 9 #include "ash/ash_export.h"
10 #include "ash/system/user/login_status.h" 10 #include "ash/system/user/login_status.h"
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 // These functions are called when the corresponding view item is about to be 48 // These functions are called when the corresponding view item is about to be
49 // removed. An item should do appropriate cleanup in these functions. 49 // removed. An item should do appropriate cleanup in these functions.
50 // The default implementation does nothing. 50 // The default implementation does nothing.
51 virtual void DestroyTrayView(); 51 virtual void DestroyTrayView();
52 virtual void DestroyDefaultView(); 52 virtual void DestroyDefaultView();
53 virtual void DestroyDetailedView(); 53 virtual void DestroyDetailedView();
54 virtual void DestroyNotificationView(); 54 virtual void DestroyNotificationView();
55 55
56 // Updates the tray view (if applicable) when the user's login status changes. 56 // Updates the tray view (if applicable) when the user's login status changes.
57 // It is not necessary the update the default or detailed view, since the 57 // It is not necessary the update the default or detailed view, since the
58 // default/detailed popup is closed when login status changes. 58 // default/detailed popup is closed when login status changes. The default
59 virtual void UpdateAfterLoginStatusChange(user::LoginStatus status) = 0; 59 // implementation does nothing.
60 virtual void UpdateAfterLoginStatusChange(user::LoginStatus status);
60 61
61 // Shows the detailed view for this item. If the main popup for the tray is 62 // Shows the detailed view for this item. If the main popup for the tray is
62 // currently visible, then making this call would use the existing window to 63 // currently visible, then making this call would use the existing window to
63 // display the detailed item. The detailed item will inherit the bounds of the 64 // display the detailed item. The detailed item will inherit the bounds of the
64 // existing window. 65 // existing window.
65 // If there is no existing view, then this is equivalent to calling 66 // If there is no existing view, then this is equivalent to calling
66 // PopupDetailedView(0, true). 67 // PopupDetailedView(0, true).
67 void TransitionDetailedView(); 68 void TransitionDetailedView();
68 69
69 // Pops up the detailed view for this item. An item can request to show its 70 // Pops up the detailed view for this item. An item can request to show its
70 // detailed view using this function (e.g. from an observer callback when 71 // detailed view using this function (e.g. from an observer callback when
71 // something, e.g. volume, network availability etc. changes). If 72 // something, e.g. volume, network availability etc. changes). If
72 // |for_seconds| is non-zero, then the popup is closed after the specified 73 // |for_seconds| is non-zero, then the popup is closed after the specified
73 // time. 74 // time.
74 void PopupDetailedView(int for_seconds, bool activate); 75 void PopupDetailedView(int for_seconds, bool activate);
75 76
76 // Continue showing the currently-shown detailed view, if any, for 77 // Continue showing the currently-shown detailed view, if any, for
77 // |for_seconds| seconds. The caller is responsible for checking that the 78 // |for_seconds| seconds. The caller is responsible for checking that the
78 // currently-shown view is for this item. 79 // currently-shown view is for this item.
79 void SetDetailedViewCloseDelay(int for_seconds); 80 void SetDetailedViewCloseDelay(int for_seconds);
80 81
82 // Hides the detailed view for this item.
83 void HideDetailedView();
84
81 // Shows a notification for this item. 85 // Shows a notification for this item.
82 void ShowNotificationView(); 86 void ShowNotificationView();
83 87
84 // Hides the notification for this item. 88 // Hides the notification for this item.
85 void HideNotificationView(); 89 void HideNotificationView();
86 90
87 private: 91 private:
88 92
89 DISALLOW_COPY_AND_ASSIGN(SystemTrayItem); 93 DISALLOW_COPY_AND_ASSIGN(SystemTrayItem);
90 }; 94 };
91 95
92 } // namespace ash 96 } // namespace ash
93 97
94 #endif // ASH_SYSTEM_TRAY_SYSTEM_TRAY_ITEM_H_ 98 #endif // ASH_SYSTEM_TRAY_SYSTEM_TRAY_ITEM_H_
OLDNEW
« no previous file with comments | « ash/system/tray/system_tray_bubble.cc ('k') | ash/system/tray/system_tray_item.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698