Commit Graph
203 Commits
Author SHA1 Message Date
Ted John be350f7e2e Add widget visible flag 2021-01-26 00:25:59 +00:00
amdoku 85efe047bb Close #12444: Refactor TILE_INSPECTOR_PAGE to use strong enum (#13134) 2021-01-03 10:30:59 -03:00
Tulio Leao 221aa8cece Close #12453: Refactor RCT2_EDITOR_STEP to strong enum 2020-12-23 20:07:53 -03:00
Adamandduncanspumpkin f09b14ef2b Split actions hpp files into separate h and cpp files (#13548)
* Split up SmallSceneryPlace/Remove

Added undo function for Remove Scenery

* Refactor: Balloon and Banner actions hpp=>h/cpp

* Refactor: rename all action *.hpp files to *.cpp

This is preparation for separation in later commits. Note that without
the complete set of commits in this branch, the code will not build.

* Refactor Clear, Climate, Custom, and Footpath actions hpp=>h/cpp

* VSCode: add src subdirectories to includePath

* Refactor Guest actions hpp=>h/cpp

* Refactor Land actions hpp=>h/cpp

* Refactor LargeScenery actions hpp=>h/cpp

* Refactor Load, Maze, Network actions hpp=>h/cpp

* Refactor Park actions hpp=>h/cpp

* Refactor/style: move private function declarations in actions *.h

Previous action .h files included private function declarations with
private member variables, before public function declarations. This
commit re-orders the header files to the following order:
- public member variables
- private member variables
- public functions
- private functions

* Refactor Pause action hpp=>h/cpp

* Refactor Peep, Place, Player actions hpp=>h/cpp

* Refactor Ride actions hpp=>h/cpp

* Refactor Scenario, Set*, Sign* actions hpp=>h/cpp

* Refactor SmallScenerySetColourAction hpp=>h/cpp

* Refactor Staff actions hpp=>h/cpp

* Refactor Surface, Tile, Track* actions hpp=>h/cpp

* Refactor Wall and Water actions hpp=>h/cpp

* Fix various includes and other compile errors

Update includes for tests.
Move static function declarations to .h files
Add explicit includes to various files that were previously implicit
(the required header was a nested include in an action hpp file, and the
action .h file does not include that header)
Move RideSetStatus string enum to the cpp file to avoid unused imports

* Xcode: modify project file for actions refactor

* Cleanup whitespace and end-of-file newlines

Co-authored-by: duncanspumpkin <duncans_pumpkin@hotmail.co.uk>
2020-12-10 06:39:10 +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
Hielke MorsinkandMichael Steenbeek f0c1ea1d37 Split declarations and definitions to improve compile times when editing (#13332)
* Split FileStream declarations and definitions

* Split JobPool declarations and definitions

* Split StringBuilder declarations and definitions

* Split StringReader declarations and definitions

* Split ZoomLevel declarations and definitions

* Fix missing include in FileClassifier.cpp

* Remove pragma once from source files

* Fix missing include in StringBuilder.h

* Update Xcode project

* Fix compilation of tests

Co-authored-by: Michael Steenbeek <m.o.steenbeek@gmail.com>
2020-11-07 12:42:04 +00:00
pizza2004 2015acd4c0 Refactor UI/Interface Window to Title Case (#13367) 2020-11-04 04:52:23 +00:00
Łukasz PękalskiandTulio Leao 88a6a085e4 Close #12455: Refactor MOUSE_STATE to use strong enum (#13361)
* Close #12455: Refactor MOUSE_STATE to use strong enum

refactor: MouseState to strong enum

Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2020-11-03 18:41:19 -03:00
pizza2004 a5607da09d Refactor Widget to TitleCase (#13355) 2020-11-03 18:29:22 -03:00
pizza2004 b0fd5f93d7 Refactor UI/Interface misc to TitleCase (#13354)
* Refactor LandTool to Namespace

* Refactor Theme to TitleCase

* Refactor ViewportInteraction to TitleCase
2020-11-03 10:59:00 +00:00
pizza2004 68bd035f12 Refactor Dropdown to TitleCase (#13352)
* Refactor Dropdown Namespace

* Refactor Dropdown to TitleCase
2020-11-03 08:16:06 +00:00
pizza2004 1643c62939 Refactor UI/Input MouseInput to Title Case 2020-11-02 07:05:33 -07:00
pizza2004 34f362b86e Refactor UI/Input KeyboardShortcuts to Title Case 2020-11-02 06:55:16 -07:00
pizza2004 06c0c1b982 Refactor UI/Input Input to Title Case 2020-11-02 06:55:16 -07:00
DuncanandTulio Leao cd39c30989 Tooltip 2 (#13159)
* Use ScreenCoords for tooltip

* Remove temporary variables

* Small refactor

* Fix #13151. Not passing tooltip arguments correctly for ride window

* Fix Server List window version tooltip

* Fix cheats tooltip event

* Add static to function decl

* Remove unreachable break statements in Ride.cpp

* Apply review suggestions

Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2020-10-17 09:10:08 +01:00
Julia Pinheiro cba1d48226 Close #12408: Refactor CURSOR_ID to use strong enum 2020-10-11 18:01:14 +02:00
Duncan f28907a87d Rework tooltip to be more logical (#13137) 2020-10-10 10:49:56 -03:00
Duncan 197bb897bb Fix #7748. Move tooltip timeout reset to correct location (#13132)
* Fix #7748. Move tooltip timeout reset to correct location

Mistake made in implementation

* Add changelog entry
2020-10-09 16:53:31 +01:00
ζeh Matt 61b510db66 Merge pull request #13073 from ZehMatt/refactor/audio-cleanup
Minor cleanup around audio code
2020-10-07 21:18:59 +03:00
Tulio Leao 076544f490 Merge pull request #13084 from vjavs/PVS-Studio/Fixes
Make some PVS-Studio fixes
2020-10-07 08:24:59 -03:00
Mike Jones 7441001c4e Close #12407: Refactor CHAT_INPUT to use strong enum (#13116) 2020-10-06 21:37:08 -03:00
Matt 091145037e Move the audio code into OpenRCT2 namespace 2020-10-07 00:34:42 +03:00
Vinicius Sa 579e008590 Refactor process_mouse_over()
- Remove unnecessary local variables and assignments

 - Remove unreached if-statement branch

Reported by PVS-Studio (Warning: V587).

Fix 5/7.

Issue: 12523
2020-10-06 18:21:24 -03:00
Bryan DiLaura 56e8cc77c6 Close #12409: Refactor CONSOLE_INPUT to use strong enum (#13052) 2020-10-01 10:31:03 +01:00
Duncan 3c8adb1fc1 Remove gMapTooltip format args global (#12971)
Fix mistake
2020-09-28 21:45:28 -03:00
Matt d0d5cc5179 Remove unused declarations 2020-09-16 20:23:34 +03:00
Łukasz Pękalski 411f242cfd Close #12431 Refactor VirtualFloorStyles to use strong enum (#12790) 2020-08-27 21:06:39 -03:00
Tulio Leao 4caf571c22 Followup on #12475 post-mortem comments (#12745)
* Remove using namespace OpenRCT2 from header

* Fix using wronf undefined enum for shortcut key map
2020-08-21 16:07:38 +01:00
frutiemaxandTulio Leao 4cc550a364 Close #12460: Refactor KeyboardShortcut to use strong enum (#12475)
* Close #12460: Refactor KeyboardShortcut to use strong enum

Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2020-08-20 23:54:43 -03:00
Matt 0dc43d66e4 Remove the use of INTERFACE macro and macro its self 2020-08-05 16:30:44 +02:00
Matt 30376085cf Include missing headers 2020-08-05 16:29:29 +02:00
frutiemax af0fc89cf4 Close #12456: Refactor INPUT_STATE to use strong enum (#12484) 2020-07-27 19:51:10 -03:00
Michał Janiszewski f1fa016400 Reset window pointer when cleaning up after dropdown 2020-07-26 10:09:56 +02:00
Aaron van Geffen 7b5087f057 Update copyright year to 2020 2020-07-21 15:04:34 +02:00
Tulio Leao 0951c0c5cc Remove goto from input_state_widget_pressed (#12265) 2020-07-15 07:50:01 -03:00
frutiemax 27734e2971 Part of #12160: Use Coords for viewport_coord_to_map_coord (#12216) 2020-07-12 18:42:54 -03:00
Thamara Andrade 8ce799a72e Close #12118: Prefer foward declaration of *Coords* in headers (#12142)
* Removing unnecessary world/Location includes in headers
* Prefer foward declaration of *Coords* in header files
Closes #12118
2020-07-06 10:10:39 -03:00
Aaron van Geffen 2e153a7e95 Introduce widget::midX and widget::midY helper functions 2020-06-25 10:31:15 +02:00
Aaron van Geffen 681b8d7938 Introduce widget::width and widget::height helper functions (#12053) 2020-06-24 22:44:00 -03:00
Michiel 03b2456bc7 Fixed clearance checks hotkey (#11833) 2020-05-30 23:42:42 +02:00
Michael SteenbeekandAaron van Geffen 6d13f7ba68 Apply suggestions from code review
Co-authored-by: Aaron van Geffen <aaron@aaronweb.net>
2020-05-30 17:10:08 +02:00
Michiel Bos 67ffc5642b Fixed the include order in KeyboardShortcut.cpp to match with clang. 2020-05-30 17:10:08 +02:00
Michiel Bos 670b879235 Added a shortcut key for disabling/enabling clearance checks. 2020-05-30 17:10:08 +02:00
Breno Rodrigues Guimarães 374b744477 Use Formatter to handle argument formatting for tooltips (#11379) 2020-04-21 12:38:59 +02:00
Aaron van Geffen d1a314b0f7 Decouple shortcut window order from internal order. 2020-04-17 18:35:06 +02:00
Aaron van Geffen 28d14517e1 Introduce a constant for scrollbar width and height (#11152) 2020-03-30 22:41:49 +02:00
Tulio Leao 8823658972 Use named casts on openrct2-ui/input 2020-03-28 17:04:29 -03:00
Ted John d34dec9c27 Create ZoomLevel struct to add two new zoom levels 2020-03-23 15:54:03 +00:00
Gymnasiast 5f96a121ae Apply ScreenCoordsXY to some functions 2020-03-07 22:25:42 +01:00
Tulio Leao 724a6d4dcf Make rct_window use ScreenCoordsXY 2020-03-02 20:51:01 -03:00