1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 06:37:35 +00:00

PixelPaint: Add "Delete Mask" action

This commit adds a "Delete Mask" action which deletes the active layer
mask. The option is only displayed if the active layer is masked.
This commit is contained in:
Tim Ledbetter 2023-02-25 06:45:55 +00:00 committed by Andreas Kling
parent d66f143fb7
commit 062c9efa88
4 changed files with 55 additions and 8 deletions

View file

@ -56,6 +56,7 @@ private:
void image_editor_did_update_undo_stack();
void set_actions_enabled(bool enabled);
void set_mask_actions_for_layer(Layer* active_layer);
virtual void drag_enter_event(GUI::DragEvent&) override;
virtual void drop_event(GUI::DropEvent&) override;
@ -110,6 +111,9 @@ private:
RefPtr<GUI::Action> m_layer_via_copy;
RefPtr<GUI::Action> m_layer_via_cut;
RefPtr<GUI::Action> m_add_mask_action;
RefPtr<GUI::Action> m_delete_mask_action;
Gfx::IntPoint m_last_image_editor_mouse_position;
};