add follow argument

This commit is contained in:
yggverse 2024-09-04 03:42:39 +03:00
parent ff901ebcf8
commit 03f0eeaf9b
2 changed files with 8 additions and 3 deletions

View File

@ -73,7 +73,8 @@ bool History::try_forward(
}
void History::push(
const Glib::ustring & REQUEST
const Glib::ustring & REQUEST,
bool follow
) {
if (memory.empty() || memory.back().request != REQUEST)
{
@ -87,7 +88,10 @@ void History::push(
}
);
index = memory.size(); // @TODO
if (follow)
{
index = memory.size();
}
}
}

View File

@ -51,7 +51,8 @@ namespace app::browser::main::tab::page::navbar
);
void push(
const Glib::ustring & REQUEST
const Glib::ustring & REQUEST,
bool follow = true
);
void refresh();