34 aElement.context_menu().trigger(
menu.
menu());
35 action actionSendToBack{
"Send To Back"_t };
36 action actionBringToFont{
"Bring To Front"_t };
37 auto& actionCut = service<i_app>().action_cut();
38 auto& actionCopy = service<i_app>().action_copy();
39 auto& actionPaste = service<i_app>().action_paste();
40 auto& actionDelete = service<i_app>().action_delete();
41 auto& actionSelectAll = service<i_app>().action_select_all();
45 if (&*caddyWidget.parent().children().back() == &caddyWidget)
47 if (&*caddyWidget.parent().children().front() == &caddyWidget)
48 actionBringToFont.disable();
49 actionSendToBack.triggered([&]()
56 if (aElement.has_caddy())
57 aElement.caddy().send_to_back();
63 actionBringToFont.triggered([&]()
70 if (aElement.has_caddy())
71 aElement.caddy().bring_to_front();
75 menu.
menu().add_action(actionSendToBack);
76 menu.
menu().add_action(actionBringToFont);
82 menu.
menu().add_action(actionDelete);
84 menu.
menu().add_action(actionSelectAll);