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

Side by Side Diff: views/controls/button/menu_button.h

Issue 113443: ChromeCanvas->gfx::Canvas (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 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 | « views/controls/button/image_button.cc ('k') | views/controls/button/menu_button.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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ 5 #ifndef VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_
6 #define VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ 6 #define VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_
7 7
8 #include <windows.h> 8 #include <windows.h>
9 9
10 #include "app/gfx/chrome_font.h" 10 #include "app/gfx/font.h"
11 #include "base/time.h" 11 #include "base/time.h"
12 #include "views/background.h" 12 #include "views/background.h"
13 #include "views/controls/button/text_button.h" 13 #include "views/controls/button/text_button.h"
14 14
15 namespace views { 15 namespace views {
16 16
17 class MouseEvent; 17 class MouseEvent;
18 class ViewMenuDelegate; 18 class ViewMenuDelegate;
19 19
20 20
(...skipping 16 matching lines...) Expand all
37 37
38 void set_menu_delegate(ViewMenuDelegate* delegate) { 38 void set_menu_delegate(ViewMenuDelegate* delegate) {
39 menu_delegate_ = delegate; 39 menu_delegate_ = delegate;
40 } 40 }
41 41
42 // Activate the button (called when the button is pressed). 42 // Activate the button (called when the button is pressed).
43 virtual bool Activate(); 43 virtual bool Activate();
44 44
45 // Overridden to take into account the potential use of a drop marker. 45 // Overridden to take into account the potential use of a drop marker.
46 virtual gfx::Size GetPreferredSize(); 46 virtual gfx::Size GetPreferredSize();
47 virtual void Paint(ChromeCanvas* canvas, bool for_drag); 47 virtual void Paint(gfx::Canvas* canvas, bool for_drag);
48 48
49 // These methods are overriden to implement a simple push button 49 // These methods are overriden to implement a simple push button
50 // behavior 50 // behavior
51 virtual bool OnMousePressed(const MouseEvent& e); 51 virtual bool OnMousePressed(const MouseEvent& e);
52 void OnMouseReleased(const MouseEvent& e, bool canceled); 52 void OnMouseReleased(const MouseEvent& e, bool canceled);
53 virtual bool OnKeyReleased(const KeyEvent& e); 53 virtual bool OnKeyReleased(const KeyEvent& e);
54 virtual void OnMouseExited(const MouseEvent& event); 54 virtual void OnMouseExited(const MouseEvent& event);
55 55
56 // Accessibility accessors, overridden from View. 56 // Accessibility accessors, overridden from View.
57 virtual bool GetAccessibleDefaultAction(std::wstring* action); 57 virtual bool GetAccessibleDefaultAction(std::wstring* action);
(...skipping 25 matching lines...) Expand all
83 83
84 // Whether or not we're showing a drop marker. 84 // Whether or not we're showing a drop marker.
85 bool show_menu_marker_; 85 bool show_menu_marker_;
86 86
87 friend class TextButtonBackground; 87 friend class TextButtonBackground;
88 }; 88 };
89 89
90 } // namespace views 90 } // namespace views
91 91
92 #endif // VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ 92 #endif // VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_
OLDNEW
« no previous file with comments | « views/controls/button/image_button.cc ('k') | views/controls/button/menu_button.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698