Jonathan G Rennison
2a31095118
Merge branch 'master' into jgrpp
...
# Conflicts:
# regression/regression/result.txt
# src/aircraft_cmd.cpp
# src/airport_gui.cpp
# src/articulated_vehicles.cpp
# src/console_cmds.cpp
# src/date_gui.cpp
# src/engine.cpp
# src/genworld_gui.cpp
# src/gfx_layout_fallback.cpp
# src/group_gui.cpp
# src/hotkeys.cpp
# src/network/core/tcp_connect.cpp
# src/network/core/tcp_listen.h
# src/newgrf.cpp
# src/newgrf.h
# src/newgrf_engine.cpp
# src/newgrf_gui.cpp
# src/newgrf_station.cpp
# src/openttd.cpp
# src/order_gui.cpp
# src/os/macosx/osx_main.cpp
# src/pathfinder/yapf/yapf_node_rail.hpp
# src/rail_gui.cpp
# src/saveload/afterload.cpp
# src/saveload/cargopacket_sl.cpp
# src/saveload/linkgraph_sl.cpp
# src/saveload/station_sl.cpp
# src/script/api/script_industrytype.cpp
# src/settings.cpp
# src/settings_gui.cpp
# src/settings_table.cpp
# src/settingsgen/settingsgen.cpp
# src/station.cpp
# src/station_cmd.cpp
# src/strings.cpp
# src/timer/timer_game_calendar.cpp
# src/timer/timer_game_calendar.h
# src/timer/timer_manager.h
# src/timer/timer_window.cpp
# src/timetable_cmd.cpp
# src/toolbar_gui.cpp
# src/town_cmd.cpp
# src/town_gui.cpp
# src/train_gui.cpp
# src/vehicle_cmd.h
# src/vehicle_gui.cpp
# src/viewport.cpp
# src/widgets/dropdown.cpp
# src/window_func.h
# src/window_gui.h
2023-11-25 13:30:06 +00:00
Peter Nelson
69e20e79ab
Codechange: Add const versions of GetItem/GetGroup, and sprinkle liberally.
...
Non-const version of GetItem is not needed.
2023-10-20 18:37:27 +01:00
Peter Nelson
1fecbeff76
Codechange: Remove create parameter from IniLoadFile::GetGroup.
...
GetGroup now only returns nullptr if the group does not exist.
Use GetOrCreateGroup to create a group.
This avoids creating groups while reading ini files.
2023-10-20 18:37:27 +01:00
Peter Nelson
6ce7195ef1
Codechange: Split GetGroup into GetGroup/GetOrCreateGroup.
...
This follows the pattern used for GetItem/GetOrCreateItem, and allows use
of references where we know the group must exist.
2023-10-20 18:37:27 +01:00
Peter Nelson
0c85ce29ea
Codechange: Pass ini file by reference and prefer automatic storage.
...
This avoids new/delete operations, and (not) checking for nullptr.
2023-10-20 18:37:27 +01:00
frosch
b6c8f301be
Codechange: Silence warnings about intentionally unused parameters.
2023-09-19 22:49:59 +02:00
Jonathan G Rennison
c8817d7f4e
Merge branch 'master' into jgrpp
...
# Conflicts:
# os/macosx/notarize.sh
# src/3rdparty/CMakeLists.txt
# src/3rdparty/squirrel/squirrel/sqcompiler.cpp
# src/3rdparty/squirrel/squirrel/sqdebug.cpp
# src/3rdparty/squirrel/squirrel/sqvm.cpp
# src/console_cmds.cpp
# src/core/span_type.hpp
# src/crashlog.cpp
# src/currency.h
# src/date_gui.cpp
# src/driver.cpp
# src/fios.cpp
# src/genworld_gui.cpp
# src/hotkeys.cpp
# src/misc_gui.cpp
# src/music/os2_m.cpp
# src/network/core/os_abstraction.h
# src/network/network_server.cpp
# src/newgrf.cpp
# src/newgrf_config.h
# src/newgrf_text.cpp
# src/openttd.cpp
# src/os/macosx/font_osx.cpp
# src/os/macosx/misc_osx.cpp
# src/os/os2/CMakeLists.txt
# src/os/os2/os2.cpp
# src/os/unix/CMakeLists.txt
# src/os/windows/font_win32.cpp
# src/os/windows/win32_main.cpp
# src/saveload/saveload.cpp
# src/script/api/script_text.cpp
# src/settings.cpp
# src/settings_gui.cpp
# src/stdafx.h
# src/strings.cpp
# src/timetable_gui.cpp
# src/town_gui.cpp
# src/train_cmd.cpp
# src/video/dedicated_v.cpp
# src/video/video_driver.cpp
# src/video/win32_v.cpp
# src/viewport.cpp
# src/waypoint_gui.cpp
# src/widgets/dropdown_type.h
# src/window.cpp
# src/window_gui.h
2023-09-12 20:06:47 +01:00
Rubidium
eaae0bb5e7
Codechange: automatic adding of _t to (u)int types, and WChar to char32_t
...
for i in `find src -type f|grep -v 3rdparty/fmt|grep -v 3rdparty/catch2|grep -v 3rdparty/opengl|grep -v stdafx.h`; do sed 's/uint16& /uint16 \&/g;s/int8\([ >*),;[]\)/int8_t\1/g;s/int16\([ >*),;[]\)/int16_t\1/g;s/int32\([ >*),;[]\)/int32_t\1/g;s/int64\([ >*),;[]\)/int64_t\1/g;s/ uint32(/ uint32_t(/g;s/_uint8_t/_uint8/;s/Uint8_t/Uint8/;s/ft_int64_t/ft_int64/g;s/uint64$/uint64_t/;s/WChar/char32_t/g;s/char32_t char32_t/char32_t WChar/' -i $i; done
2023-07-19 19:30:14 +02:00
Jonathan G Rennison
ead18b2af2
Merge branch 'master' into jgrpp
...
# Conflicts:
# CMakeLists.txt
# src/3rdparty/md5/md5.h
# src/3rdparty/squirrel/squirrel/squtils.h
# src/animated_tile.cpp
# src/console_func.h
# src/core/CMakeLists.txt
# src/core/container_func.hpp
# src/core/smallstack_type.hpp
# src/crashlog.cpp
# src/crashlog.h
# src/debug.h
# src/economy.cpp
# src/gamelog.cpp
# src/industry_gui.cpp
# src/lang/catalan.txt
# src/misc_gui.cpp
# src/network/network_content.h
# src/newgrf.cpp
# src/newgrf.h
# src/newgrf_config.cpp
# src/newgrf_config.h
# src/newgrf_gui.cpp
# src/os/unix/font_unix.cpp
# src/os/windows/crashlog_win.cpp
# src/rail_cmd.cpp
# src/saveload/animated_tile_sl.cpp
# src/script/api/script_tilelist.cpp
# src/settings.cpp
# src/settingsgen/settingsgen.cpp
# src/sl/oldloader_sl.cpp
# src/station.cpp
# src/station_cmd.cpp
# src/stdafx.h
# src/strgen/strgen.cpp
# src/strgen/strgen_base.cpp
# src/table/settings/gui_settings.ini
# src/train_gui.cpp
# src/vehicle.cpp
# src/vehicle_base.h
# src/vehicle_cmd.cpp
# src/vehicle_gui_base.h
# src/viewport_sprite_sorter.h
2023-07-02 12:02:36 +01:00
Jonathan G Rennison
d09b504bc5
Merge branch 'master' into jgrpp
...
# Conflicts:
# .github/workflows/ci-build.yml
# .github/workflows/release-linux.yml
# .github/workflows/release-macos.yml
# .github/workflows/release-source.yml
# .github/workflows/release.yml
# CMakeLists.txt
# COMPILING.md
# src/ai/ai_core.cpp
# src/ai/ai_gui.cpp
# src/bridge_gui.cpp
# src/company_gui.cpp
# src/console_cmds.cpp
# src/core/CMakeLists.txt
# src/core/smallmap_type.hpp
# src/disaster_vehicle.h
# src/effectvehicle_base.h
# src/fontcache.cpp
# src/game/game_core.cpp
# src/game/game_gui.cpp
# src/gamelog.cpp
# src/gamelog_internal.h
# src/group_gui.cpp
# src/linkgraph/linkgraph.h
# src/misc.cpp
# src/network/core/config.h
# src/network/core/udp.cpp
# src/network/network_chat_gui.cpp
# src/network/network_content_gui.cpp
# src/network/network_gui.cpp
# src/newgrf.cpp
# src/newgrf_gui.cpp
# src/newgrf_profiling.cpp
# src/newgrf_profiling.h
# src/object_gui.cpp
# src/openttd.cpp
# src/openttd.h
# src/order_gui.cpp
# src/os/windows/font_win32.cpp
# src/rail_gui.cpp
# src/road.cpp
# src/road_gui.cpp
# src/saveload/afterload.cpp
# src/saveload/saveload.h
# src/script/api/script_controller.cpp
# src/script/api/script_roadtypelist.cpp
# src/script/script_config.cpp
# src/script/script_config.hpp
# src/script/script_instance.cpp
# src/script/script_scanner.cpp
# src/script/squirrel.cpp
# src/script/squirrel_helper.hpp
# src/settings_gui.cpp
# src/settings_internal.h
# src/settings_type.h
# src/table/settings/network_private_settings.ini
# src/timetable_gui.cpp
# src/vehicle.cpp
# src/vehicle_base.h
# src/window_gui.h
2023-07-01 02:42:51 +01:00
PeterN
64d6ad50f9
Codechange: Split GetItem with GetOrCreateItem. ( #10952 )
...
`IniGroup::GetItem()` returns nullptr if the item does not exist, but does not if the create parameter is set to true. Resolve CodeQL warnings with `GetOrCreateItem()` which returns a reference to the item instead.
2023-06-05 18:29:52 +00:00
PeterN
f814c86389
Codechange: Reorganise hotkey initialisation. ( #10951 )
...
Hotkeys are now initialized inline, and use std::vector instead of
separate static C-arrays and std::string instead of char *. The list end
marker is no longer required.
2023-06-05 18:12:30 +01:00
Jonathan G Rennison
02fe4af934
Merge branch 'master' into jgrpp
...
# Conflicts:
# .github/workflows/release-windows.yml
# src/company_base.h
# src/company_cmd.cpp
# src/company_gui.cpp
# src/console_cmds.cpp
# src/economy.cpp
# src/economy_cmd.h
# src/fios.h
# src/goal.cpp
# src/group_gui.cpp
# src/network/core/config.h
# src/network/network_admin.cpp
# src/newgrf_config.cpp
# src/os/windows/win32.cpp
# src/saveload/afterload.cpp
# src/saveload/company_sl.cpp
# src/saveload/saveload.cpp
# src/saveload/saveload_error.hpp
# src/settings_gui.cpp
# src/ship_cmd.cpp
# src/stdafx.h
# src/story.cpp
# src/story_base.h
# src/string.cpp
# src/table/settings/economy_settings.ini
# src/tests/CMakeLists.txt
# src/tests/math_func.cpp
2023-05-30 00:49:24 +01:00
Rubidium
80d8c01814
Codechange: replace std::vector + duplicate preventing include with std::set
2023-05-20 16:53:10 +02:00
Rubidium
86e5dfce3d
Codechange: use std::string instead of strecat to build hotkey strings
2023-05-12 22:02:59 +02:00
Rubidium
ee8b1dfbc3
Fix 4dd5f994
: hotkey parsing was broken
2023-04-29 14:56:41 +02:00
Rubidium
4dd5f994be
Codechange: replace strncasecmp with case ignoring variant of StrStarts/EndsWith
2023-04-29 10:25:25 +02:00
Jonathan G Rennison
6c3e5642f8
Merge branch 'master' into jgrpp
...
# Conflicts:
# cmake/CompileFlags.cmake
# src/crashlog.cpp
# src/fileio.cpp
# src/fileio_func.h
# src/fios_gui.cpp
# src/ini_load.cpp
# src/ini_type.h
# src/lang/english.txt
# src/lang/german.txt
# src/lang/korean.txt
# src/network/network_client.cpp
# src/order_base.h
# src/order_cmd.cpp
# src/os/windows/win32.cpp
# src/road_cmd.cpp
# src/saveload/saveload.cpp
# src/saveload/saveload.h
# src/settings.cpp
# src/station_cmd.cpp
# src/stdafx.h
# src/table/settings.ini
# src/tree_cmd.cpp
# src/tree_gui.cpp
# src/vehicle_base.h
# src/video/cocoa/cocoa_v.mm
# src/video/cocoa/event.mm
# src/video/cocoa/wnd_quartz.mm
# src/viewport.cpp
# src/widgets/tree_widget.h
2021-01-31 01:08:35 +00:00
Michael Lutz
dd138fc460
Codechange: Stringify config file paths.
2020-12-27 13:19:25 +01:00
Jonathan G Rennison
0bfae346c1
Allow using the hash key in hotkeys (SDL)
2020-09-21 03:52:50 +01:00
Jonathan G Rennison
aea747be08
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/hotkeys.cpp
2020-09-21 02:14:30 +01:00
dP
ab420d8cc0
Change: Use key names instead of characters in hotkey.cfg
2020-09-01 09:33:17 +01:00
Jonathan G Rennison
f8d6e781ba
Merge branch 'master' into jgrpp
...
# Conflicts:
# projects/openttd_vs140.vcxproj.filters
# projects/openttd_vs141.vcxproj.filters
# projects/openttd_vs142.vcxproj.filters
# src/base_consist.h
# src/company_base.h
# src/newgrf_config.cpp
# src/newgrf_config.h
# src/openttd.cpp
# src/saveload/saveload.cpp
# src/saveload/saveload.h
# src/saveload/station_sl.cpp
# src/settings.cpp
# src/signs_base.h
# src/string.cpp
# src/string_func.h
# src/table/misc_settings.ini
# src/table/settings.h.preamble
# src/town_cmd.cpp
# src/vehicle.cpp
# src/vehicle_cmd.cpp
# src/video/cocoa/cocoa_v.mm
# src/video/null_v.cpp
2020-05-21 22:24:01 +01:00
Michael Lutz
715aa67a9c
Codechange: Use std::string in INI file parsing.
2020-05-21 20:02:34 +02:00
Jonathan G Rennison
7960db35f2
Merge branch 'master' into jgrpp
...
# Conflicts:
# config.lib
# projects/openttd_vs140.vcxproj
# projects/openttd_vs140.vcxproj.filters
# projects/openttd_vs141.vcxproj
# projects/openttd_vs141.vcxproj.filters
# projects/openttd_vs142.vcxproj
# projects/openttd_vs142.vcxproj.filters
# src/aircraft_cmd.cpp
# src/base_station_base.h
# src/core/pool_type.hpp
# src/disaster_vehicle.cpp
# src/economy.cpp
# src/engine.cpp
# src/group.h
# src/group_cmd.cpp
# src/group_gui.cpp
# src/lang/english.txt
# src/lang/german.txt
# src/linkgraph/linkgraph_gui.cpp
# src/network/network_command.cpp
# src/network/network_server.cpp
# src/openttd.cpp
# src/order_cmd.cpp
# src/road_cmd.cpp
# src/saveload/afterload.cpp
# src/saveload/cargopacket_sl.cpp
# src/saveload/linkgraph_sl.cpp
# src/saveload/order_sl.cpp
# src/saveload/station_sl.cpp
# src/saveload/town_sl.cpp
# src/saveload/vehicle_sl.cpp
# src/screenshot.cpp
# src/screenshot.h
# src/settings_gui.cpp
# src/settings_type.h
# src/smallmap_gui.cpp
# src/station.cpp
# src/station_cmd.cpp
# src/table/settings.ini
# src/toolbar_gui.cpp
# src/town_cmd.cpp
# src/train.h
# src/train_cmd.cpp
# src/train_gui.cpp
# src/vehicle.cpp
# src/vehicle_base.h
# src/vehiclelist.cpp
# src/window_type.h
2020-01-06 18:45:51 +00:00
Konstantin Gribov
69f9529ba3
Add: Missing keycodes for hotkeys.cfg ( #7850 )
...
Added missing keycodes mapping to `_keycode_to_name` array
to allow their use in `hotkeys.cfg`.
Also reordered them according to `WindowKeyCodes` order.
Signed-off-by: Konstantin Gribov <grossws@gmail.com>
2019-12-27 08:32:34 +00:00
Jonathan G Rennison
cbdd9f84d8
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/console_gui.cpp
# src/lang/korean.txt
# src/video/sdl2_v.cpp
# src/video/sdl2_v.h
# src/window.cpp
# src/window_gui.h
2019-11-12 18:43:10 +00:00
S. D. Cloudt
13cc8a0cee
Cleanup: Removed SVN headers
2019-11-10 17:59:20 +00:00
Jonathan G Rennison
674732cd68
Merge: Codechange: Use null pointer literal instead of the NULL macro
2019-04-11 18:14:13 +01:00
Henry Wilson
7c8e7c6b6e
Codechange: Use null pointer literal instead of the NULL macro
2019-04-10 23:22:20 +02:00
Jonathan G Rennison
ba34ec7ade
Merge branch 'master' into jgrpp
...
Replace build and refit, and group collapse implementations
Fix template creation build and refit
# Conflicts:
# Makefile.bundle.in
# config.lib
# src/animated_tile.cpp
# src/blitter/32bpp_anim.hpp
# src/blitter/32bpp_base.hpp
# src/blitter/8bpp_base.hpp
# src/blitter/null.hpp
# src/build_vehicle_gui.cpp
# src/command.cpp
# src/command_func.h
# src/console_gui.cpp
# src/core/smallstack_type.hpp
# src/date.cpp
# src/debug.cpp
# src/genworld_gui.cpp
# src/ground_vehicle.hpp
# src/group_gui.cpp
# src/lang/korean.txt
# src/linkgraph/linkgraph_gui.h
# src/main_gui.cpp
# src/misc_gui.cpp
# src/network/core/game.h
# src/network/core/packet.cpp
# src/network/core/udp.cpp
# src/network/core/udp.h
# src/network/network_content.cpp
# src/network/network_type.h
# src/network/network_udp.cpp
# src/newgrf_house.h
# src/openttd.cpp
# src/order_cmd.cpp
# src/order_gui.cpp
# src/os/unix/crashlog_unix.cpp
# src/os/windows/crashlog_win.cpp
# src/osk_gui.cpp
# src/pathfinder/opf/opf_ship.cpp
# src/rail_cmd.cpp
# src/rail_gui.cpp
# src/saveload/saveload.cpp
# src/settings.cpp
# src/settings_gui.cpp
# src/smallmap_gui.h
# src/station_base.h
# src/station_cmd.cpp
# src/table/gameopt_settings.ini
# src/table/newgrf_debug_data.h
# src/table/settings.ini
# src/timetable_gui.cpp
# src/toolbar_gui.cpp
# src/train_gui.cpp
# src/vehicle.cpp
# src/vehicle_gui.cpp
# src/vehiclelist.cpp
# src/viewport.cpp
# src/widgets/dropdown.cpp
# src/window_gui.h
2019-03-27 18:12:04 +00:00
Henry Wilson
c01a2e2a81
Codechange: Removed SmallVector completely
2019-03-26 20:15:57 +00:00
Henry Wilson
ab711e6942
Codechange: Replaced SmallVector::[Begin|End]() with std alternatives
2019-03-26 20:15:57 +00:00
Henry Wilson
297fd3dda3
Codechange: Replaced SmallVector::Include() with include()
2019-03-26 20:15:57 +00:00
Henry Wilson
a0f36a50e6
Codechange: Replaced SmallVector::Append() with std::vector::[push|emplace]_back()
2019-03-26 20:15:57 +00:00
Henry Wilson
5795f66d2e
Codechange: Replaced SmallVector::Contains() with std::find() pattern
2019-03-26 20:15:57 +00:00
Henry Wilson
81315939b9
Codechange: Replaced SmallVector::Find() non-const with std::find()
2019-03-26 20:15:57 +00:00
Henry Wilson
a690936ed7
Codechange: Replace SmallVector::Length() with std::vector::size()
2019-03-26 20:15:57 +00:00
Henry Wilson
bfd79e59dc
Codechange: Replace SmallVector::Clear() with std::vector::clear()
2019-03-26 20:15:57 +00:00
Jonathan G Rennison
6bcc705c7c
Merge branch 'master' into jgrpp
...
# Conflicts:
# src/saveload/saveload.cpp
2018-09-20 08:32:56 +01:00
Samuel Cochran
1a73c39838
Add: BACKSPACE can be mapped as a hotkey
2018-09-16 11:36:25 +02:00
Jonathan G Rennison
83091f55da
Merge branch 'vehicle_group_info' into jgrpp
2017-04-01 01:02:22 +01:00
peter1138
48b9cbbb76
(svn r27816) -Fix [FS#6421]: Do not search directories when opening ini files as we already have their full path.
2017-03-20 19:30:49 +00:00
peter1138
73ea8cdb21
(svn r27816) -Fix [FS#6421]: Do not search directories when opening ini files as we already have their full path.
2017-03-20 19:30:49 +00:00
patch-import
536a95dfd0
Import combined Enhanced viewport: zoom out, overlays & tooltips (r53_27127) patch
...
https://www.tt-forums.net/viewtopic.php?f=33&t=53394
2015-08-05 21:24:30 +01:00
rubidium
034735a54c
(svn r26509) -Codechange: replace strdup with stredup (the latter ensures the return is not NULL)
2014-04-25 15:40:32 +00:00
rubidium
9ed12b0f07
(svn r26509) -Codechange: replace strdup with stredup (the latter ensures the return is not NULL)
2014-04-25 15:40:32 +00:00
rubidium
2be4215f43
(svn r26482) -Codechange: add an include that allows us to undefine/redefine "unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values
2014-04-23 20:13:33 +00:00
rubidium
0463dbdc9e
(svn r26482) -Codechange: add an include that allows us to undefine/redefine "unsafe" functions to prevent them from being used, and thus having to care about certain aspects of their return values
2014-04-23 20:13:33 +00:00
rubidium
3421bfc9ca
(svn r25973) -Fix [FS#5679]: comma key collided with F12 key for hotkeys; also remove '+' as that is generally not a key (the '+' on the numpad is a separate one)
2013-11-13 15:54:44 +00:00