1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-18 20:43:04 +01:00
Commit Graph

46 Commits

Author SHA1 Message Date
Michał Janiszewski
3d12dfec3e Part of #11437: Refactor Win32 RemoveFileAssociations to Platform2 (#12773)
Additionally fixes missing changes from previous refactor in #12036 that
borked WinNT 5.1 support
2020-08-25 23:20:24 +02:00
Matt Thomson
a8f8f06e2d Fix #12402: Refactor MEASUREMENT_FORMAT to use strong enum (#12642)
* Fix #12402: Refactor MEASUREMENT_FORMAT to use strong enum

* Remove redundant default branches

Co-authored-by: Matt Thomson <matt-thomson@users.noreply.github.com>
2020-08-13 21:51:28 +01:00
Michael Lu
7cd6e72edd Refactor TEMPERATURE_FORMAT to use strong enum (#12610)
* Refactor TEMPERATURE_FORMAT to use strong enum

* Rename TEMPERATURE_FORMAT to TemperatureFormat

* Rename TemperatureFormat to TempueratureUnit
2020-08-09 07:26:46 +01:00
Matt
30376085cf Include missing headers 2020-08-05 16:29:29 +02:00
Aaron van Geffen
7b5087f057 Update copyright year to 2020 2020-07-21 15:04:34 +02:00
frutiemax
26ae2dbf04 Part of #11437: Move PlatformFileExists to Platform2.h (#12077) 2020-07-02 12:03:31 -03:00
frutiemax
5ae592ec79 Part of #11437: Move GetDateLocal and GetTimeLocal in Platform2.h 2020-06-28 21:46:14 +02:00
frutiemax
d2542194fa Part of #11437: move window_setup_file_association(s) in Platform2.hpp 2020-06-23 22:58:40 +02:00
Michael Steenbeek
d7637cd70f Replace many C-style casts (#11720) 2020-05-11 14:32:56 +02:00
Michael Steenbeek
0ecc64f781 Fix #11407: Setting an RCT1 path needs better error messages (#11418) 2020-04-25 15:36:44 +02:00
Michał Janiszewski
92e5958ab6 Improve WinNT 5.1/MinGW support (#10869) 2020-03-05 19:35:23 +01:00
Michał Janiszewski
afc92ee15a ifdef-out WinNT 6.0+ APIs (#10198)
Occasionally I need to build a binary compatible with WinNT 5.1, e.g.
when testing out Wine or ReactOS. There are just a few minor changes
required to have a working build, but as they are not part of the
repository, I always end up doing them from scratch. I would like to
upstream them instead so I don't have to recreate them each time, even
if this is not the most common use case.
2019-11-08 23:16:15 +01:00
Ted John
a1d9e52046 Rename ToUtf16 to ToWideChar
This is more correct as wchar_t size can differ, for example Linux typically uses 32 bits for wchar_t where as Windows uses 16 bits.
2019-07-22 23:44:03 +01:00
Ted John
6f61c94dbd Remove old widechar <-> utf-8 conversion function 2019-07-22 23:44:03 +01:00
muemart
7703774437 Correctly determine size of wchar arrays (#9490) 2019-06-27 19:46:03 +02:00
Ted John
15cb3e1889 Remove unnecessary new line characters from log calls (#9237) 2019-05-12 13:48:56 +02:00
Ted John
7074d6f3ae Apply review suggestions 2019-05-11 13:57:18 +01:00
Tom Lankhorst
ed353faccf Implement replace_if condition lambda
Fix include typo and CS
2019-05-11 13:54:16 +01:00
Tom Lankhorst
744f2225ed Write platform tests 2019-05-11 13:54:16 +01:00
Tom Lankhorst
bbd69496b4 Sanitize screenshot path 2019-05-11 13:54:16 +01:00
Aaron van Geffen
2af13904c5 Update copyright notices for 2019. (#8903) 2019-03-17 07:16:15 +00:00
Hielke Morsink
354d973a48 Use std::size instead of Util::CountOf 2018-11-23 21:59:08 +01:00
Ted John
2da2aa5622 Fix platform_get_username for unicode on Windows 2018-09-18 12:37:42 +01:00
Michael Steenbeek
9f891bfdcc Allow opening SV7 files 2018-08-16 16:16:56 +02:00
Aaron van Geffen
7cc5bc87e9 Check result of FileTimeToLocalFileTime; add to changelog. 2018-08-15 00:15:06 +02:00
Hielke Morsink
4a442d0d6d Convert filetime to local time on Windows 2018-08-15 00:14:47 +02:00
Michael Steenbeek
0a1b53e1c2 Auto-detect RCT1 files location (#7882) 2018-08-13 15:50:45 +02:00
Hielke Morsink
0b03464186 Replace 0 and NULL with nullptr (#7827) 2018-07-25 22:49:20 +02:00
clang-format
d787872cbe Indent preprocessor directives 2018-07-23 16:00:23 +02:00
clang-format
b02dfdbc93 Binpack function arguments together
Previously when the arguments of a function wouldn't fit on a single line, clang-format would put each argument on its own line instead. By enabling the binpack parameter setting, it tried to fit as many on one line as possible instead.

Co-authored-by: Hielke Morsink <hielke.morsink@gmail.com>
2018-07-23 16:00:22 +02:00
clang-format
0b3edc70f2 clang-format platform 2018-07-23 16:00:07 +02:00
Hielke Morsink
ce59ed0ba2 Fix include order and defines for Windows builds 2018-07-23 15:57:59 +02:00
Michael Steenbeek
8530d56a66 Add Danish translation (#7771) 2018-07-19 21:15:54 +02:00
Michał Janiszewski
ab20dcde9f Use "secure version" of swcanf (#7774)
This makes mingw builds usable again
2018-07-16 07:38:57 +01:00
Michael Steenbeek
9e559d577a Fix Steam path for Linux and macOS
While OpenRCT2 already had code to look up the Steam path on macOS and Linux, it didn't look in the correct directory. This meant that it wouldn't detect the presence of RCT2, even if the user had downloaded it via the Steam Console.
2018-07-05 09:42:52 +02:00
Michael Steenbeek
1b08fb4e69 Replace our own integer types with standard ones 2018-06-20 17:30:40 +02:00
Hielke Morsink
0cf256ac9e Ready copyright notice for clang-format
Clang-format sees the text behind `#pragma region` as code and formats it. Instead of stating the copyright and date there, it's now in the comment block right below it. The text "Copyright" is left in the `#pragma region` line, as clang-format sees it as a single identifier.

I took the opportunity to normalize the dates, and add the copyright notice to the source files where it was missing them (except for third-party and the generated resources.h file).
2018-06-15 14:07:34 +02:00
Hielke Morsink
5327c9feb4 Remove unused windows_get_registry_install_info (#7442) 2018-04-23 20:20:03 +02:00
Hielke Morsink
30063984e6 Delete unused function arguments or mark them so (#7426)
This aims to make future refactoring easier. The arguments are removed where possible, but kept and marked with C++17's [[maybe_unused]] where they could not be removed (e.g. when they are used as a callback, rather than called directly).

I've skipped the rides/<category>/* and peep/* source files, because the rides source files are mostly generated and have a ton of unused variables, and the peep source files are being refactored.
I've also skipped most of window/* source files, because most of the functions are used as callbacks and will be bulk-renamed at some point.
2018-04-20 13:56:37 +02:00
Michał Janiszewski
229c793b33 Fix NO_TTF builds for Windows and macOS 2018-03-09 16:40:40 +01:00
Gymnasiast
778ba466c5 Remove almost every extern C block 2018-02-05 16:20:15 +01:00
Ted John
87cd9f88b3 Rewrite Platform::GetInstallPath 2018-02-02 12:41:26 +00:00
Gymnasiast
5cc21fd21b Replace NULL with nullptr in C++ files 2018-01-29 21:33:21 +00:00
Ted John
cb44dc5c21 Fix changelog 2018-01-21 11:17:41 +00:00
Richard Jenkins
af76cef94b Fix bracket placement 2018-01-18 14:08:06 +00:00
Ted John
8630498213 Convert platform/windows.c to C++ (#7044) 2018-01-18 12:50:34 +00:00