Commit Graph

50 Commits

Author SHA1 Message Date
Brandon Li
545cacbcae StyleNano removal: Palette system and Sheetlets (#29903)
* Apply patch 1777eea9a4..6b32bb2b14

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* make red squiggly line go away

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Add todo list

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Add palette to `TextureButton`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Rename `PalettedButtonSheetlet` to `NTButtonSheetlet` and move useful methods to `ButtonSheetlet`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* migrate `ContextMenu` styles

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Update todo

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* tweak NT colors

* New stylesheet: `InterfaceStylesheet` & `InterfaceTooltipSheetlet`

* Move inheritance of `IButtonConfig` to `NanotransenStylesheet.Buttons`

* move `MenuButtonSheetlet` & actually implement `InterfaceStylesheet` correctly

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* tweak color & update todo

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* chat is this real (update chat palette)

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Update todo

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* `SmallButton` and remove some obsolete things from `StyleNano`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* rename `StyleClasses` to `StyleClass` so `Stylesheets.Redux.StyleClasses` syntax is dead

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* replace `ButtonColorGreen` with `Positive`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* `Placeholder`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Examine popup buttons

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* move over more things & cleanup `StyleNano` more (under 1000 lines!!!!)

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Remove some more redundant stuff

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Undo style change for chat window

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* paper editing works now

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* `OptionButton` styles

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* `ListContainer`, move `DefaultWindow` styles (for now) & more cleanup

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* fix `ActionButton` not having highlighting

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* remove imports of `Robust.Client.UserInterface.StylesheetHelpers` & format

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* `ButtonBig` and more cleanup

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Move items inheriting from `ISheetletConfig` into their own directory

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Cleanup & move `Label` styles

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Action search box styles

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Moved, stuff is

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* rename `LabelSubtext` to `LabelSubText` & move more stuff (were almost there!!)

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* yap & move over MORE stuff (just like one thing left!!!)

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Change status classes to appropriate existing classes

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* remove remaining references to `StyleNano`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Fix some hardcoding & broken code, `GetFromControl`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Scrollbars!

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* chores

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* clean up `StyleClass.cs`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* `ItemListSheetlet` refactor

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* more chores!

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Consistency w/ directory structure

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Move `MainMenuSheetlet`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* `ColorPalette`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* whoopsie

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Remove most sheet-specific sheetlets

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* fix warnings, cleanup, & fix scrollbar (this is why we fix warnings boys)

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* yap

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* MASSIVE resharper skill issue

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* actually use `ISheetletConfig`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* have specific sheetlet be specific

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* `GetResourceOr`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* cleanup & move / remove `IPalette`s

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* actually do specific stylesheets correctly & fix tooltips

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* cleanup & logging

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* Move `FontKind` and `FontKindExtensions` to their own files

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* rename `InterfaceStylesheet` to `SystemStylesheet`

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* change `ButtonHovered` etc to `PseudoHovered` etc

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* give the palettes fun names

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* `StyleSpace` is no more

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* It should compile now! I am now going to bed (fr) if it fails it fails

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* make squiggly red line go away

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>

* add additional type restrictions to sheetlets

* `CommonStylesheet`

* minor cleanup

* Make `GetSheetletRules` not horrible

* wait this was duplicating style rules. oops!

* move some sheetlets to their associated xamls

* oh wait apparently that was important

* review pass 1

* review pass 2 (font & color stuff)

* review pass 3: remove unused stuff / filename fix

* fix warnings & "replace cast with explicit variable type"

* move `Palette` stuff to its own directory

* tweak colors (they're different now that I actually fixed the OKlab thing)

* review pass 4: little things

* make window close button grey before hovering

* refactor `HLine` to make it less terrible and allow it to be styled

* fix `NanoHeading` (it's been broken for a while whoops) and cleanup hardcoding

* band-aid missing references in `StyleNano`

* move `StyleBox` generating functions out of `IButtonSheetlet` into `StyleBoxHelper`

* remove dictionary field from `IStylesheetManager`

* Add check for unloaded sheetlets

* style tweaks to satisfy OCD

* I somehow missed this: `Caution` styleclass replaced with `negative`, refactor `PowerChargeWindow`

* tweak palettes for like the fourth time

* construct `StyleNano` / `StyleSpace` in `StylesheetManager` and mark them as obsolete

* rename `BackgroundPanel` classes for consistency

* tweak window / `ListContainer`

* oh right you use `///` not `/**`

* font system is bad, make it temporary

* acknowledge Divider funkyness

* remove use of class `Disabled`

* `ColorPalette` allow overriding colors with brace initialization

* review pass again

* tweak disabled button colors

* `StatusPalette` tweaks

* typo

* Make squiggly red line go away

* Delete `Redux`

* Remove all references to `Redux`

* make red less radioactive

* Store stylesheet name inside stylesheet class

* fix merge errors

* use RT's Oklab support instead

* shuffle around `StylesheetManager` fields

* apply stylesheets based off `StylesheetComponent`

* simplify `ColorPalette` construction

* add todo for `SheetletConfigType`

* `OptionButton` has a background color now

* fix disabled buttons

* sigh (red color palette fixed)

* make `ItemList` use primary palette

* Revert "apply stylesheets based off `StylesheetComponent`"

This reverts commit c05b147da845f6e04ff33d1cbd91a18a92c676d7.

* dead code removal

* buttons are green when pressed (we need togglebuttons)

---------

Signed-off-by: Brandon Li <sirbrandonthenerd@gmail.com>
Co-authored-by: Janet Blackquill <uhhadd@gmail.com>
2025-10-19 21:10:44 +00:00
Absotively
a5129c141c Don't overwrite values that are mid-edit in air alarm window (#40338) 2025-09-20 11:55:34 -07:00
Ser11y
d7f8614c35 localization support to air alarms, wire panels and more (#39307)
* Add localization to the air alarms, wire panels, network configurator list menu and loadout window

* delete unused

* redo gas localization, delete unused

* removed the extra key

* Moved and renamed air-alarm-ui-thresholds-gas-name

* Moved localization to the XAML

* Use existing strings for gas names

* it just works

* Rename _atmosphereSystem in ScrubberControl.xaml.cs

_atmosphereSystem -> atmosphereSystem

* Rename _atmosphereSystem in SensorInfo.xaml.cs

_atmosphereSystem -> atmosphereSystem
2025-08-05 17:13:04 +02:00
qwerltaz
2c933c8de7 add: air alarm scrubber select all gases button (#39296)
* add select all gases button

* now make it work

* localize

* refactor

* remove redundant Orientation

Co-authored-by: Perry Fraser <perryprog@users.noreply.github.com>

* remove useless HorizontalExpand

Co-authored-by: Perry Fraser <perryprog@users.noreply.github.com>

* add nice newline

Co-authored-by: Perry Fraser <perryprog@users.noreply.github.com>

* deduplicate Enum.GetValues<Gas> usage

---------

Co-authored-by: Perry Fraser <perryprog@users.noreply.github.com>
2025-08-04 17:34:10 -07:00
rlebell33
23c190e9bc Dehardcoded Air Alarm's UI window title (#39072)
Extract the air alarm title to no longer be hardcoded
2025-07-19 15:21:50 -04:00
qwerltaz
b374d2468a air alarm panic wire snipping forces panic mode (#36439)
* air alarm panic wire snipping forces panic mode

* document

* ForcedMode is datafield

* switch to bool flag

* lock button when panic wire cut

* prevent manually individually changing scrubbers from siphon when panic wire is cut

* failure alert when wire snipped

* is Control

* remove double horizontalExpand

* Update Content.Server/Atmos/Monitor/Systems/AirAlarmSystem.cs

* Update Content.Server/Atmos/Monitor/Systems/AirAlarmSystem.cs

---------

Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
2025-05-14 22:39:47 +02:00
Tayrtahn
e4d7f164f6 Localize air alarm states (#36266) 2025-04-02 19:38:26 -07:00
Southbridge
edbc861c78 Add copy threshold button to air alarms (#34346) 2025-01-09 22:55:05 -08:00
MilenVolf
6c86d7b32b Cleanup some Client atmos systems (#33634)
* Cleanup `ScrubberControl.xaml.cs`

* Minor cleanups

* Another pile of minor cleanups

* Apply requested changes

* Rename "which" into "bound". Add whitespace after "if"
2024-11-30 02:33:29 +01:00
eoineoineoin
b0375f115c Remove client state from server AirAlarmComponent (#31236)
* Remove client state from server AirAlarmComponent

Send information for all connected devices, not just the ones for the
current tab, as attempting to limit this breaks multiple users viewing
the same UI.

Fixes #12842

* Send device data as a list, rather than a dictionary

---------

Co-authored-by: Eoin Mcloughlin <helloworld@eoinrul.es>
2024-08-25 12:01:46 +10:00
metalgearsloth
edb05e36bb Reapply "Remove some BUI boilerplate" (#30214) (#30219)
* Reapply "Remove some BUI boilerplate" (#30214)

This reverts commit cb0ba66be3.

* Fix gas tank

* Fix PA

* Fix microwave

* Comms console underwrap

* Fix rcd

* log wehs
2024-07-21 14:48:13 +10:00
Nemanja
cb0ba66be3 Revert "Remove some BUI boilerplate" (#30214)
Revert "Remove some BUI boilerplate (#28399)"

This reverts commit cbf329a82d.
2024-07-20 20:42:27 -04:00
metalgearsloth
cbf329a82d Remove some BUI boilerplate (#28399)
* Remove some BUI boilerplate

- The disposals overrides got removed due to the helper method handling it.
- Replace window creation with CreateWindow helper.
- Fixed some stinky code which would cause exceptions.

* More

* moar

* weh

* done

* More BUIs

* More updates

* weh

* moar

* look who it is

* weh

* merge

* weh

* fixes
2024-07-20 15:40:16 +10:00
metalgearsloth
c5486873db Shuttle console + FTL rework (#24430)
* Add shuttle interior drawing back

Just do it per-tile she'll be right, at least it's done with 1 draw call.

* Revamp shuttle console

* Bunch of cleanup work

* Lables sortito

* dok

* Pixel alignment and colours

* Fix a bunch of drawing bugs

* Shuttle map drawing

* Drawing fixes

* Map parallax working finally

* weh

* Commit all my stuff

* mic

* deez

* Update everything

* Xamlify everything

* uh

* Rudimentary blocker range

* My enemies have succeeded

* Bunch of changes to FTL

* Heaps of cleanup

* Fix FTL bugs

* FTL

* weewoo

* FTL fallback

* wew

* weh

* Basic FTL working

* FTL working

* FTL destination fixes

* a

* Exclusion zones

* Fix drawing / FTL

* Beacons working

* Coordinates drawing

* Fix unknown map names

* Dorks beginning

* State + docking cleanup start

* Basic dock drawing

* Bunch of drawing fixes

* Batching / color fixes

* Cleanup and beacons support

* weh

* weh

* Begin pings

* First draft at map objects

* Map fixup

* Faster drawing

* Fix perf + FTL

* Cached drawing

* Fix drawing

* Best I got

* strips

* Back to lists but with caching

* Final optimisation

* Fix dock bounds

* Docking work

* stinker

* kobolds

* Btns

* Docking vis working

* Fix docking pre-vis

* canasses

* Helldivers 2

* a

* Array life

* Fix

* Fix TODOs

* liltenhead feature club

* dorking

* Merge artifacts

* Last-minute touchup
2024-03-03 18:39:19 +11:00
Pieter-Jan Briers
68ce53ae17 Random spontaneous cleanup PR (#25131)
* Use new Subs.CVar helper

Removes manual config OnValueChanged calls, removes need to remember to manually unsubscribe.

This both reduces boilerplate and fixes many issues where subscriptions weren't removed on entity system shutdown.

* Fix a bunch of warnings

* More warning fixes

* Use new DateTime serializer to get rid of ISerializationHooks in changelog code.

* Get rid of some more ISerializationHooks for enums

* And a little more

* Apply suggestions from code review

Co-authored-by: 0x6273 <0x40@keemail.me>

---------

Co-authored-by: 0x6273 <0x40@keemail.me>
2024-02-13 16:48:39 -05:00
metalgearsloth
d5bd1c6f86 Predict StorageComponent (#19682) 2023-09-11 21:20:46 +10:00
Ilya246
d3244b6049 copy-settings-to-all-similar for scrubbers and vents in air alarms (#18363) 2023-08-09 14:20:19 -04:00
c4llv07e
6e66866567 Add 'auto mode' button to the air alarm ui (#17874)
Signed-off-by: c4llv07e <kseandi@gmail.com>
2023-07-09 13:22:41 -06:00
TemporalOroboros
3ac4cf85db Cleaner BoundUserInterfaces (#17736) 2023-07-09 02:02:17 +10:00
Leon Friedrich
49a22ed29d Set SpriteView sizes in various controls. (#15935) 2023-04-30 16:46:45 +10:00
Visne
c6d3e4f3bd Fix warnings and code cleanup/fixes (#13570) 2023-01-19 13:56:45 +11:00
Kara
9c844c8aed Relax water vapor threshold (#13280) 2023-01-01 21:05:37 -08:00
eoineoineoin
ff9cf108b6 UX improvements to Air Alarm UI (#12681)
Co-authored-by: Eoin Mcloughlin <helloworld@eoinrul.es>
2022-12-06 15:46:07 -08:00
eoineoineoin
8f641137e8 Fix bug where AirAlarmUI would display incorrect scrubber filters (#12846)
Co-authored-by: Eoin Mcloughlin <helloworld@eoinrul.es>
2022-12-06 15:33:21 -08:00
Flipp Syder
0882d85176 Air alarm balancing (#11063)
* threshold balancing, restores none mode on atmos alarm

dear lord, panic mode with unbalanced thresholds was a nightmare

* that was 10%, not 1%

* adds widenet mode for scrubbers

* adds the vents to wide filter as well
2022-09-05 19:35:36 -07:00
corentt
6301ac5147 AirAlarms fixes (#11062)
* modify airalarm thresholds

* display percentage, not ratio

* reopen doors on normal/warning state

* panic mode on danger state
2022-09-05 19:54:26 -05:00
vulppine
e0bf77490d number of things, fixing warnings, AtmosAlarmType instead of AtmosMonitorAlarmType 2022-08-29 07:37:26 -07:00
vulppine
b7f8c4b7ec fixes constructor 2022-08-23 13:24:39 -07:00
Flipp Syder
f00a5cb17a Merge branch 'master' into air-alarm-fixup 2022-08-23 13:21:05 -07:00
vulppine
b3a4ef9997 file-scoped namespaces 2022-08-23 10:55:46 -07:00
Leon Friedrich
921e2ee57d BUI changes required for Engine PR (#10608) 2022-08-21 03:38:30 +10:00
vulppine
8878c0d8a6 ui fix for sensor info 2022-08-20 00:14:16 -07:00
vulppine
9b3df8740f sensor info is now wider, air alarm now actually updates the networked device state 2022-08-19 05:23:25 -07:00
vulppine
14fad57e14 more UI adjustments 2022-08-19 04:17:52 -07:00
vulppine
11c1b60df9 margin changes 2022-08-19 04:10:24 -07:00
vulppine
a0e9f4d0b8 UI changes 2022-08-19 04:06:09 -07:00
vulppine
bf215350a7 double whoops (and also some localization) 2022-08-19 00:29:18 -07:00
vulppine
7f76d49ea8 whoops! 2022-08-19 00:20:50 -07:00
vulppine
376f4c8972 sensor UI 2022-08-18 23:54:39 -07:00
vulppine
787bcf903c tab setting on updatestate 2022-08-18 08:16:30 -07:00
vulppine
327314b82f tab changing 2022-08-18 08:14:18 -07:00
vulppine
35ba20de17 air alarm window changes, firelock alarmable 2022-08-18 07:52:21 -07:00
vulppine
531f0cb0e5 ui updates (no sensors yet) 2022-08-18 07:03:37 -07:00
vulppine
1c651f051f some backend stuff for air alarms
finally, some UI states!!!
2022-08-17 23:46:15 -07:00
metalgearsloth
45bd1edd5b Revert "Update submodule to 0.34.0.0 (#10356)" (#10359) 2022-08-06 16:48:21 +10:00
Leon Friedrich
e06ea56eb2 Content BUI changes for engine PR (#10308) 2022-08-06 14:59:02 +10:00
Flipp Syder
565bfa86a4 Air alarm fixes (again, oops) (#7715)
* fixes critical issue

* alright, this might be the actual fix

* removes useless null checks

* couple more

* removes default functions from unary device data
2022-04-22 23:21:00 -07:00
mirrorcult
ec4d4688c7 Seal/abstract/virtual everything (#6739) 2022-02-16 18:23:23 +11:00
wrexbe
cea1b21832 Fixing some warnings (#6250)
Co-authored-by: Paul Ritter <ritter.paul1@googlemail.com>
2022-01-21 10:38:35 +01:00
Flipp Syder
b1584793bf Adds fire/air alarms (#5018)
Co-authored-by: Vera Aguilera Puerto <6766154+Zumorica@users.noreply.github.com>
Co-authored-by: E F R <602406+Efruit@users.noreply.github.com>
Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
2022-01-02 15:56:24 +11:00