MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / doubleClickAt

Function doubleClickAt

cpp/webdriver-interactions/interactions.cpp:726–754  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

724}
725
726LRESULT doubleClickAt(WINDOW_HANDLE handle, long x, long y)
727{
728 // A double click consists of the sequence
729 // 1: mouseDown
730 // 2: mouseUp
731 // 3: doubleClick
732 // 4: mouseUp
733 // Which is the equivalent to two clicks with the second mouseDown event
734 // is replaced by a doubleClick event.
735
736 if (!handle) {
737 LOG(WARN) << "Window handle is invalid";
738 return ENULLPOINTER;
739 }
740
741 LRESULT result = clickAt(handle, x, y, 0);
742 if (result != 0) {
743 LOG(WARN) << "Mouse down did not succeed whilst clicking";
744 return result;
745 }
746
747 result = mouseDoubleClickDown(handle, x, y);
748 if (result != 0) {
749 LOG(WARN) << "Mouse down did not succeed whilst double clicking";
750 return result;
751 }
752
753 return mouseUpAt(handle, x, y, 0);
754}
755
756static void fillEventData(long button, bool buttonDown, UINT *message, WPARAM *wparam)
757{

Callers

nothing calls this directly

Calls 4

mouseDoubleClickDownFunction · 0.85
LOGClass · 0.70
clickAtFunction · 0.70
mouseUpAtFunction · 0.70

Tested by

no test coverage detected