input_state_lookup.h 744 B

12345678910111213141516171819202122232425262728
  1. // Copyright 2013 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. #ifndef UI_AURA_INPUT_STATE_LOOKUP_H_
  5. #define UI_AURA_INPUT_STATE_LOOKUP_H_
  6. #include <memory>
  7. #include "ui/aura/aura_export.h"
  8. namespace aura {
  9. // InputStateLookup is used to obtain the state of input devices.
  10. class AURA_EXPORT InputStateLookup {
  11. public:
  12. virtual ~InputStateLookup() {}
  13. // Creates the platform specific InputStateLookup. May return NULL.
  14. static std::unique_ptr<InputStateLookup> Create();
  15. // Returns true if any mouse button is down.
  16. virtual bool IsMouseButtonDown() const = 0;
  17. };
  18. } // namespace aura
  19. #endif // UI_AURA_INPUT_STATE_LOOKUP_H_