mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 11:27:35 +00:00
LibGUI: Add SettingsWindow class
The FooSettings apps have quite a lot of boilerplate just around creating a tabbed window with the same styling and the same row of buttons along the bottom. So, let's extract that out into a class we can reuse! :^) You create a SettingsWindow instead of a regular Window, passing a title and a flag to determine if a "Defaults" button is shown. Then call add_tab() to add tabs to it. Tabs are widgets extending SettingsWindow::Tab, which has methods for saving and resetting the values.
This commit is contained in:
parent
4b34a1302b
commit
23341f35cb
3 changed files with 130 additions and 0 deletions
|
@ -84,6 +84,7 @@ set(SOURCES
|
|||
ScrollableContainerWidget.cpp
|
||||
Scrollbar.cpp
|
||||
SeparatorWidget.cpp
|
||||
SettingsWindow.cpp
|
||||
Shortcut.cpp
|
||||
Slider.cpp
|
||||
SortingProxyModel.cpp
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue