CSLA_STOP, /**< Stop notifying listeners */
};
+/**
+ * cs_listener - Listen for config changes
+ * @param cs Config items
+ * @param he HashElem representing config item
+ * @param name Name of the config item
+ * @param ev Event type, e.g. #CE_SET
+ * @retval true Continue notifying
+ */
typedef bool (*cs_listener) (const struct ConfigSet *cs, struct HashElem *he, const char *name, enum ConfigEvent ev);
+/**
+ * cs_validator - Validate the "charset" config variable
+ * @param cs Config items
+ * @param cdef Config definition
+ * @param value Native value
+ * @param err Message for the user
+ * @retval CSR_SUCCESS Success
+ * @retval CSR_ERR_INVALID Failure
+ */
typedef int (*cs_validator) (const struct ConfigSet *cs, const struct ConfigDef *cdef, intptr_t value, struct Buffer *err);
typedef int (*cst_string_set)(const struct ConfigSet *cs, void *var, struct ConfigDef *cdef, const char *value, struct Buffer *err);
}
/**
- * mutt_reply_listener - Listen for config changes to "reply_regex"
- * @param cs Config items
- * @param he HashElem representing config item
- * @param name Name of the config item
- * @param ev Event type, e.g. #CE_SET
- * @retval true Continue notifying
+ * mutt_reply_listener - Listen for config changes to "reply_regex" - Implements ::cs_listener
*/
bool mutt_reply_listener(const struct ConfigSet *cs, struct HashElem *he,
const char *name, enum ConfigEvent ev)
return cs;
}
+
/**
- * charset_validator - Validate the "charset" config variable
- * @param cs Config items
- * @param cdef Config definition
- * @param value Native value
- * @param err Message for the user
- * @retval CSR_SUCCESS Success
- * @retval CSR_ERR_INVALID Failure
+ * charset_validator - Validate the "charset" config variable - Implements ::cs_validator
*/
int charset_validator(const struct ConfigSet *cs, const struct ConfigDef *cdef,
intptr_t value, struct Buffer *err)
#ifdef USE_HCACHE
/**
- * hcache_validator - Validate the "header_cache_backend" config variable
- * @param cs Config items
- * @param cdef Config definition
- * @param value Native value
- * @param err Message for the user
- * @retval CSR_SUCCESS Success
- * @retval CSR_ERR_INVALID Failure
+ * hcache_validator - Validate the "header_cache_backend" config variable - Implements ::cs_validator
*/
int hcache_validator(const struct ConfigSet *cs, const struct ConfigDef *cdef,
intptr_t value, struct Buffer *err)
#endif
/**
- * pager_validator - Check for config variables that can't be set from the pager
- * @param cs Config items
- * @param cdef Config definition
- * @param value Native value
- * @param err Message for the user
- * @retval CSR_SUCCESS Success
- * @retval CSR_ERR_INVALID Failure
+ * pager_validator - Check for config variables that can't be set from the pager - Implements ::cs_validator
*/
int pager_validator(const struct ConfigSet *cs, const struct ConfigDef *cdef,
intptr_t value, struct Buffer *err)
}
/**
- * multipart_validator - Validate the "show_multipart_alternative" config variable
- * @param cs Config items
- * @param cdef Config definition
- * @param value Native value
- * @param err Message for the user
- * @retval CSR_SUCCESS Success
- * @retval CSR_ERR_INVALID Failure
+ * multipart_validator - Validate the "show_multipart_alternative" config variable - Implements ::cs_validator
*/
int multipart_validator(const struct ConfigSet *cs, const struct ConfigDef *cdef,
intptr_t value, struct Buffer *err)
}
/**
- * reply_validator - Validate the "reply_regex" config variable
- * @param cs Config items
- * @param cdef Config definition
- * @param value Native value
- * @param err Message for the user
- * @retval CSR_SUCCESS Success
- * @retval CSR_ERR_INVALID Failure
+ * reply_validator - Validate the "reply_regex" config variable - Implements ::cs_validator
*/
int reply_validator(const struct ConfigSet *cs, const struct ConfigDef *cdef,
intptr_t value, struct Buffer *err)
}
/**
- * mutt_menu_listener - Listen for config changes affecting the menu
- * @param cs Config items
- * @param he HashElem representing config item
- * @param name Name of the config item
- * @param ev Event type, e.g. #CE_SET
- * @retval true Continue notifying
+ * mutt_menu_listener - Listen for config changes affecting the menu - Implements ::cs_listener
*/
bool mutt_menu_listener(const struct ConfigSet *cs, struct HashElem *he,
const char *name, enum ConfigEvent ev)
}
/**
- * mutt_hist_listener - Listen for config changes affecting the history
- * @param cs Config items
- * @param he HashElem representing config item
- * @param name Name of the config item
- * @param ev Event type, e.g. #CE_SET
- * @retval true Continue notifying
+ * mutt_hist_listener - Listen for config changes affecting the history - Implements ::cs_listener
*/
bool mutt_hist_listener(const struct ConfigSet *cs, struct HashElem *he,
const char *name, enum ConfigEvent ev)
}
/**
- * mutt_log_listener - Listen for config changes affecting the log file
- * @param cs Config items
- * @param he HashElem representing config item
- * @param name Name of the config item
- * @param ev Event type, e.g. #CE_SET
- * @retval true Continue notifying
+ * mutt_log_listener - Listen for config changes affecting the log file - Implements ::cs_listener
*/
bool mutt_log_listener(const struct ConfigSet *cs, struct HashElem *he,
const char *name, enum ConfigEvent ev)