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

Unified Diff: content/browser/device_orientation/device_orientation_browsertest.cc

Issue 10689106: Renaming Observer to OrientationObserver in DeviceOrientation (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/device_orientation_browsertest.cc
diff --git a/content/browser/device_orientation/device_orientation_browsertest.cc b/content/browser/device_orientation/device_orientation_browsertest.cc
index 9459ef93f26e5ea325d5e039caee27a2207e6c7e..c23d1fff2ae59dff42efa7f7ec2ec9b667700ef1 100644
--- a/content/browser/device_orientation/device_orientation_browsertest.cc
+++ b/content/browser/device_orientation/device_orientation_browsertest.cc
@@ -20,20 +20,20 @@ class MockProvider : public Provider {
public:
explicit MockProvider(const Orientation& orientation)
: orientation_(orientation),
- added_observer_(false),
- removed_observer_(false) {}
+ added_orientation_observer_(false),
+ removed_orientation_observer_(false) {}
- virtual void AddObserver(Observer* observer) {
- added_observer_ = true;
+ virtual void AddOrientationObserver(OrientationObserver* observer) {
+ added_orientation_observer_ = true;
observer->OnOrientationUpdate(orientation_);
}
- virtual void RemoveObserver(Observer* observer) {
- removed_observer_ = true;
+ virtual void RemoveOrientationObserver(OrientationObserver* observer) {
+ removed_orientation_observer_ = true;
}
Orientation orientation_;
- bool added_observer_;
- bool removed_observer_;
+ bool added_orientation_observer_;
+ bool removed_orientation_observer_;
private:
virtual ~MockProvider() {}
@@ -69,8 +69,8 @@ IN_PROC_BROWSER_TEST_F(DeviceOrientationBrowserTest, BasicTest) {
// Check that the page got the event it expected and that the provider
// saw requests for adding and removing an observer.
EXPECT_EQ("pass", chrome::GetActiveWebContents(browser())->GetURL().ref());
- EXPECT_TRUE(provider->added_observer_);
- EXPECT_TRUE(provider->removed_observer_);
+ EXPECT_TRUE(provider->added_orientation_observer_);
+ EXPECT_TRUE(provider->removed_orientation_observer_);
}
} // namespace device_orientation

Powered by Google App Engine
This is Rietveld 408576698