1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-06 06:32:56 +01:00
Commit Graph

295 Commits

Author SHA1 Message Date
Gymnasiast
be31812fa8 Create strong enum for ScenarioSelectMode 2025-03-25 15:09:23 +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
73
a976a43708 Rename network.h to Network.h (#23882) 2025-02-24 10:43:06 +01:00
73
c7c703515e Rename audio.h to Audio.h (#23842) 2025-02-17 13:24:03 +01:00
73
b9b2c96c97 Rename sprites.h to SpriteIds.h (#23804) 2025-02-13 15:51:46 +00:00
Michael Steenbeek
cfb28cd511 Turn Rotate View dropdown into two buttons
Co-authored-by: Gymnasiast <gymnasiast@users.noreply.github.com>
Co-authored-by: MasterTomNL <tomvanderlek@gmail.com>
2025-01-30 23:02:36 +01: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
Ethan O'Brien
a34e5f840d Use kStringIdNone on emscripten buttons 2025-01-20 08:31:12 -06:00
Ethan O'Brien
0310084c04 Merge branch 'develop' into develop 2025-01-20 08:28:57 -06:00
Aaron van Geffen
a8773dd805 Move WindowClose family into WindowManager (#23646)
* Replace WindowClose() calls with Close method calls where possible

* Move WindowClose family into WindowManager

* Remove UpdateSceneryGroupIndexes hack
2025-01-19 18:49:18 +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
Ethan O'Brien
0fc6daf663 Resolve merge conflicts 2025-01-18 18:11:49 -06:00
Matt
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
Ethan O'Brien
f7ca73c6eb Correct Persistent spelling 2025-01-17 09:33:05 -06:00
Ethan O'Brien
b4d72427ff Resolve code formatting issues 2025-01-17 08:36:38 -06:00
Ethan O'Brien
89859a40f9 Move export/import functions to a javascript library 2025-01-17 08:32:25 -06:00
Ethan O'Brien
8dfe1f91a9 Resolve merge conflicts 2025-01-10 12:16:03 -06:00
Ethan O'Brien
1a7251d46f Remove dead defines 2025-01-09 15:19:01 -06:00
Aaron van Geffen
fa06a49302 Update copyright year to 2025 (#23514) 2024-12-31 20:30:04 +01:00
Ethan O'Brien
63b0106de8 Fix emscripten support 2024-12-31 09:31:33 -06:00
Aaron van Geffen
6ee798337a Introduce EnumUtils header (#23407) 2024-12-15 17:39:52 +01:00
Aaron van Geffen
e70ca5c889 Allow staff to use ‘real’ names as well (#22732) 2024-09-15 20:18:00 +00:00
Aaron van Geffen
b971d1596e Indent window widget definitions (#22700)
* Indent definitions in About, AssetPacks windows

* Indent definitions in Banner, Changelog, CustomCurrency windows

* Indent DebugPaint, DemolishRidePrompt windows

* Indent EditorBottomToolbar, EditorInventionsList

* Indent EditorObjectiveOptions, EditorScenarioOptions

* Indent Finances

* Indent Footpath

* Indent GameBottomToolbar

* Indent Guest window

* Indent GuestList, InstallTrack windows

* Indent Land, LandRights windows

* Indent LoadSave, Main, MapGen, MapTooltip windows

* Indent MazeConstruction

* Indent Multiplayer

* Indent NetworkStatus

* Indent NewCampaign

* Indent NewRide window

* Indent News window

* Indent NewsOptions window

* Indent ObjectLoadError window

* Indent Options window

* Indent Park window

* Indent PatrolArea window

* Indent Player window

* Indent RefurbishRidePrompt window

* Indent Research window

* Indent Ride window

* Indent RideConstruction

* Indent RideList

* Indent SavePrompt

* Indent ScenarioSelect widgets

* Indent scenario window

* Indent scenery scatter window defs

* Indent server list window

* Indent server start window§

* Indent ShortcutKeys window

* Indent Sign window

* Indent Staff window

* Indent StaffFirePrompt window

* Indent StaffList window defs

* Indent Themes window defs

* Indent TileInspector window defs

* Indent TitleExit, TitleMenu, TitleOptions, Tooltip windows

* Indent TrackDesignManage window defs

* Indent TrackDesignPlace defs

* Indent TrackList def

* Indent Transparency window defs

* Indent ViewClipping window defs

* Indent Viewport window defs

* Indent Water window defs
2024-09-04 21:11:26 +02:00
Matt
06501b0e9a Fix #22316: Always recreate the window when changing drawing engine 2024-08-12 23:49:58 +02:00
Aaron van Geffen
aa7eb18d78 Rename ScrollBar struct to ScrollArea and rename its properties (#22539) 2024-08-11 16:21:53 +02:00
Aaron van Geffen
05e56517ab Adopt existing namespaces into OpenRCT2 namespace (#22368)
* Put all of TitleSequenceManager into the same namespace

* Move RideConstructionState into the OpenRCT2 namespace

* Adopt existing namespaces into OpenRCT2 namespace

This adds `using namespace OpenRCT2` to compilation units where appropriate,
as a means to get the codebase to compile until these units have been placed
in a namespace of their own.
2024-07-26 09:59:58 +02:00
Aaron van Geffen
3d5c19de08 Drop Localisation.h include where not required 2024-07-13 13:33:32 +02:00
Aaron van Geffen
a97820f297 Move kRideInspectionIntervalNames into Ride unit 2024-07-13 12:30:40 +02:00
Aaron van Geffen
3fd91038c3 Rename Date.h to Localisation.Date.h to match unit file 2024-07-12 22:18:43 +02:00
Aaron van Geffen
51873dc0f6 Include Diagnostic.h at unit level 2024-07-09 16:23:31 +02:00
Arnold Zhou
fb7961e30a Split off Enlarged UI from touch enhancements
Co-authored-by: Gymnasiast <Gymnasiast@users.noreply.github.com>
2024-06-14 20:49:12 +00:00
Arnold Zhou
63d1259fd7 Fix missing tooltip for Enlarged UI option 2024-06-04 12:09:03 +02:00
Gymnasiast
8a181b5513 Split colours and colour flags 2024-05-26 12:35:40 +02:00
Aaron van Geffen
adc8c5e6a2 Close the gap in advanced options tab (#22088) 2024-05-23 21:17:44 +02:00
Gymnasiast
5522b5cb03 Add Enlarged UI setting 2024-05-18 20:55:20 +02:00
rohan4412
24a24e3f53 Part of #21421: Replace constants that use #define with ones that use constexpr (#21883)
* rename MAX_SCROLLING_TEXT_MODES to kMaxScrollingTextModes

* Rename FRAME_RENDERING_START to kFrameRenderingStart

* Rename FRAME_EFFECTS_START to kFrameEffectStart

* Rename CONTROLS_GROUP_START to kControlsGroupStart

* Rename THEMES_GROUP_START to kThemesGroupStart

* Rename TOOLBAR_GROUP_START to kToolbarGroupStart

* Rename TITLE_SEQUENCE_START to kTitleSequenceStart
2024-05-18 10:37:42 +00:00
Aaron van Geffen
05448222e2 Options: extract common code to ToggleToolbarSetting helper 2024-05-08 21:22:28 +02:00
Aaron van Geffen
e423575411 Add a config setting to toggle toolbar mode 2024-05-08 21:19:57 +02:00
Aaron van Geffen
a63d86c488 Introduce Config namespace and struct 2024-05-10 12:10:21 +02:00
Aaron van Geffen
ba9c84f835 Move Csg path related functions into their own header (#22004) 2024-05-10 12:05:52 +02:00
Michał Janiszewski
7b12667ddb Reduce <algorithm> include (#21947) 2024-05-01 13:47:27 +02:00
Aaron van Geffen
255e89ec37 Refactor TitleScreen to TitleScene; introduce GameScene
Co-authored-by: ζeh Matt <5415177+ZehMatt@users.noreply.github.com>
2024-04-23 21:31:05 +02:00
CoryY
3f81a491b0 Close #21569: Remove 'Window' from Window Open function names (#21613)
* Close #21569: Remove 'Window' from Window Open function names

Windows are all under the OpenRCT2::Ui::Windows namespace. As such, "Window" is removed from the Open functions names.

* Update Contributors.md

* Fix formatting TrackMangeOpen

Co-authored-by: Tulio Leao <tupaschoal@gmail.com>

* Fix formatting TrackPlaceOpen

Co-authored-by: Tulio Leao <tupaschoal@gmail.com>

---------

Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2024-03-17 06:37:46 +00:00
Jan Kelemen
9bb678688e Fix #21434: Number of guests overflows in objective text 2024-03-14 19:49:57 +01:00
Harry Hopkinson
78d95fc0bd Pass DrawPixelInfo by reference (#21563) 2024-03-10 12:00:08 -03:00
Duncan
7a60e7f2e0 OpenRCT2::Ui::Windows namespace for OpenRCT2 Ui Windows (#21559)
* Move all the windows into OpenRCT2::Ui::Windows namespace

* Fix missing symbol

* Clang format

* Call the correct FormatStringID
2024-03-10 13:52:35 +00:00
Duncan
3146d463bd Move Ui header items to OpenRCT2::Ui (#21546)
* Move ui definitions to ui project

* Enforce coding style

* Apply clang format

* Add clang tidy ignore

* Increase compiler happiness
2024-03-09 14:15:45 +00:00
Harry Hopkinson
ef9840f29b Replace static_cast with EnumValue 2024-03-04 15:37:20 +00:00