MCPcopy Create free account
hub / github.com/MITK/MITK / InitializeStateMachine

Method InitializeStateMachine

Modules/Segmentation/src/Interactions/mitkTool.cpp:64–84  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

62}
63
64void mitk::Tool::InitializeStateMachine()
65{
66 if (m_InteractorType.empty())
67 return;
68
69 try
70 {
71 auto isThisModule = nullptr == m_InteractorModule;
72
73 auto module = isThisModule
74 ? us::GetModuleContext()->GetModule()
75 : m_InteractorModule;
76
77 LoadStateMachine(m_InteractorType + ".xml", module);
78 SetEventConfig(isThisModule ? "SegmentationToolsConfig.xml" : m_InteractorType + "Config.xml", module);
79 }
80 catch (const std::exception &e)
81 {
82 MITK_ERROR << "Could not load statemachine pattern " << m_InteractorType << ".xml with exception: " << e.what();
83 }
84}
85
86void mitk::Tool::Notify(InteractionEvent *interactionEvent, bool isHandled)
87{

Callers 1

InitializeToolsMethod · 0.80

Calls 4

GetModuleContextFunction · 0.85
whatMethod · 0.80
emptyMethod · 0.45
GetModuleMethod · 0.45

Tested by

no test coverage detected