mirror of
https://github.com/kovidgoyal/kitty
synced 2026-06-06 01:05:48 +02:00
Revert to 1-based directory entry indexing in DnD protocol
- dnd.c: entry_num==0 closes handle; entry_num>=1 reads at entry_num-1
- parse-dnd-command.h: revert cell_y default to 0 (from {0} init)
- gen/apc_parsers.py: remove post_init for DnD parser
- docs/dnd-protocol.rst: update to say 1-based indexing
- tests: all .index() calls add +1, rename test_dir_entry_one_based_index
Agent-Logs-Url: https://github.com/kovidgoyal/kitty/sessions/d4074aba-3aeb-4d2b-adc1-d6c6f2b539e7
Co-authored-by: kovidgoyal <1308621+kovidgoyal@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
7e0e3eb6ac
commit
4d2b63fce8
@@ -179,8 +179,8 @@ encoded and might be chunked if the directory has a lot of entries.
|
||||
|
||||
``idx`` is an arbitrary 32 bit integer that acts as a handle to this
|
||||
directory. The client can now read the files in this directory using requests of the form
|
||||
``t=d:x=idx:y=num:r=request_id``, here ``num`` is the 0-based index into the list of
|
||||
directory entries previously transmitted to the client, where, ``0`` will
|
||||
``t=d:x=idx:y=num:r=request_id``, here ``num`` is the 1-based index into the list of
|
||||
directory entries previously transmitted to the client, where, ``1`` will
|
||||
correspond to the first entry in the directory. Once the client is done
|
||||
reading a directory it should transmit ``t=d:x=idx:r=request_id`` to the terminal. The
|
||||
terminal can then free any resources associated with that directory. The
|
||||
|
||||
Reference in New Issue
Block a user