mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-01-22 17:24:48 -05:00
AK: Add ScopedValueRollback::set_override_rollback_value().
This can be used if you change your mind about what value we should roll back to. :^)
This commit is contained in:
parent
65c3101897
commit
6ae95945aa
Notes:
sideshowbarker
2024-07-19 13:03:31 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/6ae95945aa0
1 changed files with 5 additions and 0 deletions
|
@ -16,6 +16,11 @@ public:
|
|||
m_variable = m_saved_value;
|
||||
}
|
||||
|
||||
void set_override_rollback_value(const T& value)
|
||||
{
|
||||
m_saved_value = value;
|
||||
}
|
||||
|
||||
private:
|
||||
T& m_variable;
|
||||
T m_saved_value;
|
||||
|
|
Loading…
Reference in a new issue