renderer_gamepad_provider.h revision 6d86b77056ed63eb6871182f42a9fd5f07550f90
1// Copyright 2014 The Chromium Authors. All rights reserved. 2// Use of this source code is governed by a BSD-style license that can be 3// found in the LICENSE file. 4 5#ifndef CONTENT_GAMEPAD_RENDERER_PROVIDER_H_ 6#define CONTENT_GAMEPAD_RENDERER_PROVIDER_H_ 7 8namespace blink { 9class WebGamepadListener; 10class WebGamepads; 11} 12 13namespace content { 14 15// Provides gamepad data and events for blink. 16class RendererGamepadProvider { 17 public: 18 // Provides latest snapshot of gamepads. 19 virtual void SampleGamepads(blink::WebGamepads& gamepads) = 0; 20 21 // Registers listener for be notified of events. 22 virtual void SetGamepadListener(blink::WebGamepadListener* listener) = 0; 23 24 protected: 25 virtual ~RendererGamepadProvider() {} 26}; 27 28} // namespace content 29 30#endif 31