1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-28 13:56:37 +02:00

relay/api: add support of hidden buffers in remote client (issue #2159)

This commit is contained in:
Sébastien Helleu
2024-08-10 12:55:17 +02:00
parent b00f94dc70
commit bb2387ec38
2 changed files with 5 additions and 2 deletions
+1 -1
View File
@@ -17,7 +17,7 @@
- core: allow buffer id in commands `/buffer` and `/print`, in addition to number and name
- core: allow mask in command `/item refresh`
- relay: enable websocket extension "permessage-deflate" with "api" relay only ([#1549](https://github.com/weechat/weechat/issues/1549))
- relay/api: add field "hidden" in GET /api/buffers ([#2159](https://github.com/weechat/weechat/issues/2159))
- relay/api: add field "hidden" in GET /api/buffers, add support of hidden buffers in remote client ([#2159](https://github.com/weechat/weechat/issues/2159))
- relay/weechat: add line id in buffer lines sent to clients
- relay: display connection status in output of commands `/remote list` and `/remote listfull`
- relay: add option `reconnect` in command `/remote` ([#2160](https://github.com/weechat/weechat/issues/2160))
@@ -842,7 +842,8 @@ RELAY_REMOTE_EVENT_CALLBACK(buffer)
const char *ptr_key, *ptr_command;
char *full_name, str_number[64], str_local_var[1024], *property;
long long id;
int number, nicklist, nicklist_case_sensitive, nicklist_display_groups;
int number, hidden, nicklist;
int nicklist_case_sensitive, nicklist_display_groups;
int apply_props, input_position, input_multiline;
if (!event->json)
@@ -853,6 +854,7 @@ RELAY_REMOTE_EVENT_CALLBACK(buffer)
JSON_GET_STR(event->json, short_name);
JSON_GET_NUM(event->json, number, -1);
JSON_GET_STR(event->json, type);
JSON_GET_BOOL(event->json, hidden);
JSON_GET_STR(event->json, title);
JSON_GET_STR(event->json, modes);
JSON_GET_STR(event->json, input_prompt);
@@ -873,6 +875,7 @@ RELAY_REMOTE_EVENT_CALLBACK(buffer)
/* buffer base properties */
weechat_hashtable_set (buffer_props, "type", type);
weechat_hashtable_set (buffer_props, "hidden", (hidden) ? "1" : "0");
weechat_hashtable_set (buffer_props, "short_name", short_name);
weechat_hashtable_set (buffer_props, "title", title);
weechat_hashtable_set (buffer_props, "modes", modes);