diff options
author | Yegappan Lakshmanan <yegappan@yahoo.com> | 2021-06-23 20:46:52 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2021-06-23 20:46:52 +0200 |
commit | 18d46587b985923ef4b90b19a0cf37a094607fec (patch) | |
tree | 6e680815dc89cd49aa178486f320df88191fecf8 /runtime | |
parent | 8cec9273d2518f2a9abcbd326722a2eba38d2a13 (diff) |
patch 8.2.3040: GUI: dropping files not testedv8.2.3040
Problem: GUI: dropping files not tested.
Solution: Add test_gui_drop_files() and tests. (Yegappan Lakshmanan,
closes #8434)
Diffstat (limited to 'runtime')
-rw-r--r-- | runtime/doc/eval.txt | 2 | ||||
-rw-r--r-- | runtime/doc/testing.txt | 21 | ||||
-rw-r--r-- | runtime/doc/usr_41.txt | 1 |
3 files changed, 21 insertions, 3 deletions
diff --git a/runtime/doc/eval.txt b/runtime/doc/eval.txt index 1f52d9f05b..8a8431281d 100644 --- a/runtime/doc/eval.txt +++ b/runtime/doc/eval.txt @@ -3022,6 +3022,8 @@ test_feedinput({string}) none add key sequence to input buffer test_garbagecollect_now() none free memory right now for testing test_garbagecollect_soon() none free memory soon for testing test_getvalue({string}) any get value of an internal variable +test_gui_drop_files({list}, {row}, {col}, {mods}) + none drop a list of files in a window test_gui_mouse_event({button}, {row}, {col}, {repeated}, {mods}) none add a mouse event to the input buffer test_ignore_error({expr}) none ignore a specific error diff --git a/runtime/doc/testing.txt b/runtime/doc/testing.txt index db505e7efc..eef322714e 100644 --- a/runtime/doc/testing.txt +++ b/runtime/doc/testing.txt @@ -79,10 +79,23 @@ test_getvalue({name}) *test_getvalue()* Can also be used as a |method|: > GetName()->test_getvalue() < + *test_gui_drop_files()* +test_gui_drop_files({list}, {row}, {col}, {mods}) + Drop one or more files in {list} in the window at {row}, {col}. + This function only works when the GUI is running. + + The supported values for {mods} are: + 0x4 Shift + 0x8 Alt + 0x10 Ctrl + The files are added to the argument list and the first file in + {list} is edited in the window. See |drag-n-drop| for more + information. + *test_gui_mouse_event()* test_gui_mouse_event({button}, {row}, {col}, {multiclick}, {modifiers}) - Inject a mouse button click event. This function works only - when GUI is running. + Inject a mouse button click event. This function only works + when the GUI is running. The supported values for {button} are: 0 right mouse button 1 middle mouse button @@ -92,7 +105,9 @@ test_gui_mouse_event({button}, {row}, {col}, {multiclick}, {modifiers}) 5 scroll wheel up 6 scroll wheel left 7 scroll wheel right - {row} and {col} specify the location of the mouse click. + {row} and {col} specify the location of the mouse click. The + first row of the Vim window is 1 and the last row is 'lines'. + The maximum value of {col} is 'columns'. To inject a multiclick event, set {multiclick} to 1. The supported values for {modifiers} are: 4 shift is pressed diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt index de7f197078..54e5e2930d 100644 --- a/runtime/doc/usr_41.txt +++ b/runtime/doc/usr_41.txt @@ -1021,6 +1021,7 @@ Testing: *test-functions* test_garbagecollect_now() free memory right now test_garbagecollect_soon() set a flag to free memory soon test_getvalue() get value of an internal variable + test_gui_drop_files() drop file(s) in a window test_gui_mouse_event() add a GUI mouse event to the input buffer test_ignore_error() ignore a specific error message test_null_blob() return a null Blob |