Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 #include "base/win/win_util.h" | 5 #include "base/win/win_util.h" |
| 6 | 6 |
| 7 #include <aclapi.h> | 7 #include <aclapi.h> |
| 8 #include <cfgmgr32.h> | 8 #include <cfgmgr32.h> |
| 9 #include <lm.h> | 9 #include <lm.h> |
| 10 #include <powrprof.h> | 10 #include <powrprof.h> |
| 11 #include <tchar.h> | |
|
ananta
2016/04/04 21:17:59
Please fix the include order if possible for this
kylix_rd
2016/04/04 21:40:51
Done.
| |
| 12 #include <tpcshrd.h> | |
| 11 #include <shellapi.h> | 13 #include <shellapi.h> |
| 12 #include <shlobj.h> | 14 #include <shlobj.h> |
| 13 #include <shobjidl.h> // Must be before propkey. | 15 #include <shobjidl.h> // Must be before propkey. |
| 14 #include <initguid.h> | 16 #include <initguid.h> |
| 15 #include <inspectable.h> | 17 #include <inspectable.h> |
| 16 #include <propkey.h> | 18 #include <propkey.h> |
| 17 #include <propvarutil.h> | 19 #include <propvarutil.h> |
| 18 #include <psapi.h> | 20 #include <psapi.h> |
| 19 #include <roapi.h> | 21 #include <roapi.h> |
| 20 #include <sddl.h> | 22 #include <sddl.h> |
| (...skipping 666 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 687 // more room is given to avoid multiple expensive calls to | 689 // more room is given to avoid multiple expensive calls to |
| 688 // ::EnumProcessModules() just because one module has been added. | 690 // ::EnumProcessModules() just because one module has been added. |
| 689 snapshot->resize(num_modules + 8, NULL); | 691 snapshot->resize(num_modules + 8, NULL); |
| 690 } | 692 } |
| 691 } while (--retries_remaining); | 693 } while (--retries_remaining); |
| 692 | 694 |
| 693 DLOG(ERROR) << "Failed to enumerate modules."; | 695 DLOG(ERROR) << "Failed to enumerate modules."; |
| 694 return false; | 696 return false; |
| 695 } | 697 } |
| 696 | 698 |
| 699 // Disable/Enable flick gestures | |
| 700 void AllowFlicks(HWND hwnd, bool allow) { | |
| 701 if (allow) { | |
| 702 ::RemoveProp(hwnd, MICROSOFT_TABLETPENSERVICE_PROPERTY); | |
| 703 } else { | |
| 704 ::SetProp(hwnd, MICROSOFT_TABLETPENSERVICE_PROPERTY, | |
| 705 reinterpret_cast<HANDLE>(TABLET_DISABLE_FLICKS | | |
| 706 TABLET_DISABLE_FLICKFALLBACKKEYS)); | |
| 707 } | |
| 708 } | |
| 709 | |
| 697 } // namespace win | 710 } // namespace win |
| 698 } // namespace base | 711 } // namespace base |
| OLD | NEW |