Skip to content

Commit 3d0f385

Browse files
committed
Update snippets/mouse_clicks.py (cztomczak#403)
1 parent 5b51fc3 commit 3d0f385

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

examples/snippets/mouse_clicks.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,14 @@ def main():
1818

1919
def click_after_1_second(browser):
2020
print("Click after 1 second")
21+
# Mouse move to the top-left corner of the text
2122
browser.SendMouseMoveEvent(0, 70, False, 0)
23+
# Left mouse button click in the top-left corner of the text
2224
browser.SendMouseClickEvent(0, 70, cef.MOUSEBUTTON_LEFT, False, 1)
25+
# Mouse move to the bottom-right corner of the text,
26+
# while holding left mouse button.
2327
browser.SendMouseMoveEvent(400, 80, False, cef.EVENTFLAG_LEFT_MOUSE_BUTTON)
28+
# Release left mouse button
2429
browser.SendMouseClickEvent(400, 80, cef.MOUSEBUTTON_LEFT, True, 1)
2530
cef.PostDelayedTask(cef.TID_UI, 1000, click_after_2_seconds, browser)
2631

src/cef_v59..v66_changes.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ NEW FEATURES
8181
+ examples/snippets/
8282
+ onbeforeclose.py
8383
+ network_cookies.py
84+
+ mouse_clicks.py
8485

8586
internal/cef_types.h
8687
+ cef_log_severity_t: new key LOGSEVERITY_DEBUG (no need to expose,

0 commit comments

Comments
 (0)