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

Side by Side Diff: ash/system/chromeos/tray_tracing.h

Issue 2091953002: mash: Move TrayTracing to //ash/common/system/chromeos (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments Created 4 years, 6 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
« no previous file with comments | « ash/common/system/tray/wm_system_tray_notifier.cc ('k') | ash/system/chromeos/tray_tracing.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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 ASH_SYSTEM_TRAY_TRACING_H_
6 #define ASH_SYSTEM_TRAY_TRACING_H_
7
8 #include "ash/ash_export.h"
9 #include "ash/common/system/tray/tray_image_item.h"
10 #include "base/macros.h"
11
12 namespace views {
13 class View;
14 }
15
16 namespace ash {
17
18 class ASH_EXPORT TracingObserver {
19 public:
20 virtual ~TracingObserver() {}
21
22 // Notifies when tracing mode changes.
23 virtual void OnTracingModeChanged(bool value) = 0;
24 };
25
26 // This is the item that displays when users enable performance tracing at
27 // chrome://slow. It alerts them that this mode is running, and provides an
28 // easy way to open the page to disable it.
29 class TrayTracing : public TrayImageItem,
30 public TracingObserver {
31 public:
32 explicit TrayTracing(SystemTray* system_tray);
33 ~TrayTracing() override;
34
35 private:
36 void SetTrayIconVisible(bool visible);
37
38 // Overridden from TrayImageItem.
39 bool GetInitialVisibility() override;
40 views::View* CreateDefaultView(LoginStatus status) override;
41 views::View* CreateDetailedView(LoginStatus status) override;
42 void DestroyDefaultView() override;
43 void DestroyDetailedView() override;
44
45 // Overridden from TracingObserver.
46 void OnTracingModeChanged(bool value) override;
47
48 views::View* default_;
49
50 DISALLOW_COPY_AND_ASSIGN(TrayTracing);
51 };
52
53 } // namespace ash
54
55 #endif // ASH_SYSTEM_TRAY_TRACING_H_
OLDNEW
« no previous file with comments | « ash/common/system/tray/wm_system_tray_notifier.cc ('k') | ash/system/chromeos/tray_tracing.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698