tdf#154546 skip dispatch when presenter controller is not set
[LibreOffice.git] / sal / osl / w32 / filetime.hxx
blobdc355591adcebe708837d275e13c2a48fbfff7e8
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 */
10 #ifndef INCLUDED_SAL_OSL_W32_FILETIME_HXX
11 #define INCLUDED_SAL_OSL_W32_FILETIME_HXX
13 #include <sal/config.h>
15 #define WIN32_LEAN_AND_MEAN
16 #include <windows.h>
18 #include <osl/time.h>
20 BOOL TimeValueToFileTime(TimeValue const* cpTimeVal, FILETIME* pFTime);
22 BOOL FileTimeToTimeValue(FILETIME const* cpFTime, TimeValue* pTimeVal);
24 namespace osl::detail
26 inline __int64 getFiletime(FILETIME const& ft)
28 return (DWORD64(ft.dwHighDateTime) << 32) | ft.dwLowDateTime;
31 inline void setFiletime(FILETIME& ft, __int64 value)
33 ft.dwHighDateTime = value >> 32;
34 ft.dwLowDateTime = value & 0xFFFFFFFF;
38 #endif
40 /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */