diff options
author | Andreas Kling <kling@serenityos.org> | 2020-03-03 17:02:38 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-03-03 17:02:38 +0100 |
commit | a26b63a9585631d39c97db5b5808aca351894da8 (patch) | |
tree | 28f4f48f4f7c8487fb2326e23d6b070ee6e785e6 /Games | |
parent | b1d35248e45a6c4e4e9b9a55aa5d8fa60e60c276 (diff) | |
download | serenity-a26b63a9585631d39c97db5b5808aca351894da8.zip |
LibGUI: Remove Button& parameter from Button::on_click hook
There was but a single user of this parameter and it's a bit tedious
to write it out every time, so let's get rid of it.
Diffstat (limited to 'Games')
-rw-r--r-- | Games/Minesweeper/Field.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Games/Minesweeper/Field.cpp b/Games/Minesweeper/Field.cpp index 13b86757c0..fde8517cbf 100644 --- a/Games/Minesweeper/Field.cpp +++ b/Games/Minesweeper/Field.cpp @@ -147,7 +147,7 @@ Field::Field(GUI::Label& flag_label, GUI::Label& time_label, GUI::Button& face_b set_fill_with_background_color(true); reset(); - m_face_button.on_click = [this](auto&) { reset(); }; + m_face_button.on_click = [this] { reset(); }; set_face(Face::Default); { @@ -260,7 +260,7 @@ void Field::reset() square.label->set_icon(square.has_mine ? m_mine_bitmap : nullptr); if (!square.button) { square.button = add<SquareButton>(); - square.button->on_click = [this, &square](GUI::Button&) { + square.button->on_click = [this, &square] { on_square_clicked(square); }; square.button->on_right_click = [this, &square] { |