mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
API: Implement window_get_buffer
This commit is contained in:
parent
9d18533ca3
commit
6c850bd6b9
@ -4,11 +4,18 @@
|
||||
|
||||
#include "api/window.h"
|
||||
#include "api/defs.h"
|
||||
#include "api/helpers.h"
|
||||
|
||||
|
||||
Buffer window_get_buffer(Window window, Error *err)
|
||||
{
|
||||
abort();
|
||||
win_T *win = find_window(window, err);
|
||||
|
||||
if (!win) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
return win->w_buffer->b_fnum;
|
||||
}
|
||||
|
||||
Position window_get_cursor(Window window, Error *err)
|
||||
|
Loading…
Reference in New Issue
Block a user