| 1755 | //----------------------------------------------------------------------------- |
| 1756 | |
| 1757 | void VPathEditor::VPathEditorEditPathAction::undo( void ) |
| 1758 | { |
| 1759 | const MatrixF oldTransform = mTransform; |
| 1760 | const MatrixF newTransform = mPath->getTransform(); |
| 1761 | |
| 1762 | // Apply Old Values. |
| 1763 | mEditor->setPathTransform( oldTransform ); |
| 1764 | |
| 1765 | // The ol' Switcheroo. |
| 1766 | mTransform = newTransform; |
| 1767 | |
| 1768 | // Update Selection. |
| 1769 | mEditor->updateSelection(); |
| 1770 | |
| 1771 | if ( mPath == mEditor->mSelection.Path ) |
| 1772 | { |
| 1773 | // Arg Buffer. |
| 1774 | char buffer[32]; |
| 1775 | dSprintf( buffer, sizeof( buffer ), "%d", mPath->getId() ); |
| 1776 | |
| 1777 | // Callback. |
| 1778 | Con::executef( mEditor, "onUpdatePath", buffer ); |
| 1779 | } |
| 1780 | |
| 1781 | // Set World Editor Dirty. |
| 1782 | mEditor->setWorldEditorDirty(); |
| 1783 | } |
| 1784 | |
| 1785 | void VPathEditor::VPathEditorEditPathAction::redo( void ) |
| 1786 | { |
nothing calls this directly
no test coverage detected