Lines Matching refs:event

30      *   // safe to call add_*_callback() to register event handlers.
97 on_event(window, 'message', function(event) {
98 if (event.data && event.data.type === "getmessages" && event.source) {
105 event.source.postMessage(this_obj.dispatched_messages[i], "*");
359 // Shared workers receive message ports via the 'onconnect' event for
388 function(event) {
389 if (event.data && event.data.type && event.data.type === "connect") {
390 this_obj._add_message_port(event.source);
394 // The oninstall event is received after the service worker script and
396 // equivalent of an onload event for a document. All tests should have
397 // been added by the time this event is received, thus it's not
398 // necessary to wait until the onactivate event. However, tests for
399 // installed service workers need another event which is equivalent to
400 // the onload event because oninstall is fired only on installation. The
401 // onmessage event is used for that purpose since tests using
403 // PostMessage. If the onmessage event is triggered on the service
447 * event for us to use to set up the test environment; so, instead, this method
890 * `EventWatcher` will assert if an event occurs while there is no `wait_for`
891 * created Promise waiting to be fulfilled, or if the event is of a different type
917 'Not expecting event, but got ' + evt.type + ' event');
919 'Expected ' + waitingFor.types[0] + ' event, but got ' +
920 evt.type + ' event instead');
927 // Pop first event from array
947 * Returns a Promise that will resolve after the specified event or
968 return Promise.reject('Already waiting for an event or events');
1187 * Register a function as a DOM event listener to the
1188 * given object for the event bubbling phase.
1191 * @param {string} event - Event name
1194 function on_event(object, event, callback)
1196 object.addEventListener(event, callback, false);
2343 * not taken e.g. that an error event isn't fired.