MCPcopy Create free account
hub / github.com/Nelarius/imnodes / IsLinkStarted

Function IsLinkStarted

imnodes.cpp:2868–2883  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2866}
2867
2868bool IsLinkStarted(int* const started_at_id)
2869{
2870 // Call this function after EndNodeEditor()!
2871 assert(GImNodes->CurrentScope == ImNodesScope_None);
2872 assert(started_at_id != NULL);
2873
2874 const bool is_started = (GImNodes->ImNodesUIState & ImNodesUIState_LinkStarted) != 0;
2875 if (is_started)
2876 {
2877 const ImNodesEditorContext& editor = EditorContextGet();
2878 const int pin_idx = editor.ClickInteraction.LinkCreation.StartPinIdx;
2879 *started_at_id = editor.Pins.Pool[pin_idx].Id;
2880 }
2881
2882 return is_started;
2883}
2884
2885bool IsLinkDropped(int* const started_at_id, const bool including_detached_links)
2886{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected