OpenLexocad  27.1
CmdAddCentroid.h
Go to the documentation of this file.
1 #pragma once
2 #include <Core/Command.h>
3 #include <OpenLxApp/Element.h>
4 
5 #include <memory>
6 #include <vector>
7 
8 namespace OpenLxCmd
9 {
16 class LX_OPENLXCMD_EXPORT CmdAddCentroid : public Core::Command
17 {
18 public:
20  explicit CmdAddCentroid(std::shared_ptr<OpenLxApp::Element> curveElement);
21  explicit CmdAddCentroid(const std::vector<std::shared_ptr<OpenLxApp::Element>>& aElems);
22  ~CmdAddCentroid() = default;
23 
24  bool redo() override;
25  bool undo() override;
26 
27 private:
28  std::unique_ptr<Core::Command> _cmd;
29 };
30 }
bool undo(int id=0)
Will UNDO one step, returns False if no undo was done (Undos == 0).
bool redo(int id=0)
Will REDO one step, returns False if no redo was done (Redos == 0).
Definition: CmdAddBolt.h:7
Definition: Command.h:34
Definition: CmdAddCentroid.h:16