summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorDaniel Silverstone <dsilvers@digital-scurf.org>2015-11-22 14:50:35 +0000
committerDaniel Silverstone <dsilvers@digital-scurf.org>2015-11-22 14:50:35 +0000
commitb42a910ed91c91da71e53b4efb9889aa46938aee (patch)
treef0f60fc005a0545ddfb4328ac40d8ffc48fe054d /utils
parent9fe01f09c879bd75c369ea064be519adaf3d9837 (diff)
downloadnetsurf-b42a910ed91c91da71e53b4efb9889aa46938aee.tar.gz
netsurf-b42a910ed91c91da71e53b4efb9889aa46938aee.tar.bz2
Ensure that those events listed in 8.1.5.2 as forwarded from body to window, don't get registered for listeners on body
Diffstat (limited to 'utils')
-rw-r--r--utils/corestrings.c22
-rw-r--r--utils/corestrings.h9
2 files changed, 31 insertions, 0 deletions
diff --git a/utils/corestrings.c b/utils/corestrings.c
index c263565b0..493dace81 100644
--- a/utils/corestrings.c
+++ b/utils/corestrings.c
@@ -269,6 +269,12 @@ dom_string *corestring_dom_radio;
dom_string *corestring_dom_checkbox;
dom_string *corestring_dom_file;
dom_string *corestring_dom_on;
+dom_string *corestring_dom_onblur;
+dom_string *corestring_dom_onerror;
+dom_string *corestring_dom_onfocus;
+dom_string *corestring_dom_onload;
+dom_string *corestring_dom_onresize;
+dom_string *corestring_dom_onscroll;
dom_string *corestring_dom___ns_key_box_node_data;
dom_string *corestring_dom___ns_key_libcss_node_data;
dom_string *corestring_dom___ns_key_file_name_node_data;
@@ -544,7 +550,15 @@ void corestrings_fini(void)
CSS_DOM_STRING_UNREF(radio);
CSS_DOM_STRING_UNREF(checkbox);
CSS_DOM_STRING_UNREF(file);
+ /* DOM event prefix */
CSS_DOM_STRING_UNREF(on);
+ /* DOM events forwarded from body to window */
+ CSS_DOM_STRING_UNREF(onblur);
+ CSS_DOM_STRING_UNREF(onerror);
+ CSS_DOM_STRING_UNREF(onfocus);
+ CSS_DOM_STRING_UNREF(onload);
+ CSS_DOM_STRING_UNREF(onresize);
+ CSS_DOM_STRING_UNREF(onscroll);
/* DOM userdata keys, not really CSS */
CSS_DOM_STRING_UNREF(__ns_key_box_node_data);
CSS_DOM_STRING_UNREF(__ns_key_libcss_node_data);
@@ -863,7 +877,15 @@ nserror corestrings_init(void)
CSS_DOM_STRING_INTERN(radio);
CSS_DOM_STRING_INTERN(checkbox);
CSS_DOM_STRING_INTERN(file);
+ /* DOM event prefix */
CSS_DOM_STRING_INTERN(on);
+ /* DOM events forwarded from body to window */
+ CSS_DOM_STRING_INTERN(onblur);
+ CSS_DOM_STRING_INTERN(onerror);
+ CSS_DOM_STRING_INTERN(onfocus);
+ CSS_DOM_STRING_INTERN(onload);
+ CSS_DOM_STRING_INTERN(onresize);
+ CSS_DOM_STRING_INTERN(onscroll);
/* DOM userdata keys, not really CSS */
CSS_DOM_STRING_INTERN(__ns_key_box_node_data);
CSS_DOM_STRING_INTERN(__ns_key_libcss_node_data);
diff --git a/utils/corestrings.h b/utils/corestrings.h
index c72e8b012..4913e73ae 100644
--- a/utils/corestrings.h
+++ b/utils/corestrings.h
@@ -284,7 +284,16 @@ extern struct dom_string *corestring_dom_image;
extern struct dom_string *corestring_dom_radio;
extern struct dom_string *corestring_dom_checkbox;
extern struct dom_string *corestring_dom_file;
+/* Event prefix */
extern struct dom_string *corestring_dom_on;
+/* These are the event attributes which forward from body to window */
+extern struct dom_string *corestring_dom_onblur;
+extern struct dom_string *corestring_dom_onerror;
+extern struct dom_string *corestring_dom_onfocus;
+extern struct dom_string *corestring_dom_onload;
+extern struct dom_string *corestring_dom_onresize;
+extern struct dom_string *corestring_dom_onscroll;
+
/* DOM userdata keys */
extern struct dom_string *corestring_dom___ns_key_box_node_data;
extern struct dom_string *corestring_dom___ns_key_libcss_node_data;