Commit Graph
110 Commits
Author SHA1 Message Date
Hielke Morsink a258008bef Refactor window functions to take references 4 2022-07-31 17:23:16 +02:00
Hielke Morsink 523bb8136e Refactor window functions to take references 3 2022-07-31 17:23:16 +02:00
Hielke Morsink c8605a8763 Refactor window functions to take references 2 2022-07-31 17:23:15 +02:00
Hielke Morsink 76c1bc8980 Refactor window functions to take references 1 2022-07-31 17:23:15 +02:00
Hielke Morsink ba85cf4873 Close #15896: Refactor out the ZoomLevel operators 2022-02-26 23:14:59 +01:00
Ted John 501328bc9a Fix #16712: [Plugin] Crash when clicking on a list view item 2022-02-24 21:39:11 +01:00
Ted John 007a33404e Close plugin's windows gracefully when stopped
When a plugin is stopped, close all windows created by that plugin.
Ensure the close event on the window can not open a new window if the plugin is being stopped.
2022-02-17 20:18:30 +00:00
Duncan ad86544c83 Merge pull request #16668 from IntelOrca/fix/plugin-pressed-tab
Fix pressed tab for plugin windows
2022-02-17 16:13:41 +00:00
Michael Steenbeek ffe67ff33e Merge pull request #16642 from Gymnasiast/refactor/dropdown
Create Dropdown::Item and use it for gDropdownItems
2022-02-15 18:50:26 +01:00
Ted John b5127089e2 Fix pressed tab for plugin windows 2022-02-15 10:37:18 +00:00
Ted John b775832d01 Refactor window flags to be read with the helper methods 2022-02-13 23:09:42 +00:00
Ted John da89a4e413 Remove rct_window::enabled_widgets (#16643)
`enabled_widgets` was used to enable input for widgets. However I do not recall anywhere this being used to specifically disable a widget which doesn't use the dedicated `disabled_widgets` flag. I don't think there is any purpose in keeping this, so I have removed all uses of it.
2022-02-13 23:06:19 +00:00
Gymnasiast 723867e0a0 Create Dropdown::Item and use it for gDropdownItems 2022-02-12 23:57:22 +01:00
Ted John 992ece4a4c Fix #16449: Viewport doesn't close when switching tabs 2022-01-19 10:23:44 +01:00
frutiemax adb692b74e Forward declare Formatter 2021-12-30 12:17:51 -05:00
Duncan 90d2be3ddd Clang tidy Part 3: Ui Project Enum Names (#15986)
* Enum constant case

* Apply enum names clang tidy

* Rename scoped enum missed by clang-tidy
2021-11-26 14:25:34 +00:00
Michał Janiszewski ce1d3e9c83 Minor fixes (#15491) 2021-09-29 21:06:46 +00:00
Hielke Morsink 9dd9b27db4 Make WIDGETS_END constexpr 2021-09-26 11:11:42 +02:00
Duncan a268350615 Fix #15439: Ride viewport is partially grey
The ride viewport does not work the same as other viewports due to the selection of views that it has. After refactoring the focus system to use a more streamlined approach the ride viewport lost its invalidation on resizing. If the ride window was to use the same viewport update code as say the guest window then the viewport focus still ends up incorrect due to it no longer centring the focus. Therefore the best approach was to lose the focus on resize and force a recalculation of it.

Also renamed Focus2 to Focus as Focus2 was meant to just be fill in whilst removing the original focus structs.
2021-09-21 11:06:04 +02:00
Duncan fa57b6aea0 Remove focus union and replace with typed focus (#15426)
* Remove focus union and replace with typed focus

This if for the NSF to allow for CoordsXYZ

* Remove legacy structures

* Rework viewport_create to deduplicate logic

* Simplify yet further

* Apply review comments

* Remove intermediate
2021-09-18 20:34:38 +01:00
Hielke Morsink 4b4b3333d6 Remove unnecessary else blocks 2021-09-16 18:31:12 +02:00
Ted John 40a4a993de Fix #15170: Plugin: incorrect label text alignment (#15175)
Initialise CustomWidgetDesc::TextAlign.
2021-08-04 21:47:13 +02:00
Hielke Morsink e54dc7e466 Use consistent left-shift notation for widgets (#14956) 2021-06-26 14:23:15 +02:00
duncanspumpkin 98f9f24909 Remove sprite.h includes where possible 2021-05-29 08:54:33 +01:00
Michael Steenbeek a5a63f839a Allow passing ImageId into gfx_draw_sprite() 2021-03-23 11:58:09 +01:00
Ted John e000f06442 Remove holdable flag from spinner widget 2021-02-25 22:30:35 +00:00
Ted John d64bd60278 Fix CI errors 2021-02-24 22:54:53 +00:00
Ted John c2183989a5 Allow spinners to be clicked and held 2021-02-24 22:37:31 +00:00
Ted John 93f17f1175 Add custom widget logic and network stats API 2021-02-24 22:37:31 +00:00
Ted John 82b1a5eb6d Convert CustomWindow into a class 2021-02-24 22:37:31 +00:00
Michał Janiszewski 9aef29361f Default-initialise more fields (#14130)
Doesn't really fix any particular issue, but adds more defaults to
fields in classes where other defaults are already present
2021-02-20 19:40:32 +01:00
Ted John 2fdf91874c Implement centred labels 2021-01-29 17:50:32 +00:00
Ted John 180a41686c Implement transparent windows for plugins 2021-01-29 17:50:27 +00:00
Ted John 2fcaed8165 Allow more fields to be optional 2021-01-27 00:28:59 +00:00
Ted John c0d8786af8 Add text box widget 2021-01-27 00:28:59 +00:00
Ted John be350f7e2e Add widget visible flag 2021-01-26 00:25:59 +00:00
skdltmxn 7ef4d7762f Refactor to avoid unnecessary copies (#13736)
* Refactor to avoid unnecessary copies

* Fix dangling references
2021-01-11 18:14:15 -03:00
skdltmxn c093a50f3f Refactor to use string_view more properly 2021-01-07 01:52:10 +09:00
Ted John 030713e126 Fix #13078: [Plugin] Add colour picker widget 2020-12-05 18:26:35 +00:00
Ted John a55bcff99c Fix #13431: [Plugin] UI disabled widgets can still be interacted with. 2020-12-05 18:26:35 +00:00
Ted John b6a688e540 Refactor format tokens 2020-11-27 18:54:57 +00:00
ffrogman 7ed1804e61 Fix #12410: Refactor WINDOW_WIDGET_TYPES to use strong enum (#13453)
* Fix #12410: Refactor WINDOW_WIDGET_TYPES to use strong enum
2020-11-27 00:14:20 -03:00
Sadret 2f4b1b9e3f Close #13376: Open custom window at specified tab 2020-11-05 17:43:23 +01:00
pizza2004 2015acd4c0 Refactor UI/Interface Window to Title Case (#13367) 2020-11-04 04:52:23 +00:00
pizza2004 a5607da09d Refactor Widget to TitleCase (#13355) 2020-11-03 18:29:22 -03:00
pizza2004 68bd035f12 Refactor Dropdown to TitleCase (#13352)
* Refactor Dropdown Namespace

* Refactor Dropdown to TitleCase
2020-11-03 08:16:06 +00:00
Sadret 5893664785 Fix #13334: Uninitialised variables in CustomTabDesc 2020-11-01 20:59:19 +01:00
Aaron van Geffen d27e14f45b Compact, statically initialized syntax for event lists (#12973) 2020-09-28 20:36:15 +02:00
Sadret a9cd89d02e Fix #12912: Plugin: selectedCell of CustomListView (#12913) 2020-09-12 19:24:23 -03:00
Michael Steenbeek 1cf89362f0 Merge pull request #12184 from IntelOrca/sea
Add support for reading .sea (RCT classic) files
2020-07-13 17:23:16 +02:00