|
FuncDoodle
|
Represents a single-pixel draw operation for undo/redo. More...
#include <Core.h>
Public Member Functions | |
| DrawAction (int x, int y, Col prev, Col next, unsigned long frameI, const SharedPtr< ProjectFile > &proj) | |
| Creates a draw action for a single pixel change. | |
| DrawAction (const DrawAction &other)=default | |
| Copy constructor. | |
| ~DrawAction () override=default | |
| Destructor. | |
| void | Undo () override |
| Reverts the pixel to its previous color. | |
| void | Redo () override |
| Applies the new pixel color. | |
| Public Member Functions inherited from FuncDoodle::Action | |
| virtual | ~Action ()=default |
| Virtual destructor for safe polymorphic destruction. | |
Private Attributes | |
| int | m_X |
| int | m_Y |
| Col | m_Prev |
| Col | m_Next |
| unsigned long | m_FrameIndex |
| WeakPtr< ProjectFile > | m_Proj |
Represents a single-pixel draw operation for undo/redo.
Stores the previous and new color of a pixel so the change can be reverted or reapplied on a specific frame.
|
inline |
Creates a draw action for a single pixel change.
|
default |
Copy constructor.
|
overridedefault |
Destructor.
|
overridevirtual |
Applies the new pixel color.
Implements FuncDoodle::Action.
|
overridevirtual |
Reverts the pixel to its previous color.
Implements FuncDoodle::Action.
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |