diff options
author | Karol Kosek <krkk@serenityos.org> | 2021-09-25 21:59:05 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-09-25 23:34:02 +0200 |
commit | 5a5f6d11ef4f7380a2004c4000104284c6c19e97 (patch) | |
tree | e4d294ce274d4093f76e4a061b93069c293a6120 /Userland/Applications/PixelPaint | |
parent | df195188bc68b48d20f584b9fd29a65ac5b567e9 (diff) | |
download | serenity-5a5f6d11ef4f7380a2004c4000104284c6c19e97.zip |
PixelPaint: Close image tabs on middle click
Diffstat (limited to 'Userland/Applications/PixelPaint')
-rw-r--r-- | Userland/Applications/PixelPaint/MainWidget.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Userland/Applications/PixelPaint/MainWidget.cpp b/Userland/Applications/PixelPaint/MainWidget.cpp index aeeb92f17e..75413d267c 100644 --- a/Userland/Applications/PixelPaint/MainWidget.cpp +++ b/Userland/Applications/PixelPaint/MainWidget.cpp @@ -55,6 +55,10 @@ MainWidget::MainWidget() m_tool_properties_widget->set_active_tool(tool); }; + m_tab_widget->on_middle_click = [&](auto& widget) { + m_tab_widget->on_tab_close_click(widget); + }; + m_tab_widget->on_tab_close_click = [&](auto& widget) { auto& image_editor = verify_cast<PixelPaint::ImageEditor>(widget); |