| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 void FileTimeToUnixTime(const FILETIME& ft, time_t* ut); | 79 void FileTimeToUnixTime(const FILETIME& ft, time_t* ut); |
| 80 | 80 |
| 81 // Convert time_t to FILETIME | 81 // Convert time_t to FILETIME |
| 82 void UnixTimeToFileTime(const time_t& ut, FILETIME * ft); | 82 void UnixTimeToFileTime(const time_t& ut, FILETIME * ft); |
| 83 | 83 |
| 84 // Convert a Utf8 path representation to a non-length-limited Unicode pathname. | 84 // Convert a Utf8 path representation to a non-length-limited Unicode pathname. |
| 85 bool Utf8ToWindowsFilename(const std::string& utf8, std::wstring* filename); | 85 bool Utf8ToWindowsFilename(const std::string& utf8, std::wstring* filename); |
| 86 | 86 |
| 87 // Convert a FILETIME to a UInt64 | 87 // Convert a FILETIME to a UInt64 |
| 88 inline uint64 ToUInt64(const FILETIME& ft) { | 88 inline uint64 ToUInt64(const FILETIME& ft) { |
| 89 ULARGE_INTEGER r = {ft.dwLowDateTime, ft.dwHighDateTime}; | 89 ULARGE_INTEGER r = {{ft.dwLowDateTime, ft.dwHighDateTime}}; |
| 90 return r.QuadPart; | 90 return r.QuadPart; |
| 91 } | 91 } |
| 92 | 92 |
| 93 enum WindowsMajorVersions { | 93 enum WindowsMajorVersions { |
| 94 kWindows2000 = 5, | 94 kWindows2000 = 5, |
| 95 kWindowsVista = 6, | 95 kWindowsVista = 6, |
| 96 }; | 96 }; |
| 97 bool GetOsVersion(int* major, int* minor, int* build); | 97 bool GetOsVersion(int* major, int* minor, int* build); |
| 98 | 98 |
| 99 inline bool IsWindowsVistaOrLater() { | 99 inline bool IsWindowsVistaOrLater() { |
| (...skipping 23 matching lines...) Expand all Loading... |
| 123 return (GetCurrentProcessIntegrityLevel(&level) && | 123 return (GetCurrentProcessIntegrityLevel(&level) && |
| 124 level < SECURITY_MANDATORY_MEDIUM_RID); | 124 level < SECURITY_MANDATORY_MEDIUM_RID); |
| 125 } | 125 } |
| 126 | 126 |
| 127 bool AdjustCurrentProcessPrivilege(const TCHAR* privilege, bool to_enable); | 127 bool AdjustCurrentProcessPrivilege(const TCHAR* privilege, bool to_enable); |
| 128 | 128 |
| 129 } // namespace rtc | 129 } // namespace rtc |
| 130 | 130 |
| 131 #endif // WEBRTC_WIN | 131 #endif // WEBRTC_WIN |
| 132 #endif // WEBRTC_BASE_WIN32_H_ | 132 #endif // WEBRTC_BASE_WIN32_H_ |
| OLD | NEW |