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

Unified Diff: content/browser/screen_orientation/screen_orientation_message_filter_android.cc

Issue 546453004: Centralize ScreenOrientationProvider logic, add platform delegates (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@screen_orientation_public_impl_split
Patch Set: Remove Factory Created 6 years, 2 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/screen_orientation/screen_orientation_message_filter_android.cc
diff --git a/content/browser/screen_orientation/screen_orientation_message_filter_android.cc b/content/browser/screen_orientation/screen_orientation_message_filter_android.cc
index 3a7831b2df03891b929ea0f22d997a658260f3cd..cd7bd186a22fadbcaba9f140079363aba1250d1d 100644
--- a/content/browser/screen_orientation/screen_orientation_message_filter_android.cc
+++ b/content/browser/screen_orientation/screen_orientation_message_filter_android.cc
@@ -4,7 +4,7 @@
#include "content/browser/screen_orientation/screen_orientation_message_filter_android.h"
-#include "content/browser/screen_orientation/screen_orientation_provider_android.h"
+#include "content/browser/screen_orientation/screen_orientation_delegate_android.h"
#include "content/common/screen_orientation_messages.h"
namespace content {
@@ -17,7 +17,7 @@ ScreenOrientationMessageFilterAndroid::ScreenOrientationMessageFilterAndroid()
ScreenOrientationMessageFilterAndroid::~ScreenOrientationMessageFilterAndroid()
{
if (listeners_count_ > 0)
- ScreenOrientationProviderAndroid::StopAccurateListening();
+ ScreenOrientationDelegateAndroid::StopAccurateListening();
}
bool ScreenOrientationMessageFilterAndroid::OnMessageReceived(
@@ -36,14 +36,14 @@ bool ScreenOrientationMessageFilterAndroid::OnMessageReceived(
void ScreenOrientationMessageFilterAndroid::OnStartListening() {
++listeners_count_;
if (listeners_count_ == 1)
- ScreenOrientationProviderAndroid::StartAccurateListening();
+ ScreenOrientationDelegateAndroid::StartAccurateListening();
}
void ScreenOrientationMessageFilterAndroid::OnStopListening() {
DCHECK(listeners_count_ > 0);
--listeners_count_;
if (listeners_count_ == 0)
- ScreenOrientationProviderAndroid::StopAccurateListening();
+ ScreenOrientationDelegateAndroid::StopAccurateListening();
}
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698