| Index: content/browser/screen_orientation/screen_orientation_context.h | 
| diff --git a/content/browser/screen_orientation/screen_orientation_context.h b/content/browser/screen_orientation/screen_orientation_context.h | 
| new file mode 100644 | 
| index 0000000000000000000000000000000000000000..453a61f61304d26435f9e68242e898d966dfd4e3 | 
| --- /dev/null | 
| +++ b/content/browser/screen_orientation/screen_orientation_context.h | 
| @@ -0,0 +1,50 @@ | 
| +// Copyright 2014 The Chromium Authors. All rights reserved. | 
| +// Use of this source code is governed by a BSD-style license that can be | 
| +// found in the LICENSE file. | 
| + | 
| +#ifndef CONTENT_BROWSER_SCREEN_ORIENTATION_SCREEN_ORIENTATION_CONTEXT_H_ | 
| +#define CONTENT_BROWSER_SCREEN_ORIENTATION_SCREEN_ORIENTATION_CONTEXT_H_ | 
| + | 
| +#include "base/observer_list.h" | 
| +#include "content/common/content_export.h" | 
| + | 
| +namespace content { | 
| + | 
| +// Provides information about changes within a screen orientation context to a | 
| +// set of observers of that context. | 
| +class CONTENT_EXPORT ScreenOrientationContext { | 
| + public: | 
| +  class Observer { | 
| +   public: | 
| +    // Called when the screen orientation changes. | 
| +    virtual void OnScreenOrientationChange() = 0; | 
| + | 
| +    // Called when a new lock request is received within this screen | 
| +    // orientation context. | 
| +    virtual void OnNewLockRequest() = 0; | 
| + | 
| +   protected: | 
| +    virtual ~Observer() {} | 
| +  }; | 
| + | 
| +  ScreenOrientationContext(); | 
| +  virtual ~ScreenOrientationContext(); | 
| + | 
| +  void AddObserver(Observer* observer); | 
| +  void RemoveObserver(Observer* observer); | 
| + | 
| +  // Notifies observers that screen orientation changed. | 
| +  void OnScreenOrientationChange(); | 
| + | 
| +  // Notifies observers that a new lock request was received. | 
| +  void OnNewLockRequest(); | 
| + | 
| + private: | 
| +  ObserverList<Observer> observer_list_; | 
| + | 
| +  DISALLOW_COPY_AND_ASSIGN(ScreenOrientationContext); | 
| +}; | 
| + | 
| +}  // namespace content | 
| + | 
| +#endif  // CONTENT_BROWSER_SCREEN_ORIENTATION_SCREEN_ORIENTATION_CONTEXT_H_ | 
|  |