1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-06-01 07:38:10 +00:00

PixelPaint: Add Merge Active Layer Down action

This allows you to merge the active layer with the one below it.
This commit is contained in:
Mustafa Quraish 2021-09-02 03:10:59 -04:00 committed by Andreas Kling
parent 97cc34c034
commit 339f0d5bca
3 changed files with 33 additions and 0 deletions

View file

@ -541,6 +541,19 @@ int main(int argc, char** argv)
},
window));
layer_menu.add_action(GUI::Action::create(
"M&erge Active Layer Down", { Mod_Ctrl, Key_E }, [&](auto&) {
auto* editor = current_image_editor();
if (!editor)
return;
auto active_layer = editor->active_layer();
if (!active_layer)
return;
editor->image().merge_active_layer_down(*active_layer);
editor->did_complete_action();
},
window));
auto& filter_menu = window->add_menu("&Filter");
auto& spatial_filters_menu = filter_menu.add_submenu("&Spatial");