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

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

Issue 10815082: ash: Make sure the focus-border in the tray paints correctly, and tray-view should not be focusable (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 5 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.cc ('k') | ash/system/tray/tray_views.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_TRAY_VIEWS_H_ 5 #ifndef ASH_SYSTEM_TRAY_TRAY_VIEWS_H_
6 #define ASH_SYSTEM_TRAY_TRAY_VIEWS_H_ 6 #define ASH_SYSTEM_TRAY_TRAY_VIEWS_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "ash/wm/shelf_types.h" 9 #include "ash/wm/shelf_types.h"
10 #include "ui/gfx/font.h" 10 #include "ui/gfx/font.h"
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 public: 59 public:
60 ActionableView(); 60 ActionableView();
61 61
62 virtual ~ActionableView(); 62 virtual ~ActionableView();
63 63
64 // Set the accessible name. 64 // Set the accessible name.
65 void SetAccessibleName(const string16& name); 65 void SetAccessibleName(const string16& name);
66 const string16& accessible_name() const { return accessible_name_; } 66 const string16& accessible_name() const { return accessible_name_; }
67 67
68 protected: 68 protected:
69 void DrawBorder(gfx::Canvas* canvas, const gfx::Rect& bounds);
70
69 // Performs an action when user clicks on the view (on mouse-press event), or 71 // Performs an action when user clicks on the view (on mouse-press event), or
70 // presses a key when this view is in focus. Returns true if the event has 72 // presses a key when this view is in focus. Returns true if the event has
71 // been handled and an action was performed. Returns false otherwise. 73 // been handled and an action was performed. Returns false otherwise.
72 virtual bool PerformAction(const views::Event& event) = 0; 74 virtual bool PerformAction(const views::Event& event) = 0;
73 75
74 // Overridden from views::View. 76 // Overridden from views::View.
75 virtual bool OnKeyPressed(const views::KeyEvent& event) OVERRIDE; 77 virtual bool OnKeyPressed(const views::KeyEvent& event) OVERRIDE;
76 virtual bool OnMousePressed(const views::MouseEvent& event) OVERRIDE; 78 virtual bool OnMousePressed(const views::MouseEvent& event) OVERRIDE;
77 virtual void OnMouseReleased(const views::MouseEvent& event) OVERRIDE; 79 virtual void OnMouseReleased(const views::MouseEvent& event) OVERRIDE;
78 virtual void OnMouseCaptureLost() OVERRIDE; 80 virtual void OnMouseCaptureLost() OVERRIDE;
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 void SetTrayImageItemBorder(views::View* tray_view, ShelfAlignment alignment); 294 void SetTrayImageItemBorder(views::View* tray_view, ShelfAlignment alignment);
293 // Sets the empty border around a label tray item for adjusting the space 295 // Sets the empty border around a label tray item for adjusting the space
294 // around it. 296 // around it.
295 void SetTrayLabelItemBorder(TrayItemView* tray_view, 297 void SetTrayLabelItemBorder(TrayItemView* tray_view,
296 ShelfAlignment alignment); 298 ShelfAlignment alignment);
297 299
298 } // namespace internal 300 } // namespace internal
299 } // namespace ash 301 } // namespace ash
300 302
301 #endif // ASH_SYSTEM_TRAY_TRAY_VIEWS_H_ 303 #endif // ASH_SYSTEM_TRAY_TRAY_VIEWS_H_
OLDNEW
« no previous file with comments | « ash/system/tray/system_tray.cc ('k') | ash/system/tray/tray_views.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698