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

Unified Diff: content/browser/device_orientation/provider_impl.h

Issue 10837055: Changes ProviderImpl to use a single DataFetcherFactory (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
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 side-by-side diff with in-line comments
Download patch
Index: content/browser/device_orientation/provider_impl.h
diff --git a/content/browser/device_orientation/provider_impl.h b/content/browser/device_orientation/provider_impl.h
index 32c63691a6a531cc9ed313de23ac86aa1ce86115..6855225cfcb1ea645243a2fd36ef69596f814a41 100644
--- a/content/browser/device_orientation/provider_impl.h
+++ b/content/browser/device_orientation/provider_impl.h
@@ -24,9 +24,10 @@ class ProviderImpl : public Provider {
public:
typedef DataFetcher* (*DataFetcherFactory)();
- // Create a ProviderImpl that uses the NULL-terminated factories array to find
- // a DataFetcher that can provide orientation data.
- CONTENT_EXPORT ProviderImpl(const DataFetcherFactory factories[]);
+ // Create a ProviderImpl that uses the pointer to a factory to create a
hans 2012/08/01 19:08:47 i don't think it should take a pointer to a factor
aousterh 2012/08/02 10:10:38 Good point, that does simply things further. Done.
+ // DataFetcher that can provide orientation data. A NULL pointer indicates
+ // that there are no DataFetchers for this OS.
+ CONTENT_EXPORT ProviderImpl(const DataFetcherFactory* factory);
// From Provider.
virtual void AddObserver(Observer* observer) OVERRIDE;
@@ -52,7 +53,7 @@ class ProviderImpl : public Provider {
MessageLoop* creator_loop_;
// Members below are only to be used from the creator_loop_.
- std::vector<DataFetcherFactory> factories_;
+ const DataFetcherFactory* factory_;
std::set<Observer*> observers_;
Orientation last_notification_;

Powered by Google App Engine
This is Rietveld 408576698