Commit Graph

118 Commits

Author SHA1 Message Date
TomasZilinek cd6076b5bc
FIx #12017 - Create gfx_draw_sprite overload (#12049)
Second and final part. replaces the rest of the calls and removes the old function.
2020-06-24 12:48:17 -03:00
frutiemax 6e47385b90
Part of #11389 : in peep class, FormatTo* use Formatter class (#12035) 2020-06-23 14:52:08 +01:00
TomasZilinek 2264c5f7f1
Part of #11571 - Use gfx_draw_string_left with ScreenCoordsXY (#12008) 2020-06-20 11:56:36 -03:00
duncanspumpkin 6ed17b4ff9 Remove FOR_ALL_PEEPS/GUESTS/STAFF macros
Replaced with an EntityList iterator

Fix formatting

Fix nullptr issues
2020-06-16 20:27:44 +01:00
Tulio Leao ce171164c9
Merge pull request #11932 from tupaschoal/draw_string_right-11569
Use ScreenCoordsXY for gfx_draw_string_right
2020-06-14 12:11:10 -03:00
Tulio Leao e54a3d89f2
Rename some Peep member variables to use TitleCase (#11931)
* Rename Peep::destination_tolerance to use TitleCase

* Rename Peep::destination_y to use TitleCase

* Rename Peep::destination_x to use TitleCase

* Rename Peep::trousers_colour to use Title Case

* Rename Peep::tshirt_colour to use TitleCase

* Rename Peep::no_of_rides to use Title Case

* Rename Peep::staff_type to use TitleCase

* Rename Peep::type to use TitleCase

* Rename Peep::sprite_type to use TitleCase

* Rename Peep::sub_state to use TitleCase

* Rename Peep::state to use TitleCase

* Rename Peep::outside_of_park to use TitleCase

* Rename Peep::next_flags to use TitleCase

* Rename Peep::name to use TitleCase

* Rename Peep::NoOfRides to GuestNoOfRides

* Rename Peep::Type to AssignedPeepType

* Rename Peep::GuestNoOfRides to GuestNumRides
2020-06-14 06:31:08 +01:00
Tulio Leao fab0ea131f Part of #11569: Use gfx_draw_string_right with ScreenCoordsXY 2020-06-11 10:11:20 -03:00
Tulio Leao e08c1b44b2 Rename Peep::thoughts to Thoughts 2020-06-06 10:03:58 -03:00
Michael Steenbeek 4efd3dbfbf
Merge pull request #11866 from Gymnasiast/refactor/set_format_arg_be_gone
Move calls to set_format_arg to Formatter::Common()
2020-06-04 23:20:37 +02:00
Tulio Leao a2a0fad886
Rename Peep::peep_flags to PeepFlags 2020-06-04 19:16:11 +02:00
Gymnasiast 02338ffc5c
Migrate 50 more calls to set_format_arg() 2020-06-03 14:49:04 +02:00
Gymnasiast f640446d58
Migrate 40 calls to set_format_arg() 2020-06-03 14:49:04 +02:00
TusharSariya 2cf95adc4b
Fix #11565: gfx_draw_string_left_clipped to use ScreenCoordsXY (#11765)
* Issue #11565, created overload for gfx_draw_string_left_clipped

Co-authored-by: Tushar <tushar.97@hotmail.com>
Co-authored-by: Tulio Leao <tupaschoal@gmail.com>
2020-05-17 19:30:58 -03:00
Michael Steenbeek f0bd05cf6d
Part of #11158: Remove more C-style casts (#11743) 2020-05-13 21:22:50 -03:00
Gymnasiast f8aeb70398
Apply review requests 2020-05-09 18:07:16 +02:00
Gymnasiast 43556d2dec
Remove ifdefs for LEFT_CLOSEBOX - for now 2020-05-09 18:07:16 +02:00
Gymnasiast 9e4c664944
Replace defines with constexpr 2020-05-09 18:07:16 +02:00
Gymnasiast 96fe3d3b3c
Make WINDOW_SKELETON take a title, height and width 2020-05-09 18:07:16 +02:00
tassaron2 559ede5d14
Add compile option to move close box to the left 2020-05-09 18:07:16 +02:00
Tulio Leao 4933785b1c Make window_dropdown_show_text_custom_width() use ScreenCoordsXY 2020-05-01 15:48:20 -03:00
Breno Rodrigues Guimarães 2479256bc1
Adjust Formatter function names according to coding style (#11378) 2020-04-20 18:55:15 -03:00
Breno Rodrigues Guimarães d4a2a98e20
Replacing set_format_arg_on macro in favor of a more C++zy solution (#11350) 2020-04-20 07:10:33 +02:00
Tulio Leao 935cfe90fc
Use named casts on openrct2-ui/windows (#11136) 2020-04-18 13:32:48 +02:00
Gymnasiast edd31d9f16
Move flags to RideTypeDescriptors 2020-04-17 17:03:33 +02:00
Duncan 8920c36170
Fix #11107. Guestlist refresh issues after refactor (#11108)
Another little oversite on the guestlist preventing full functionality of the guestlist. Also fixed the map flashing
2020-03-28 16:21:01 +00:00
Duncan a33fbfa234
Fix guest list when in filtered mode. (#11102)
Mistake during refactor didn't consider that find_groups resets global vars.
2020-03-28 11:02:26 +01:00
Michael Steenbeek 81c6bb26e9
Prepare guest counters for more than 32767 guests (#10989) 2020-03-26 20:02:15 +01:00
Duncan 40160892a9
Rework GuestList to use a vector. (#11014)
* Rework GuestList to use a vector.

This is part of a chain of refactors that will be used to rework peep order in the sprite list

* Apply comments. Remove setting var_492 as no longer required
2020-03-26 07:23:30 +00:00
Gymnasiast a0e14a66d9
Prepare guest window for more than 5 pages 2020-03-09 11:54:49 +01:00
Tulio Leao 724a6d4dcf Make rct_window use ScreenCoordsXY 2020-03-02 20:51:01 -03:00
Tulio Leao 9bcd20e0e6 Prefer const ref to send ScreenCoordsXY over 2020-02-29 08:25:48 -03:00
duncanspumpkin 272e4f29a3 Further minor refactors 2020-01-19 17:16:42 +00:00
Tulio Leao fe3d6f6faf Use ScreenCoordsXY for scroll_mouse* functions 2019-11-14 08:40:40 -03:00
Matt cc6321048f
Refactor window_invalidate to use rct_window::Invalidate 2019-08-11 17:22:00 +02:00
Ted John 40d49b93d3 Do not use user strings for peep names 2019-07-29 19:18:16 +01:00
Ted John f8b08b334e Fix a few more bugs 2019-07-29 19:18:16 +01:00
Ted John 3f45976009 Fix openrct2ui errors 2019-07-29 19:18:16 +01:00
Ted John 3155c661fa Refactor format peep action 2019-07-29 19:18:16 +01:00
Aaron van Geffen 2af13904c5 Update copyright notices for 2019. (#8903) 2019-03-17 07:16:15 +00:00
Ted John cdec457abd Refactor peep struct 2019-02-28 20:28:58 +01:00
Tom Lankhorst ddf4c32644 Fix #8588: Guest list scrolling breaks above ~2000 guests 2019-01-20 11:55:29 +01:00
ζeh Matt 7d19a5bc77 Refactor memcpy to std::memcpy and memset to std::memset (#8408) 2018-12-15 22:23:31 +01:00
Gymnasiast 45b8ca9421 Remove more strings, fix error 2018-08-12 15:56:47 +02:00
clang-format b02dfdbc93 Binpack function arguments together
Previously when the arguments of a function wouldn't fit on a single line, clang-format would put each argument on its own line instead. By enabling the binpack parameter setting, it tried to fit as many on one line as possible instead.

Co-authored-by: Hielke Morsink <hielke.morsink@gmail.com>
2018-07-23 16:00:22 +02:00
clang-format 95ce592579 Enforce not breaking before assignments and function names
Co-authored-by: Hielke Morsink <hielke.morsink@gmail.com>
2018-07-23 16:00:19 +02:00
clang-format e558660860 clang-format UI windows 2018-07-23 16:00:14 +02:00
Michael Steenbeek 1b08fb4e69 Replace our own integer types with standard ones 2018-06-20 17:30:40 +02:00
Hielke Morsink 0cf256ac9e Ready copyright notice for clang-format
Clang-format sees the text behind `#pragma region` as code and formats it. Instead of stating the copyright and date there, it's now in the comment block right below it. The text "Copyright" is left in the `#pragma region` line, as clang-format sees it as a single identifier.

I took the opportunity to normalize the dates, and add the copyright notice to the source files where it was missing them (except for third-party and the generated resources.h file).
2018-06-15 14:07:34 +02:00
Michał Janiszewski a2ef4bd699
Exclude pre-formatted blocks from clang-format (#7520)
[ci skip]
2018-05-16 20:41:29 +02:00
duncanspumpkin 765500adfa Label offsets and functions
Actually save before commiting

Label more peep vars.

Remove unread var

Further refactoring

Fix mistake in map element type
2018-04-11 18:16:09 +01:00
Michał Janiszewski cd065d4f41 Reduce includes in common header 2018-03-20 00:27:58 +01:00
Michał Janiszewski 4dd0995efb Move cmath out of common.h 2018-03-18 23:29:13 +01:00
Michał Janiszewski 10dabfa15c Fix strncpy usage in GuestList.cpp 2018-03-14 22:11:01 +01:00
Marijn van der Werf 4c956def67 Update UI imports 2018-01-18 22:57:55 +01:00
ZehMatt 84f2917f59 Use const and constexpr whenever possible. 2018-01-11 22:29:08 +01:00
Aaron van Geffen ecc1cfed2a Rename WWT_DROPDOWN_BUTTON to WWT_BUTTON.
The previous name implied an exclusive association with dropdowns.
While used to display the dropdown triangle button, this is not an
exclusive use.
2018-01-08 00:01:32 +01:00
Ted John 83d1b6eb8f Refactor widget.c to C++ 2018-01-07 12:39:58 +01:00
Michael Steenbeek 755add6c9a
Compile localisation folder as C++ 2018-01-06 18:32:25 +01:00
Aaron van Geffen 759c51bbad Fix #6869: incorrect Map button appearance in Guest List.
* Fixes the map button overlapping with the new search icon.

* Fixes the map button not being repositioned when the window is resized.
2017-12-27 14:51:17 +01:00
Park Joon-Kyu bbf5571c17 Allow filtering guests by name (#6633) 2017-12-25 12:17:37 +01:00
Marijn van der Werf 1e946fc0fe Move Dropdown to UI project 2017-12-16 15:47:38 +02:00
Michael Steenbeek 60d8865efb Compile game.c and game.h as C++ 2017-12-05 09:10:27 +01:00
Ted John 323b8dd352 Partially fix #6129: Guest List not updating after a ride rename
- Force refresh of ride list and guest list for both rename ride and demolish ride actions.
2017-11-23 09:40:39 +01:00
Cody Jung 3bb9d41908 Fix #6657: Reset tracking icon status when opening guest list
The guest tracking icon is hidden on the guest list if it's in
PAGE_SUMMARISED mode. Closing then reopening the window reset it back to
INDIVIDUAL mode but did not restore the icon state.
2017-11-13 10:36:16 +01:00
Aaron van Geffen cbb178743f Add extra padding to scrollable list items in guest window. 2017-10-22 22:00:49 +02:00
Marijn van der Werf 8569a7fe2f Move map window 2017-10-07 22:24:14 +02:00
Marijn van der Werf 257c9d60d5 Fix imports 2017-09-24 22:41:49 +02:00
Marijn van der Werf 9b1b2b5c62 WIP window moving 2017-09-24 22:41:49 +02:00
Renamed from src/openrct2/windows/GuestList.cpp (Browse further)