#ifndef CONTENT_BROWSER_SCREEN_ORIENTATION_SCREEN_ORIENTATION_DISPATCHER_HOST_H_
#define CONTENT_BROWSER_SCREEN_ORIENTATION_SCREEN_ORIENTATION_DISPATCHER_HOST_H_
#include "content/public/browser/browser_message_filter.h"
#include "third_party/WebKit/public/platform/WebScreenOrientation.h"
namespace content {
class ScreenOrientationProvider;
class CONTENT_EXPORT ScreenOrientationDispatcherHost
: public BrowserMessageFilter {
public:
ScreenOrientationDispatcherHost();
virtual bool OnMessageReceived(const IPC::Message&, bool*) OVERRIDE;
void OnOrientationChange(blink::WebScreenOrientation orientation);
void SetProviderForTests(ScreenOrientationProvider* provider);
private:
virtual ~ScreenOrientationDispatcherHost();
void OnLockRequest(blink::WebScreenOrientations orientations);
void OnUnlockRequest();
static ScreenOrientationProvider* CreateProvider();
scoped_ptr<ScreenOrientationProvider> provider_;
DISALLOW_COPY_AND_ASSIGN(ScreenOrientationDispatcherHost);
};
}
#endif