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

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

Issue 2084733002: mash: Move tray accessibility and keyboard to //ash/common (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@typenamespace
Patch Set: rebase 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/system/tray/system_tray.cc ('k') | ash/system/tray/tray_details_view.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 (c) 2012 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_TRAY_DETAILS_VIEW_H_
6 #define ASH_SYSTEM_TRAY_TRAY_DETAILS_VIEW_H_
7
8 #include "ash/ash_export.h"
9 #include "ash/common/system/tray/special_popup_row.h"
10 #include "base/macros.h"
11 #include "ui/views/view.h"
12
13 namespace views {
14 class ScrollView;
15 }
16
17 namespace ash {
18 class FixedSizedScrollView;
19 class ScrollBorder;
20 class SystemTrayItem;
21 class ViewClickListener;
22
23 class ASH_EXPORT TrayDetailsView : public views::View {
24 public:
25 explicit TrayDetailsView(SystemTrayItem* owner);
26 ~TrayDetailsView() override;
27
28 // Creates a row with special highlighting etc. This is typically the
29 // bottom-most row in the popup.
30 void CreateSpecialRow(int string_id, ViewClickListener* listener);
31
32 // Creates a scrollable list. The list has a border at the bottom if there is
33 // any other view between the list and the footer row at the bottom.
34 void CreateScrollableList();
35
36 // Adds a separator in scrollable list.
37 void AddScrollSeparator();
38
39 // Removes (and destroys) all child views.
40 void Reset();
41
42 // Transition to default view from details view. If |footer_| has focus before
43 // transition, the default view should focus on the owner of this details
44 // view.
45 void TransitionToDefaultView();
46
47 SystemTrayItem* owner() const { return owner_; }
48 SpecialPopupRow* footer() const { return footer_; }
49 FixedSizedScrollView* scroller() const { return scroller_; }
50 views::View* scroll_content() const { return scroll_content_; }
51
52 protected:
53 // Overridden from views::View.
54 void Layout() override;
55 void OnPaintBorder(gfx::Canvas* canvas) override;
56
57 private:
58 SystemTrayItem* owner_;
59 SpecialPopupRow* footer_;
60 FixedSizedScrollView* scroller_;
61 views::View* scroll_content_;
62 ScrollBorder* scroll_border_; // Weak reference
63
64 DISALLOW_COPY_AND_ASSIGN(TrayDetailsView);
65 };
66
67 } // namespace ash
68
69 #endif // ASH_SYSTEM_TRAY_TRAY_DETAILS_VIEW_H_
OLDNEW
« no previous file with comments | « ash/system/tray/system_tray.cc ('k') | ash/system/tray/tray_details_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698