mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 02:05:07 +02:00
Base+LibWebView: Organize the settings page into tabs
The tabless page with an ever-growing list of vertical cards was getting a bit disorganized. This moves each section of the settings page to be its own tab, with buttons to switch tabs. Some of this presented the opportunity to migrate settings from popup dialogs to be directly in the tab, such as the disk cache settings. The global "restore defaults" button has also been removed. The more settings we have, the less sense such a button makes sense. Individual settings can have a reset option where it makes sense.
This commit is contained in:
Notes:
github-actions[bot]
2026-03-05 15:03:08 +00:00
Author: https://github.com/trflynn89 Commit: https://github.com/LadybirdBrowser/ladybird/commit/809ef1ac6e1 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/8272
@@ -17,9 +17,6 @@ void SettingsUI::register_interfaces()
|
||||
register_interface("loadCurrentSettings"sv, [this](auto const&) {
|
||||
load_current_settings();
|
||||
});
|
||||
register_interface("restoreDefaultSettings"sv, [this](auto const&) {
|
||||
restore_default_settings();
|
||||
});
|
||||
|
||||
register_interface("setNewTabPageURL"sv, [this](auto const& data) {
|
||||
set_new_tab_page_url(data);
|
||||
@@ -87,12 +84,6 @@ void SettingsUI::load_current_settings()
|
||||
async_send_message("loadSettings"sv, settings);
|
||||
}
|
||||
|
||||
void SettingsUI::restore_default_settings()
|
||||
{
|
||||
WebView::Application::settings().restore_defaults();
|
||||
load_current_settings();
|
||||
}
|
||||
|
||||
void SettingsUI::set_new_tab_page_url(JsonValue const& new_tab_page_url)
|
||||
{
|
||||
if (!new_tab_page_url.is_string())
|
||||
|
||||
Reference in New Issue
Block a user