Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(20)

Side by Side Diff: base/win/win_util.h

Issue 10802085: Correct behaviour of touch wrt mouse capture. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Clean-up Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | base/win/win_util.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // ============================================================================= 5 // =============================================================================
6 // PLEASE READ 6 // PLEASE READ
7 // 7 //
8 // In general, you should not be adding stuff to this file. 8 // In general, you should not be adding stuff to this file.
sky 2012/07/25 00:50:11 See this comment. Put the function in ui/base/win/
girard 2012/07/25 22:08:30 Thanks. Done.
9 // 9 //
10 // - If your thing is only used in one place, just put it in a reasonable 10 // - If your thing is only used in one place, just put it in a reasonable
11 // location in or near that one place. It's nice you want people to be able 11 // location in or near that one place. It's nice you want people to be able
12 // to re-use your function, but realistically, if it hasn't been necessary 12 // to re-use your function, but realistically, if it hasn't been necessary
13 // before after so many years of development, it's probably not going to be 13 // before after so many years of development, it's probably not going to be
14 // used in other places in the future unless you know of them now. 14 // used in other places in the future unless you know of them now.
15 // 15 //
16 // - If your thing is used by multiple callers and is UI-related, it should 16 // - If your thing is used by multiple callers and is UI-related, it should
17 // probably be in app/win/ instead. Try to put it in the most specific file 17 // probably be in app/win/ instead. Try to put it in the most specific file
18 // possible (avoiding the *_util files when practical). 18 // possible (avoiding the *_util files when practical).
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 51
52 // Returns true if the shift key is currently pressed. 52 // Returns true if the shift key is currently pressed.
53 BASE_EXPORT bool IsShiftPressed(); 53 BASE_EXPORT bool IsShiftPressed();
54 54
55 // Returns true if the ctrl key is currently pressed. 55 // Returns true if the ctrl key is currently pressed.
56 BASE_EXPORT bool IsCtrlPressed(); 56 BASE_EXPORT bool IsCtrlPressed();
57 57
58 // Returns true if the alt key is currently pressed. 58 // Returns true if the alt key is currently pressed.
59 BASE_EXPORT bool IsAltPressed(); 59 BASE_EXPORT bool IsAltPressed();
60 60
61 // Returns true if |message| identifies a mouse event that was generated as the
62 // result of a touch event.
63 BASE_EXPORT bool IsMouseEventFromTouch(UINT message);
64
61 // Returns false if user account control (UAC) has been disabled with the 65 // Returns false if user account control (UAC) has been disabled with the
62 // EnableLUA registry flag. Returns true if user account control is enabled. 66 // EnableLUA registry flag. Returns true if user account control is enabled.
63 // NOTE: The EnableLUA registry flag, which is ignored on Windows XP 67 // NOTE: The EnableLUA registry flag, which is ignored on Windows XP
64 // machines, might still exist and be set to 0 (UAC disabled), in which case 68 // machines, might still exist and be set to 0 (UAC disabled), in which case
65 // this function will return false. You should therefore check this flag only 69 // this function will return false. You should therefore check this flag only
66 // if the OS is Vista or later. 70 // if the OS is Vista or later.
67 BASE_EXPORT bool UserAccountControlIsEnabled(); 71 BASE_EXPORT bool UserAccountControlIsEnabled();
68 72
69 // Sets the string value for given key in given IPropertyStore. 73 // Sets the string value for given key in given IPropertyStore.
70 BASE_EXPORT bool SetStringValueForPropertyStore( 74 BASE_EXPORT bool SetStringValueForPropertyStore(
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 // This is necessary to set compatible struct sizes for different versions 112 // This is necessary to set compatible struct sizes for different versions
109 // of certain Windows APIs (e.g. SystemParametersInfo). 113 // of certain Windows APIs (e.g. SystemParametersInfo).
110 #define SIZEOF_STRUCT_WITH_SPECIFIED_LAST_MEMBER(struct_name, member) \ 114 #define SIZEOF_STRUCT_WITH_SPECIFIED_LAST_MEMBER(struct_name, member) \
111 offsetof(struct_name, member) + \ 115 offsetof(struct_name, member) + \
112 (sizeof static_cast<struct_name*>(NULL)->member) 116 (sizeof static_cast<struct_name*>(NULL)->member)
113 117
114 } // namespace win 118 } // namespace win
115 } // namespace base 119 } // namespace base
116 120
117 #endif // BASE_WIN_WIN_UTIL_H_ 121 #endif // BASE_WIN_WIN_UTIL_H_
OLDNEW
« no previous file with comments | « no previous file | base/win/win_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698