robin/laufey
git clone https://git.robinwobin.dev/robin/laufey
38986188ba
master
1#pragma once 2 3#include "nvim/eval/typval_defs.h" // IWYU pragma: keep 4#include "nvim/normal_defs.h" // IWYU pragma: keep 5#include "nvim/types_defs.h" // IWYU pragma: keep 6#include "nvim/vim_defs.h" // IWYU pragma: keep 7 8/// jump_to_mouse() returns one of first five these values, possibly with 9/// some of the other five added. 10enum { 11IN_UNKNOWN = 0 , 12IN_BUFFER = 1 , 13IN_STATUS_LINE = 2 ,///< on status or command line 14IN_SEP_LINE = 4 ,///< on vertical separator line 15IN_OTHER_WIN = 8 ,///< in other window but can't go there 16CURSOR_MOVED = 0x100 , 17MOUSE_FOLD_CLOSE = 0x200 ,///< clicked on '-' in fold column 18MOUSE_FOLD_OPEN = 0x400 ,///< clicked on '+' in fold column 19MOUSE_WINBAR = 0x800 ,///< in window toolbar 20MOUSE_STATUSCOL = 0x1000 ,///< in 'statuscolumn' 21}; 22 23/// flags for jump_to_mouse() 24enum { 25MOUSE_FOCUS = 0x01 ,///< need to stay in this window 26MOUSE_MAY_VIS = 0x02 ,///< may start Visual mode 27MOUSE_DID_MOVE = 0x04 ,///< only act when mouse has moved 28MOUSE_SETPOS = 0x08 ,///< only set current mouse position 29MOUSE_MAY_STOP_VIS = 0x10 ,///< may stop Visual mode 30MOUSE_RELEASED = 0x20 ,///< button was released 31}; 32 33enum { 34// Codes for mouse button events in lower three bits: 35MOUSE_LEFT = 0x00 , 36MOUSE_MIDDLE = 0x01 , 37MOUSE_RIGHT = 0x02 , 38MOUSE_RELEASE = 0x03 , 39 40// mouse buttons that are handled like a key press 41MOUSE_X1 = 0x300 ,///< Mouse-button X1 (6th) 42MOUSE_X2 = 0x400 ,///< Mouse-button X2 43}; 44 45/// Direction for nv_mousescroll() and ins_mousescroll() 46enum { 47MSCR_DOWN = 0 ,///< DOWN must be false 48MSCR_UP = 1 , 49MSCR_LEFT = -1 , 50MSCR_RIGHT = -2 , 51}; 52 53#include "mouse.h.generated.h"