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

Side by Side Diff: chrome/browser/extensions/extension_toolbar_model.h

Issue 549224: Support reordering of Browser Actions within the container. Currently does no... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 10 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
OLDNEW
1 // Copyright (c) 2009 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 CHROME_BROWSER_EXTENSIONS_EXTENSION_TOOLBAR_MODEL_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_TOOLBAR_MODEL_H_
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_TOOLBAR_MODEL_H_ 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_TOOLBAR_MODEL_H_
7 7
8 #include "base/observer_list.h" 8 #include "base/observer_list.h"
9 #include "chrome/common/extensions/extension.h" 9 #include "chrome/common/extensions/extension.h"
10 #include "chrome/common/notification_observer.h" 10 #include "chrome/common/notification_observer.h"
11 #include "chrome/common/notification_registrar.h" 11 #include "chrome/common/notification_registrar.h"
(...skipping 19 matching lines...) Expand all
31 31
32 // The browser action button for |extension| has been moved to |index|. 32 // The browser action button for |extension| has been moved to |index|.
33 virtual void BrowserActionMoved(Extension* extension, int index) {} 33 virtual void BrowserActionMoved(Extension* extension, int index) {}
34 }; 34 };
35 35
36 // Functions called by the view. 36 // Functions called by the view.
37 void AddObserver(Observer* observer); 37 void AddObserver(Observer* observer);
38 void RemoveObserver(Observer* observer); 38 void RemoveObserver(Observer* observer);
39 void MoveBrowserAction(Extension* extension, int index); 39 void MoveBrowserAction(Extension* extension, int index);
40 40
41 size_t size() const {
42 return toolitems_.size();
43 }
44
41 ExtensionList::iterator begin() { 45 ExtensionList::iterator begin() {
42 return toolitems_.begin(); 46 return toolitems_.begin();
43 } 47 }
44 48
45 ExtensionList::iterator end() { 49 ExtensionList::iterator end() {
46 return toolitems_.end(); 50 return toolitems_.end();
47 } 51 }
48 52
49 private: 53 private:
50 // NotificationObserver implementation. 54 // NotificationObserver implementation.
(...skipping 18 matching lines...) Expand all
69 // Our ExtensionsService, guaranteed to outlive us. 73 // Our ExtensionsService, guaranteed to outlive us.
70 ExtensionsService* service_; 74 ExtensionsService* service_;
71 75
72 // Ordered list of browser action buttons. 76 // Ordered list of browser action buttons.
73 ExtensionList toolitems_; 77 ExtensionList toolitems_;
74 78
75 NotificationRegistrar registrar_; 79 NotificationRegistrar registrar_;
76 }; 80 };
77 81
78 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_TOOLBAR_MODEL_H_ 82 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_TOOLBAR_MODEL_H_
OLDNEW
« no previous file with comments | « chrome/browser/bookmarks/bookmark_drag_data.cc ('k') | chrome/browser/views/browser_actions_container.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698