blob: dd1ea010c1065563a12721e6f465640bc485255e [file] [log] [blame]
// Copyright 2015 The Vanadium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
var mercury = require('mercury');
module.exports = addDelegatedEvents;
/*
* Given a list of event names, have mercury's Delegator listenTo them.
*/
function addDelegatedEvents(eventNames) {
var delegator = mercury.Delegator({
defaultEvents: false
});
eventNames.forEach(function(eventName) {
delegator.listenTo(eventName);
});
}