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

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

Issue 2853024: Remove the bookmark menu. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 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 | « chrome/common/chrome_switches.cc ('k') | no next file » | 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 <string> 8 #include <string>
9 9
10 #include "base/time.h" 10 #include "base/time.h"
(...skipping 20 matching lines...) Expand all
31 static const char kViewClassName[]; 31 static const char kViewClassName[];
32 32
33 // 33 //
34 // Create a Button 34 // Create a Button
35 MenuButton(ButtonListener* listener, 35 MenuButton(ButtonListener* listener,
36 const std::wstring& text, 36 const std::wstring& text,
37 ViewMenuDelegate* menu_delegate, 37 ViewMenuDelegate* menu_delegate,
38 bool show_menu_marker); 38 bool show_menu_marker);
39 virtual ~MenuButton(); 39 virtual ~MenuButton();
40 40
41 void set_menu_delegate(ViewMenuDelegate* delegate) {
42 menu_delegate_ = delegate;
43 }
44
45 void set_menu_marker(const SkBitmap* menu_marker) { 41 void set_menu_marker(const SkBitmap* menu_marker) {
46 menu_marker_ = menu_marker; 42 menu_marker_ = menu_marker;
47 } 43 }
48 44
49 // Activate the button (called when the button is pressed). 45 // Activate the button (called when the button is pressed).
50 virtual bool Activate(); 46 virtual bool Activate();
51 47
52 // Overridden to take into account the potential use of a drop marker. 48 // Overridden to take into account the potential use of a drop marker.
53 virtual gfx::Size GetPreferredSize(); 49 virtual gfx::Size GetPreferredSize();
54 virtual void Paint(gfx::Canvas* canvas, bool for_drag); 50 virtual void Paint(gfx::Canvas* canvas, bool for_drag);
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 // If non-null the destuctor sets this to true. This is set while the menu is 97 // If non-null the destuctor sets this to true. This is set while the menu is
102 // showing and used to detect if the menu was deleted while running. 98 // showing and used to detect if the menu was deleted while running.
103 bool* destroyed_flag_; 99 bool* destroyed_flag_;
104 100
105 DISALLOW_COPY_AND_ASSIGN(MenuButton); 101 DISALLOW_COPY_AND_ASSIGN(MenuButton);
106 }; 102 };
107 103
108 } // namespace views 104 } // namespace views
109 105
110 #endif // VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_ 106 #endif // VIEWS_CONTROLS_BUTTON_MENU_BUTTON_H_
OLDNEW
« no previous file with comments | « chrome/common/chrome_switches.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698