From 4f184114de24149d9bd6d64a2511bfe79deb170a Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Tue, 17 Sep 2019 22:39:48 +0200 Subject: [PATCH] VisualBuilder: Add icons for the layout menu actions --- Base/res/icons/16x16/layout-horizontally.png | Bin 0 -> 104 bytes Base/res/icons/16x16/layout-vertically.png | Bin 0 -> 95 bytes DevTools/VisualBuilder/VBForm.cpp | 5 +++-- 3 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 Base/res/icons/16x16/layout-horizontally.png create mode 100644 Base/res/icons/16x16/layout-vertically.png diff --git a/Base/res/icons/16x16/layout-horizontally.png b/Base/res/icons/16x16/layout-horizontally.png new file mode 100644 index 0000000000000000000000000000000000000000..45caadb13178252c1a38f69b3a9112c50f671458 GIT binary patch literal 104 zcmeAS@N?(olHy`uVBq!ia0y~yU=RRd4mJh`2Kmqb6B!s7^gUf1Lo7}wCrEs15bXUw zKcv>@h0*{2|I>f`|8E~>W|Xk#3io0*9yVqTKaax<3=D@nMHo#)lGqs-7#KWV{an^L HB{Ts5#)BTz literal 0 HcmV?d00001 diff --git a/Base/res/icons/16x16/layout-vertically.png b/Base/res/icons/16x16/layout-vertically.png new file mode 100644 index 0000000000000000000000000000000000000000..21bd239d94950d48b5deb987284ce4d9621b8e59 GIT binary patch literal 95 zcmeAS@N?(olHy`uVBq!ia0y~yU=RRd4mJh`2Kmqb6B!s7)I41rLo7}wCrEs15bXUw xKcrUYh0*{2kIkDW3SRYF7O3A-l~}>R&}zgh{$%-0Sq26M22WQ%mvv4FO#q&-9UK4v literal 0 HcmV?d00001 diff --git a/DevTools/VisualBuilder/VBForm.cpp b/DevTools/VisualBuilder/VBForm.cpp index 8e7ef948e0..84362a0b8f 100644 --- a/DevTools/VisualBuilder/VBForm.cpp +++ b/DevTools/VisualBuilder/VBForm.cpp @@ -6,6 +6,7 @@ #include #include #include +#include #include #include #include @@ -37,13 +38,13 @@ VBForm::VBForm(const String& name, GWidget* parent) widget->gwidget()->move_to_back(); })); m_context_menu->add_separator(); - m_context_menu->add_action(GAction::create("Lay out horizontally", [this](auto&) { + m_context_menu->add_action(GAction::create("Lay out horizontally", load_png("/res/icons/16x16/layout-horizontally.png"), [this](auto&) { if (auto* widget = single_selected_widget()) { dbg() << "Giving " << *widget->gwidget() << " a horizontal box layout"; widget->gwidget()->set_layout(make(Orientation::Horizontal)); } })); - m_context_menu->add_action(GAction::create("Lay out vertically", [this](auto&) { + m_context_menu->add_action(GAction::create("Lay out vertically", load_png("/res/icons/16x16/layout-vertically.png"), [this](auto&) { if (auto* widget = single_selected_widget()) { dbg() << "Giving " << *widget->gwidget() << " a vertical box layout"; widget->gwidget()->set_layout(make(Orientation::Vertical));