mirror of
https://github.com/neovim/neovim.git
synced 2025-09-13 23:08:16 +00:00
api: unify buffer numbers and window ids with handles
also allow handle==0 meaning curbuf/curwin/curtab
This commit is contained in:
@@ -472,7 +472,7 @@ void vim_set_current_buffer(Buffer buffer, Error *err)
|
||||
if (!try_end(err) && result == FAIL) {
|
||||
api_set_error(err,
|
||||
Exception,
|
||||
_("Failed to switch to buffer %" PRIu64),
|
||||
_("Failed to switch to buffer %d"),
|
||||
buffer);
|
||||
}
|
||||
}
|
||||
@@ -522,7 +522,7 @@ void vim_set_current_window(Window window, Error *err)
|
||||
if (!try_end(err) && win != curwin) {
|
||||
api_set_error(err,
|
||||
Exception,
|
||||
_("Failed to switch to window %" PRIu64),
|
||||
_("Failed to switch to window %d"),
|
||||
window);
|
||||
}
|
||||
}
|
||||
@@ -573,7 +573,7 @@ void vim_set_current_tabpage(Tabpage tabpage, Error *err)
|
||||
if (!try_end(err) && tp != curtab) {
|
||||
api_set_error(err,
|
||||
Exception,
|
||||
_("Failed to switch to tabpage %" PRIu64),
|
||||
_("Failed to switch to tabpage %d"),
|
||||
tabpage);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user