roll skia 1111->1115
[chromium-blink-merge.git] / views / events / event_utils_win.h
blob9133864ef4ba09c514fbd926197bbb917d75928b
1 // Copyright (c) 2011 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.
5 #ifndef VIEWS_EVENTS_EVENT_UTILS_WIN_H_
6 #define VIEWS_EVENTS_EVENT_UTILS_WIN_H_
7 #pragma once
9 #include "ui/gfx/native_widget_types.h"
11 // Windows-specific Event utilities. Add functionality here rather than adding
12 // #ifdefs to event.h
14 namespace views {
16 class Event;
17 class KeyEvent;
19 // Returns the repeat count of the specified KeyEvent. Valid only for
20 // KeyEvents constructed from a MSG.
21 int GetRepeatCount(const KeyEvent& event);
23 // Returns true if the affected key is a Windows extended key. See documentation
24 // for WM_KEYDOWN for explanation.
25 // Valid only for KeyEvents constructed from a MSG.
26 bool IsExtendedKey(const KeyEvent& event);
28 // Return a mask of windows key/button state flags for the event object.
29 int GetWindowsFlags(const Event& event);
31 } // namespace views
33 #endif // VIEWS_EVENTS_EVENT_UTILS_WIN_H_