Commit graph

2 commits

Author SHA1 Message Date
Vigers Ray
dbfa90e956 Звуковое оповещение новых ролей для призраков и вынос правил в отдельную кнопку. 2024-11-29 04:35:28 +03:00
MilenVolf
cc3a19c212
Collapsible ghost roles menu (#32717)
* Make ghost roles collapsible

* Save `BodyVisible` state of each `Collapsible` box

* Make ghost role collapsible only when group has more than 1 role

* Make it a little prettier

* Make only ghost role buttons collapsible

* Apply requested changes

* Typo

* Small cleanup

* Store in list, instead of iterating

* Make unique ids more unique

* Move it out of the cycle

* Make _collapsibleBoxes into dictionary and use key instead of Collapsible boxes names

Added TODO. So after the problem will be fixed in `GhostRolesEui`, it should be mirrored and fixed here too.

* Put TODO in GhostRolesEui. I guess Issue must be made for this

* Use HashSet instead of Dictionary as suggested. Invert the HashSet, so being present means it uncollapsed

I decided to invert HashSet to _uncollapsedStates, because players surely will have more collapsed buttons than opened, so we optimise memory usage a little bit.

* Remove extra space from ghost roles window

* Add buttons stretching. Size 3:1
2024-11-04 01:49:42 +01:00
Renamed from Content.Client/UserInterface/Systems/Ghost/Controls/Roles/GhostRolesEntry.xaml.cs (Browse further)