Commit Graph
223 Commits
Author SHA1 Message Date
Michael Steenbeek 6f24577027 Fix return value of Widget::width() 2025-11-08 10:27:58 +01:00
Gymnasiast 64ef3da5a4 Use FlagHolder in ColourWithFlags 2025-11-03 23:25:31 +01:00
Gymnasiast 124352c922 Update members of TextAlignment 2025-11-03 23:25:29 +01:00
Gymnasiast 4158ddfe11 Change CheatType to lowerCamelCase 2025-10-01 20:34:54 +02:00
Gymnasiast a662c5ef8e Change WindowClass members to use lowerCamelCase 2025-09-17 23:18:52 +02:00
Gymnasiast 3a803e13e2 Change window functions to use lowerCamelCase 2025-09-17 20:10:12 +02:00
Gymnasiast d4a0bca091 Rename Window fields 2025-09-17 20:10:12 +02:00
Aaron van Geffen 4446ff9f6f Pass game state ref as parameter to game actions (#25065) 2025-09-08 16:21:29 +02:00
matheusvb3 353f444057 Merge pull request #25109 from matheusvb3/clean-cheats
Remove redundant braces in Cheats.cpp
2025-09-06 20:32:10 +02:00
Michael Steenbeek ba2ed7564c Merge pull request #25027 from Gymnasiast/refactor/dropdown-3
Move more global dropdown stuff into individual items
2025-08-27 17:26:43 +02:00
Aaron van Geffen a052437d12 Move Park game actions to GameActions namespace 2025-08-26 20:52:46 +02:00
Aaron van Geffen e8ef3897df Rework more game actions into GameActions namespace 2025-08-26 14:22:58 +02:00
Gymnasiast bde70ea95f Create MenuLabel constructor 2025-08-24 11:30:59 +02:00
Gymnasiast af50e9b0da Fold tooltips and images into dropdown items 2025-08-24 11:30:59 +02:00
Gymnasiast ff896787ac Replace dropdown disabled/checked functions 2025-08-24 11:30:58 +02:00
Michael Steenbeek 577c3336c6 Create struct for all dropdown-related globals (#25023) 2025-08-23 13:56:13 +02:00
Michael Steenbeek 92f493b28a Merge pull request #25010 from Gymnasiast/refactor/more-code-style
More code style refactors
2025-08-21 22:26:52 +02:00
Gymnasiast 9c810d9e32 Update ParkData fields to new code style 2025-08-21 22:12:41 +02:00
Gymnasiast 8fd9658cd3 Update dropdown item fields and functions to new code style 2025-08-21 21:33:22 +02:00
Michael Steenbeek 7b322d825a Refactor constants in window .cpp files 2025-06-16 23:10:47 +02:00
Gymnasiast 81e3181ebb Pass ScreenSize to makeWindowShim() 2025-06-10 23:21:15 +02:00
Gymnasiast bdba89f428 Pass ScreenSize to window creation functions 2025-06-10 23:20:28 +02:00
Gymnasiast 650fa3ae2e Rename WindowWidgetType to WidgetType and change for new code style 2025-06-10 19:55:12 +02:00
Gymnasiast 149468406b Update WindowColour enum for new code style 2025-06-10 19:53:12 +02:00
Gymnasiast 86e265f093 Make widget creation functions lowerCamelCase 2025-06-10 19:51:21 +02:00
Aaron van Geffen 0779b9f0ab Replace window shim and widget macros with constexpr functions (#24566) 2025-06-07 23:02:14 +02:00
Matt 6335c31336 Rename DrawPixelInfo to RenderTarget (#24339)
* Begin backend separation, rename type DrawingPixelInfo to RenderTarget

* Rename dpi variables to rt
2025-05-04 22:06:46 +00:00
Aaron van Geffen 3f87e2b67a Centralise ResizeFrame in WindowBase and call when setting widgets or resizing 2025-04-11 20:37:54 +02:00
Aaron van Geffen 1381eb4a5c Correctly reposition all tabs when using the cheats window in the editor (#24209) 2025-04-13 18:41:45 +02:00
Aaron van Geffen 47795f398c Adjust more hardcoded top positions 2025-04-06 11:53:29 +02:00
Gymnasiast 4badffcdb6 Change GameState_t members to lowerCamelCase 2025-03-20 23:05:57 +01:00
Aaron van Geffen 92212369d4 Skip setting page/widgets if we're already on the page (#23975) 2025-03-12 19:50:19 +01:00
Michael Steenbeek 06c1fed4f7 Refactor gScreenFlags to LegacyScene enum 2025-03-05 20:45:04 +00:00
Michael Steenbeek 9f343abdda Reduce hardcoded positions for various windows 2025-02-26 21:09:54 +01:00
73 a976a43708 Rename network.h to Network.h (#23882) 2025-02-24 10:43:06 +01:00
73 b9b2c96c97 Rename sprites.h to SpriteIds.h (#23804) 2025-02-13 15:51:46 +00:00
Aaron van Geffen 6933af25ae Rename 'Climate' properties to Weather (#23786)
* Rename ClimateState to WeatherState

* Rename ClimateCurrent to WeatherCurrent

* Rename ClimateNext to WeatherNext

* Rename ClimateUpdateTimer to WeatherUpdateTimer

* Use named initialisers for weather state import in S4/S6 importers

* Rename S4::ClimateTimer to WeatherUpdateTimer as well

* Rename WeatherState struct properties to lowerCamelCase
2025-02-13 07:38:45 -03:00
Aaron van Geffen cf448753c1 Move WindowInvalidate and WidgetInvalidate families into WindowManager (#23692)
* Move WindowInvalidate and WidgetInvalidate families into WindowManager

* Use InvalidateWidget shorthand in more places

* Cut back on UiContext includes

* Cut back on Window.h includes

* Remove outdated parameter comments
2025-01-25 13:46:08 +01:00
Michael Steenbeek be9f27e4f9 Mass rename constants (#23656) 2025-01-19 15:59:45 +00:00
Aaron van Geffen 5fbe8d0ae1 Centralise external window signatures in Windows.h (#23653) 2025-01-19 15:50:54 +01:00
Aaron van Geffen bed4d5bdca Move WindowCreate and WindowFocusOrCreate into WindowManager (#23643)
* Move WindowBringToFront into WindowManager

* Move WindowCreate and WindowFocusOrCreate into WindowManager

* Cut back on Context/UiContext includes
2025-01-19 06:58:28 -03:00
MattandAaron van Geffen b9f6b6f754 Refactor widgets state (#23621)
* Refactor windows to not share widget state

* First half of refactoring all the windows

* Refactor the remaining windows, compiles but has issues

* Fix drawing only every second widget

* Remove the need of an terminating widget

* Address WidgetIndex signedness issues; use kWidgetIndexNull more

* Address constexpr issue with Widget content union

* Fix tabs in scenery window

* Fix tabs in object selection window

* Adjust custom widget index for CustomTool events

* Use STR_NONE for default tooltip initialisation

* Adjustment for mingw compiler

* Fix bottom toolbar using the widget declaration not instance

* Remove pointless code in Guest window, handled by SetPage

* Prevent out of bounds crash

* Move scroll widgets initialization to SetPage in Cheats window

* Remove special logic in Options window

* Remove special logic in Park window

* Remove special logic for Player window

* Remove special logic for Research window

* Remove special logic for Ride window

* Remove special logic for Staff window

* Remove special logic for Finances window

* Remove special logic for MapGen window

* Remove special logic for editor objective options window

* Remove special logic for editor scenario options window

* Fix widgets not being set since page is initialized to 0

* Remove more redundant code

* Fix remaining access to widget declarations

* Remove unused variable

* Fix editor object selection tabs on successive windows

---------

Co-authored-by: Aaron van Geffen <aaron@aaronweb.net>
2025-01-18 13:45:17 +01:00
Aaron van Geffen fa06a49302 Update copyright year to 2025 (#23514) 2024-12-31 20:30:04 +01:00
Aaron van Geffen 6ee798337a Introduce EnumUtils header (#23407) 2024-12-15 17:39:52 +01:00
RedMarcher c24e47dea1 Rename cheat variables to match new code style 2024-12-01 18:15:37 +01:00
Michael Steenbeek a2ed026264 Split up remaining tile elements 2024-10-15 22:02:31 +02:00
Aaron van Geffen 1bfd3febe6 Rework guest cheats tab layout and strings 2024-08-19 22:20:40 +02:00
Aaron van Geffen 3138730d33 Move 'Allow building while paused' cheat to park cheats 2024-08-19 21:22:53 +02:00
Aaron van Geffen 4e0d00f71b Reorganise park cheats to account for moved widgets 2024-08-19 20:50:28 +02:00
Aaron van Geffen 493bee46e7 Move staff cheats to their own tab as well 2024-08-19 20:40:04 +02:00