Commit Graph

605 Commits (0a9c44d1a2b3b5de76595dfc74938fca34b3448a)

Author SHA1 Message Date
Jonathan G Rennison 0a9c44d1a2 Merge branch 'master' into jgrpp
# Conflicts:
#	src/airport_gui.cpp
#	src/blitter/32bpp_anim_sse4.cpp
#	src/console_cmds.cpp
#	src/linkgraph/linkgraph_gui.cpp
#	src/newgrf_object.h
#	src/road_gui.cpp
#	src/widgets/road_widget.h
#	src/window.cpp
2 years ago
Peter Nelson 5cc1a48db7 Change: Use NC_BIGFIRST in group window.
This means we no longer need to manually calculate the size of other
widgets in the window to determine how much space we need, as the widget
system will automatically fill as much as possible.
2 years ago
Jonathan G Rennison 0ac96a0da3 Show vehicle inspect window when ctrl-shift clicking in group list window 2 years ago
Jonathan G Rennison 904ff6757d Add slot support to road vehicles, ships and aircraft 2 years ago
Michael Lutz 57b82e2e99 Codechange: Don't use globals for story/goal/sign/group command proc return values. 2 years ago
Michael Lutz 8503854655 Codechange: Pass unpacked command arguments to command callbacks (except Script). 2 years ago
Michael Lutz e08b3abe7f Codechange: Un-bitstuff group and autoreplace commands. 2 years ago
Michael Lutz 21675ec7e2 Codechange: Un-bitstuff vehicle/engine commands. 2 years ago
Michael Lutz eab18f06a4 Codechange: Pass additional data as byte stream to command callbacks. 2 years ago
Michael Lutz 0f64ee5ce1 Codechange: Template DoCommandP to automagically reflect the parameters of the command proc.
When finished, this will allow each command handler to take individually
different parameters, obliviating the need for bit-packing.
2 years ago
Michael Lutz b0990fcff7 Codechange: Make TileIndex a "strong" typedef to give it a distinct type.
This is accomplished by changing it to a single member struct with the
appropriate operator overloads to make it all work with not too much
source modifications.
2 years ago
Michael Lutz 4fc055d6e9 Codechange: Align parameter order of command callbacks to command handlers. 2 years ago
Michael Lutz 123c7f99c3 Codechange: Move command callback declarations to the cmd header files. 2 years ago
Michael Lutz a38bbefe1b Codechange: Untangle command code, flags and error string for DoCommand*. 2 years ago
Michael Lutz 549caca39c Codechange: Move command arguments to the back of the networked command function calls. 2 years ago
Jonathan G Rennison 0691b25e17 Merge branch 'master' into jgrpp
# Conflicts:
#	src/saveload/afterload.cpp
3 years ago
Bernard Teo 0533b666b7
Fix #9702: Display order window for vehicle group on ctrl-click only when using shared orders (#9704) 3 years ago
Jonathan G Rennison 9e946d4c5d Merge branch 'master' into jgrpp-beta
# Conflicts:
#	src/command.cpp
#	src/console_cmds.cpp
#	src/group_gui.cpp
#	src/lang/catalan.txt
#	src/lang/czech.txt
#	src/lang/danish.txt
#	src/lang/greek.txt
#	src/lang/hungarian.txt
#	src/lang/irish.txt
#	src/lang/japanese.txt
#	src/lang/luxembourgish.txt
#	src/lang/norwegian_bokmal.txt
#	src/lang/romanian.txt
#	src/lang/russian.txt
#	src/lang/serbian.txt
#	src/lang/simplified_chinese.txt
#	src/lang/slovak.txt
#	src/lang/spanish_MX.txt
#	src/lang/swedish.txt
#	src/lang/tamil.txt
#	src/lang/traditional_chinese.txt
#	src/lang/turkish.txt
#	src/lang/ukrainian.txt
#	src/lang/vietnamese.txt
#	src/network/network.cpp
#	src/network/network_client.cpp
#	src/network/network_func.h
#	src/network/network_internal.h
#	src/network/network_server.cpp
#	src/network/network_server.h
#	src/saveload/afterload.cpp
#	src/saveload/newgrf_sl.cpp
#	src/saveload/saveload.h
#	src/script/script_instance.cpp
#	src/toolbar_gui.cpp
#	src/toolbar_gui.h
#	src/vehicle_gui.cpp
#	src/widgets/rail_widget.h
#	src/widgets/vehicle_widget.h
#	src/window.cpp
3 years ago
Jonathan G Rennison 9ad5e4baf0 Add maximum speed (fully loaded) to train window sort list 3 years ago
Bernard Teo 6a6dbbaad2 Feature: Ctrl-Clicking GB_SHARED_ORDERS vehicle list opens order window 3 years ago
Jonathan G Rennison dab1501b7c
Merge pull request #292 from VacuumBreather/minor_additions
Minor additions
3 years ago
Jonathan G Rennison 906ee568d6 Use a lower resort interval in veh windows when sorting by timetable delay 3 years ago
Andreas Schmitt 0f07ae839d Make the sort order toggle button resort a vehicle list 3 years ago
Jonathan G Rennison d246ba1dd1 Lower create group button when vehicle dragged over it 3 years ago
Jonathan G Rennison 6c07758cc3 Do name generation at client, fix localisation
Use existing group creation command
3 years ago
Andreas Schmitt 5d505f2389 Fix crash and show error message if group creation fails 3 years ago
Andreas Schmitt 8b66ebd4f0 Add auto named group generated when dropping a vehicle onto new group button 3 years ago
Jonathan G Rennison 1002c6d9d2 Fix various compiler warnings
See: #267
3 years ago
glx22 5799402f7a Codechange: Rename window related DeleteXXX to match new behaviour 3 years ago
Jonathan G Rennison 253772e9af Merge branch 'master' into jgrpp
# Conflicts:
#	CMakeLists.txt
#	COMPILING.md
#	src/console.cpp
#	src/console_cmds.cpp
#	src/console_internal.h
#	src/rev.cpp.in
3 years ago
Jonathan G Rennison 2e5b8d8110 Fix vertical alignment of group info panel
See also: https://github.com/OpenTTD/OpenTTD/pull/9041
3 years ago
Jonathan G Rennison f83b71828e Partially revert 8e539ce2: Fix train/RV spacing at normal zoom
See: https://github.com/OpenTTD/OpenTTD/pull/9041
3 years ago
Jonathan G Rennison 1e4161ff56 Merge branch 'master' into jgrpp
# Conflicts:
#	src/group_gui.cpp
3 years ago
peter1138 c56fce70b4 Codechange: Replace CMD_SET_GROUP_REPLACE_PROTECTION with generic CMD_SET_GROUP_FLAG. 3 years ago
peter1138 27a956ba62 Codechange: Replace Group::replace_protection with Group::flags 3 years ago
Peter Nelson 2a0365b3d9 Cleanup: Remove unnecessary parameter of GetScrolledRowFromWidget()
Line height defaults to the resize height of the relevant widget, which is
set in all cases. Therefore it is not necessary to specify this value every time.

Additionally fixes scrolled padding for the framerate window.
3 years ago
PeterN 8e539ce293
Change: Improve layout and spacing of vehicle group widgets. (#9041)
Existing layout included a blank widget above the group list to align with the vehicle list, however since then an additional sort-by row was added.
Group list size tweaks to match normal row size (at least with normal gui and text size.)
Removed reduction of 2 rows in the group list <- main culprit of odd sizing.
Removed fill attribute on buttons which gave strange sizes, and put it on the group info widget instead.
Tweaked various soft-padding values to line up (centreing text with a 1px offset does not make centred text.)
3 years ago
Jonathan G Rennison edfa04286b Merge branch 'master' into jgrpp
# Conflicts:
#	.github/workflows/release.yml
#	bin/CMakeLists.txt
#	src/dock_gui.cpp
#	src/lang/brazilian_portuguese.txt
#	src/lang/catalan.txt
#	src/lang/czech.txt
#	src/lang/dutch.txt
#	src/lang/english.txt
#	src/lang/english_US.txt
#	src/lang/estonian.txt
#	src/lang/finnish.txt
#	src/lang/french.txt
#	src/lang/german.txt
#	src/lang/hungarian.txt
#	src/lang/indonesian.txt
#	src/lang/italian.txt
#	src/lang/japanese.txt
#	src/lang/korean.txt
#	src/lang/lithuanian.txt
#	src/lang/luxembourgish.txt
#	src/lang/norwegian_bokmal.txt
#	src/lang/polish.txt
#	src/lang/portuguese.txt
#	src/lang/romanian.txt
#	src/lang/russian.txt
#	src/lang/serbian.txt
#	src/lang/simplified_chinese.txt
#	src/lang/slovak.txt
#	src/lang/spanish.txt
#	src/lang/spanish_MX.txt
#	src/lang/swedish.txt
#	src/lang/tamil.txt
#	src/lang/ukrainian.txt
#	src/lang/vietnamese.txt
#	src/newgrf.cpp
#	src/newgrf_gui.cpp
#	src/object_gui.cpp
#	src/pathfinder/yapf/yapf_costrail.hpp
#	src/pathfinder/yapf/yapf_node_rail.hpp
#	src/rail_cmd.cpp
#	src/roadveh_cmd.cpp
#	src/town_cmd.cpp
#	src/vehicle.cpp
#	src/water_cmd.cpp
3 years ago
Bernard Teo f0a24e98f5
Fix #8922: Show vehicle window for single vehicle in shared order grouping (#8926) 3 years ago
Jonathan G Rennison e95216b59d Merge branch 'master' into jgrpp
# Conflicts:
#	src/company_cmd.cpp
#	src/core/geometry_func.cpp
#	src/date.cpp
#	src/genworld_gui.cpp
#	src/gfx.cpp
#	src/object_gui.cpp
#	src/openttd.cpp
#	src/settings_type.h
#	src/video/allegro_v.cpp
#	src/video/dedicated_v.cpp
#	src/video/null_v.cpp
#	src/video/sdl2_v.cpp
#	src/video/sdl_v.cpp
#	src/video/win32_v.cpp
3 years ago
SamuXarick a4035af337
Codechange: Apply coding style (#8640)
* Fix: Missing or needed spaces

* Codechange: Remove space

* Codechange: Remove space

* Codechange: More missing spaces

* Codechange: Missing spaces

* Codechange: Remove space

* Codechange: Remove space
3 years ago
Jonathan G Rennison b7ddd486cf Merge branch 'master' into jgrpp
# Conflicts:
#	cmake/CompileFlags.cmake
#	src/aircraft_cmd.cpp
#	src/blitter/32bpp_anim.cpp
#	src/cargopacket.cpp
#	src/cheat_gui.cpp
#	src/company_cmd.cpp
#	src/company_gui.cpp
#	src/core/pool_func.hpp
#	src/date.cpp
#	src/economy.cpp
#	src/error_gui.cpp
#	src/ground_vehicle.cpp
#	src/ground_vehicle.hpp
#	src/group_gui.cpp
#	src/industry_cmd.cpp
#	src/lang/dutch.txt
#	src/lang/french.txt
#	src/lang/german.txt
#	src/linkgraph/linkgraph_gui.cpp
#	src/linkgraph/mcf.cpp
#	src/network/network_content.cpp
#	src/network/network_server.cpp
#	src/network/network_udp.cpp
#	src/newgrf_engine.cpp
#	src/newgrf_station.cpp
#	src/order_cmd.cpp
#	src/order_gui.cpp
#	src/pathfinder/follow_track.hpp
#	src/pathfinder/yapf/yapf_common.hpp
#	src/saveload/saveload.cpp
#	src/settings_gui.cpp
#	src/station_cmd.cpp
#	src/station_kdtree.h
#	src/string_func.h
#	src/table/settings.ini
#	src/tgp.cpp
#	src/timetable_cmd.cpp
#	src/timetable_gui.cpp
#	src/toolbar_gui.cpp
#	src/town_cmd.cpp
#	src/train_cmd.cpp
#	src/train_gui.cpp
#	src/tree_gui.cpp
#	src/tunnelbridge_cmd.cpp
#	src/vehicle.cpp
#	src/vehicle_gui.cpp
#	src/video/sdl2_v.cpp
#	src/video/sdl_v.cpp
#	src/video/win32_v.cpp
#	src/viewport.cpp
#	src/viewport_sprite_sorter_sse4.cpp
#	src/window.cpp
3 years ago
Jonathan G Rennison 39df1c49a1 Merge branch 'master' into jgrpp
# Conflicts:
#	src/fileio.cpp
#	src/group_gui.cpp
#	src/industry.h
#	src/lang/korean.txt
#	src/linkgraph/linkgraphjob.cpp
#	src/linkgraph/linkgraphjob.h
#	src/linkgraph/linkgraphschedule.cpp
#	src/linkgraph/linkgraphschedule.h
#	src/openttd.cpp
#	src/saveload/saveload.cpp
#	src/saveload/saveload.h
#	src/town_cmd.cpp
#	src/vehicle_gui.cpp
#	src/vehicle_gui_base.h
3 years ago
Charles Pigott 9b800a96ed
Codechange: Remove min/max functions in favour of STL variants (#8502) 3 years ago
Patric Stout c988b4d62b
Fix #8332: aborting group drag&drop could cause crashes with vehicle drag&drop (#8511)
The selected group was not reset when drag&drop was aborted. When
after that vehicle drag&drop was successful, group drag&drop code
was still executed, causing weird behaviour or even crashes.
3 years ago
Bernard Teo 4af1acfe92 Feature: Drag-and-drop vehicles in group GUI for shared order groups 3 years ago
Bernard Teo a5047b7566 Cleanup: Use range-based for-loop in group_gui.cpp 3 years ago
Bernard Teo e59c400ca6 Feature: Option to group vehicle lists by shared orders
This applies to all kinds of vehicle lists, as well as the "vehicle groups" window.
3 years ago
Bernard Teo 584df548f1 Codechange: Make vehicle lists internally support grouping of vehicles
This is in preparation for the new UI feature that allows grouping by shared orders.
3 years ago
Jonathan G Rennison 66630ef8df Fix crash in group GUI vehicle/group dragging
See: https://github.com/OpenTTD/OpenTTD/issues/8332
4 years ago