Rename libcss_node_data key for libdom node user data.
This commit is contained in:
parent
e4c50bd58a
commit
fabc086d4a
11
css/select.c
11
css/select.c
|
@ -223,8 +223,9 @@ static void nscss_dom_user_data_handler(dom_node_operation operation,
|
|||
css_error error;
|
||||
bool match;
|
||||
|
||||
if (lwc_string_isequal(corestring_dom_key_css_bloom, key, &match) !=
|
||||
lwc_error_ok || match == false || data == NULL) {
|
||||
if (lwc_string_isequal(corestring_dom___ns_key_libcss_node_data,
|
||||
key, &match) != lwc_error_ok || match == false ||
|
||||
data == NULL) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -3079,7 +3080,8 @@ css_error set_libcss_node_data(void *pw, void *node, void *libcss_node_data)
|
|||
void *old_node_data;
|
||||
|
||||
/* Set this node's node data */
|
||||
err = dom_node_set_user_data(n, corestring_dom_key_css_bloom,
|
||||
err = dom_node_set_user_data(n,
|
||||
corestring_dom___ns_key_libcss_node_data,
|
||||
libcss_node_data, nscss_dom_user_data_handler,
|
||||
(void *) &old_node_data);
|
||||
if (err != DOM_NO_ERR) {
|
||||
|
@ -3097,7 +3099,8 @@ css_error get_libcss_node_data(void *pw, void *node, void **libcss_node_data)
|
|||
dom_exception err;
|
||||
|
||||
/* Get this node's node data */
|
||||
err = dom_node_get_user_data(n, corestring_dom_key_css_bloom,
|
||||
err = dom_node_get_user_data(n,
|
||||
corestring_dom___ns_key_libcss_node_data,
|
||||
libcss_node_data);
|
||||
if (err != DOM_NO_ERR) {
|
||||
return CSS_NOMEM;
|
||||
|
|
|
@ -174,7 +174,6 @@ dom_string *corestring_dom_invalid;
|
|||
dom_string *corestring_dom_keydown;
|
||||
dom_string *corestring_dom_keypress;
|
||||
dom_string *corestring_dom_keyup;
|
||||
dom_string *corestring_dom_key_css_bloom;
|
||||
dom_string *corestring_dom_link;
|
||||
dom_string *corestring_dom_load;
|
||||
dom_string *corestring_dom_loadeddata;
|
||||
|
@ -233,6 +232,7 @@ dom_string *corestring_dom_volumechange;
|
|||
dom_string *corestring_dom_vspace;
|
||||
dom_string *corestring_dom_waiting;
|
||||
dom_string *corestring_dom_width;
|
||||
dom_string *corestring_dom___ns_key_libcss_node_data;
|
||||
|
||||
|
||||
/*
|
||||
|
@ -405,7 +405,6 @@ void corestrings_fini(void)
|
|||
CSS_DOM_STRING_UNREF(keydown);
|
||||
CSS_DOM_STRING_UNREF(keypress);
|
||||
CSS_DOM_STRING_UNREF(keyup);
|
||||
CSS_DOM_STRING_UNREF(key_css_bloom);
|
||||
CSS_DOM_STRING_UNREF(link);
|
||||
CSS_DOM_STRING_UNREF(load);
|
||||
CSS_DOM_STRING_UNREF(loadeddata);
|
||||
|
@ -464,6 +463,7 @@ void corestrings_fini(void)
|
|||
CSS_DOM_STRING_UNREF(vspace);
|
||||
CSS_DOM_STRING_UNREF(waiting);
|
||||
CSS_DOM_STRING_UNREF(width);
|
||||
CSS_DOM_STRING_UNREF(__ns_key_libcss_node_data);
|
||||
#undef CSS_DOM_STRING_UNREF
|
||||
}
|
||||
|
||||
|
@ -724,6 +724,7 @@ nserror corestrings_init(void)
|
|||
CSS_DOM_STRING_INTERN(vspace);
|
||||
CSS_DOM_STRING_INTERN(waiting);
|
||||
CSS_DOM_STRING_INTERN(width);
|
||||
CSS_DOM_STRING_INTERN(__ns_key_libcss_node_data);
|
||||
#undef CSS_DOM_STRING_INTERN
|
||||
|
||||
exc = dom_string_create_interned((const uint8_t *) "text/javascript",
|
||||
|
|
|
@ -180,7 +180,6 @@ extern struct dom_string *corestring_dom_invalid;
|
|||
extern struct dom_string *corestring_dom_keydown;
|
||||
extern struct dom_string *corestring_dom_keypress;
|
||||
extern struct dom_string *corestring_dom_keyup;
|
||||
extern struct dom_string *corestring_dom_key_css_bloom;
|
||||
extern struct dom_string *corestring_dom_link;
|
||||
extern struct dom_string *corestring_dom_load;
|
||||
extern struct dom_string *corestring_dom_loadeddata;
|
||||
|
@ -239,6 +238,7 @@ extern struct dom_string *corestring_dom_volumechange;
|
|||
extern struct dom_string *corestring_dom_vspace;
|
||||
extern struct dom_string *corestring_dom_waiting;
|
||||
extern struct dom_string *corestring_dom_width;
|
||||
extern struct dom_string *corestring_dom___ns_key_libcss_node_data;
|
||||
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue