MCPcopy Create free account
hub / github.com/XRay3D/GERBER_X3 / Handler

Method Handler

shape_plugins/shape/shhandler.cpp:60–79  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

58}
59
60Handler::Handler(Shape* shape, HType type)
61 : shape(shape)
62 , m_hType(type)
63{
64 setAcceptHoverEvents(true);
65 setFlags(ItemIsMovable);
66 switch (m_hType) {
67 case Adder:
68 setZValue(std::numeric_limits<double>::max() - 2);
69 break;
70 case Center:
71 setZValue(std::numeric_limits<double>::max() - 0);
72 break;
73 case Corner:
74 setZValue(std::numeric_limits<double>::max() - 1);
75 break;
76 }
77 App::scene()->addItem(this);
78 App::shapeHandlers().emplace_back(this);
79}
80
81Handler::~Handler()
82{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected