Files
ofxPiMapper/src/Commands/MvSelectionCmd.cpp
2017-12-26 17:10:53 +01:00

24 lines
458 B
C++

#include "MvSelectionCmd.h"
namespace ofx {
namespace piMapper {
MvSelectionCmd::MvSelectionCmd(SurfaceManager * sm, Vec3 moveBy){
_surfaceManager = sm;
_movedBy = moveBy;
}
void MvSelectionCmd::exec(){
ofLogNotice("MvSelectionCmd", "exec");
_surfaceManager->moveSelectionBy(_movedBy);
}
void MvSelectionCmd::undo(){
ofLogNotice("MvSelectionCmd", "undo");
_surfaceManager->moveSelectionBy(-_movedBy);
}
} // namespace piMapper
} // namespace ofx