mirror of
https://github.com/YGGverse/Yoda.git
synced 2025-03-12 05:31:06 +00:00
draft children components save action delegation
This commit is contained in:
parent
7e8aaef1c5
commit
b1f2a1b893
@ -129,7 +129,7 @@ int Tab::save()
|
||||
// Save current tab session
|
||||
for (int page_number = 0; page_number < get_n_pages(); page_number++)
|
||||
{
|
||||
auto tabLabel = get_tabLabel(
|
||||
const auto TAB_LABEL = get_tabLabel(
|
||||
page_number
|
||||
);
|
||||
|
||||
@ -151,12 +151,17 @@ int Tab::save()
|
||||
)SQL",
|
||||
page_number,
|
||||
page_number == get_current_page() ? 1 : 0,
|
||||
tabLabel->get_text()
|
||||
TAB_LABEL->get_text()
|
||||
).c_str(),
|
||||
nullptr,
|
||||
nullptr,
|
||||
&error
|
||||
);
|
||||
|
||||
// Delegate save action to the page component
|
||||
get_tabPage(
|
||||
page_number
|
||||
)->save();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -63,6 +63,13 @@ void Page::refresh()
|
||||
);
|
||||
}
|
||||
|
||||
int Page::save()
|
||||
{
|
||||
pageNavigation->save();
|
||||
|
||||
return 1; // @TODO SQL
|
||||
}
|
||||
|
||||
void Page::update(
|
||||
const enum MIME & MIME,
|
||||
const Glib::ustring & TITLE,
|
||||
|
@ -70,6 +70,8 @@ namespace app::browser::main::tab
|
||||
// Actions
|
||||
void refresh();
|
||||
|
||||
int save();
|
||||
|
||||
void update(
|
||||
const MIME & MIME,
|
||||
const Glib::ustring & TITLE,
|
||||
|
@ -101,6 +101,13 @@ void Navigation::refresh(
|
||||
);
|
||||
}
|
||||
|
||||
int Navigation::save()
|
||||
{
|
||||
navigationRequest->save();
|
||||
|
||||
return 1; // @TODO SQL
|
||||
}
|
||||
|
||||
void Navigation::history_add(
|
||||
const Glib::ustring & REQUEST,
|
||||
const bool & UPDATE_MEMORY_INDEX
|
||||
|
@ -45,6 +45,8 @@ namespace app::browser::main::tab::page
|
||||
const double & PROGRESS_FRACTION
|
||||
);
|
||||
|
||||
int save();
|
||||
|
||||
void history_add(
|
||||
const Glib::ustring & REQUEST,
|
||||
const bool & UPDATE_MEMORY_INDEX
|
||||
|
@ -78,6 +78,11 @@ void Request::refresh(
|
||||
);
|
||||
}
|
||||
|
||||
int Request::save()
|
||||
{
|
||||
return 1; // @TODO SQL
|
||||
}
|
||||
|
||||
void Request::parse()
|
||||
{
|
||||
auto match = Glib::Regex::split_simple(
|
||||
|
@ -46,6 +46,8 @@ namespace app::browser::main::tab::page::navigation
|
||||
const double & PROGRESS_FRACTION
|
||||
);
|
||||
|
||||
int save();
|
||||
|
||||
// Getters
|
||||
Glib::ustring get_scheme();
|
||||
Glib::ustring get_host();
|
||||
|
Loading…
x
Reference in New Issue
Block a user