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

Side by Side Diff: chrome/browser/location_bar.h

Issue 347016: Implement page action popups. (Closed)
Patch Set: fixed failing test Created 11 years, 1 month 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 | « chrome/browser/gtk/location_bar_view_gtk.cc ('k') | chrome/browser/views/browser_bubble_win.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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 // The LocationBar class is a virtual interface, defining access to the 5 // The LocationBar class is a virtual interface, defining access to the
6 // window's location bar component. This class exists so that cross-platform 6 // window's location bar component. This class exists so that cross-platform
7 // components like the browser command system can talk to the platform 7 // components like the browser command system can talk to the platform
8 // specific implementations of the location bar control. It also allows the 8 // specific implementations of the location bar control. It also allows the
9 // location bar to be mocked for testing. 9 // location bar to be mocked for testing.
10 10
11 #ifndef CHROME_BROWSER_LOCATION_BAR_H_ 11 #ifndef CHROME_BROWSER_LOCATION_BAR_H_
12 #define CHROME_BROWSER_LOCATION_BAR_H_ 12 #define CHROME_BROWSER_LOCATION_BAR_H_
13 13
14 #include <string> 14 #include <string>
15 15
16 #include "chrome/common/page_transition_types.h" 16 #include "chrome/common/page_transition_types.h"
17 #include "webkit/glue/window_open_disposition.h" 17 #include "webkit/glue/window_open_disposition.h"
18 18
19 class AutocompleteEditView; 19 class AutocompleteEditView;
20 class ExtensionAction;
20 class LocationBarTesting; 21 class LocationBarTesting;
21 class TabContents; 22 class TabContents;
22 23
23 class LocationBar { 24 class LocationBar {
24 public: 25 public:
25 // Shows the first run information bubble anchored to the location bar. 26 // Shows the first run information bubble anchored to the location bar.
26 virtual void ShowFirstRunBubble(bool use_OEM_bubble) = 0; 27 virtual void ShowFirstRunBubble(bool use_OEM_bubble) = 0;
27 28
28 // Returns the string of text entered in the location bar. 29 // Returns the string of text entered in the location bar.
29 virtual std::wstring GetInputString() const = 0; 30 virtual std::wstring GetInputString() const = 0;
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 virtual LocationBarTesting* GetLocationBarForTesting() = 0; 71 virtual LocationBarTesting* GetLocationBarForTesting() = 0;
71 }; 72 };
72 73
73 class LocationBarTesting { 74 class LocationBarTesting {
74 public: 75 public:
75 // Returns the total number of page actions in the Omnibox. 76 // Returns the total number of page actions in the Omnibox.
76 virtual int PageActionCount() = 0; 77 virtual int PageActionCount() = 0;
77 78
78 // Returns the number of visible page actions in the Omnibox. 79 // Returns the number of visible page actions in the Omnibox.
79 virtual int PageActionVisibleCount() = 0; 80 virtual int PageActionVisibleCount() = 0;
81
82 // Returns the ExtensionAction at |index|.
83 virtual ExtensionAction* GetPageAction(size_t index) = 0;
84
85 // Returns the visible ExtensionAction at |index|.
86 virtual ExtensionAction* GetVisiblePageAction(size_t index) = 0;
87
88 // Simulates a left mouse pressed on the visible page action at |index|.
89 virtual void TestPageActionPressed(size_t index) = 0;
80 }; 90 };
81 91
82 #endif // CHROME_BROWSER_LOCATION_BAR_H_ 92 #endif // CHROME_BROWSER_LOCATION_BAR_H_
OLDNEW
« no previous file with comments | « chrome/browser/gtk/location_bar_view_gtk.cc ('k') | chrome/browser/views/browser_bubble_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698