mirror of
https://github.com/weechat/weechat.git
synced 2026-07-02 15:53:12 +02:00
api: allow update for some variables of hdata, add new functions hdata_update and hdata_set
This commit is contained in:
@@ -963,17 +963,18 @@ irc_notify_hdata_notify_cb (void *data, const char *hdata_name)
|
||||
/* make C compiler happy */
|
||||
(void) data;
|
||||
|
||||
hdata = weechat_hdata_new (hdata_name, "prev_notify", "next_notify");
|
||||
hdata = weechat_hdata_new (hdata_name, "prev_notify", "next_notify",
|
||||
0, NULL, NULL);
|
||||
if (hdata)
|
||||
{
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, server, POINTER, NULL, "irc_server");
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, nick, STRING, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, check_away, INTEGER, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, is_on_server, INTEGER, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, away_message, STRING, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, ison_received, INTEGER, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, prev_notify, POINTER, NULL, hdata_name);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, next_notify, POINTER, NULL, hdata_name);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, server, POINTER, 0, NULL, "irc_server");
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, nick, STRING, 0, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, check_away, INTEGER, 0, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, is_on_server, INTEGER, 0, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, away_message, STRING, 0, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, ison_received, INTEGER, 0, NULL, NULL);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, prev_notify, POINTER, 0, NULL, hdata_name);
|
||||
WEECHAT_HDATA_VAR(struct t_irc_notify, next_notify, POINTER, 0, NULL, hdata_name);
|
||||
}
|
||||
return hdata;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user