fix(libsimu): move Menu wrapper methods to fix Windows build (#7015)

This commit is contained in:
Peter Feerick
2026-01-23 10:36:20 +10:00
committed by GitHub
parent 6901c410ca
commit fbf96600a3
2 changed files with 14 additions and 8 deletions
+12
View File
@@ -400,6 +400,12 @@ void Menu::addLine(const MaskBitmap* icon_mask, const std::string& text,
updatePosition();
}
void Menu::addLine(const std::string &text, std::function<void()> onPress,
std::function<bool()> isChecked)
{
addLine(nullptr, text, onPress, isChecked);
}
void Menu::addLineBuffered(const MaskBitmap* icon_mask, const std::string& text,
std::function<void()> onPress,
std::function<bool()> isChecked)
@@ -408,6 +414,12 @@ void Menu::addLineBuffered(const MaskBitmap* icon_mask, const std::string& text,
false);
}
void Menu::addLineBuffered(const std::string &text, std::function<void()> onPress,
std::function<bool()> isChecked)
{
addLineBuffered(nullptr, text, onPress, isChecked);
}
void Menu::updateLines()
{
content->updateLines();
+2 -8
View File
@@ -49,20 +49,14 @@ class Menu : public ModalWindow
std::function<bool()> isChecked = nullptr);
void addLine(const std::string &text, std::function<void()> onPress,
std::function<bool()> isChecked = nullptr)
{
addLine(nullptr, text, onPress, isChecked);
}
std::function<bool()> isChecked = nullptr);
void addLineBuffered(const MaskBitmap *icon_mask, const std::string &text,
std::function<void()> onPress,
std::function<bool()> isChecked = nullptr);
void addLineBuffered(const std::string &text, std::function<void()> onPress,
std::function<bool()> isChecked = nullptr)
{
addLineBuffered(nullptr, text, onPress, isChecked);
}
std::function<bool()> isChecked = nullptr);
void updateLines();