OpenTTD Source  1.11.2
win32.h
Go to the documentation of this file.
1 /*
2  * This file is part of OpenTTD.
3  * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
4  * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
5  * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
6  */
7 
10 #ifndef WIN32_H
11 #define WIN32_H
12 
13 #include <windows.h>
14 bool MyShowCursor(bool show, bool toggle = false);
15 
16 typedef void (*Function)(int);
17 bool LoadLibraryList(Function proc[], const char *dll);
18 
19 char *convert_from_fs(const wchar_t *name, char *utf8_buf, size_t buflen);
20 wchar_t *convert_to_fs(const char *name, wchar_t *utf16_buf, size_t buflen, bool console_cp = false);
21 
22 #if defined(__MINGW32__) && !defined(__MINGW64__)
23 #define SHGFP_TYPE_CURRENT 0
24 #endif /* __MINGW32__ */
25 
26 void Win32SetCurrentLocaleName(const char *iso_code);
27 int OTTDStringCompare(const char *s1, const char *s2);
29 
30 #endif /* WIN32_H */
LoadLibraryList
bool LoadLibraryList(Function proc[], const char *dll)
Helper function needed by dynamically loading libraries.
Definition: win32.cpp:56
convert_to_fs
wchar_t * convert_to_fs(const char *name, wchar_t *utf16_buf, size_t buflen, bool console_cp=false)
Convert from OpenTTD's encoding to that of the environment in UNICODE.
Definition: win32.cpp:617
IsWindowsVistaOrGreater
bool IsWindowsVistaOrGreater()
Is the current Windows version Vista or later?
Definition: win32.cpp:710
convert_from_fs
char * convert_from_fs(const wchar_t *name, char *utf8_buf, size_t buflen)
Convert to OpenTTD's encoding from that of the environment in UNICODE.
Definition: win32.cpp:595