~ubuntu-branches/ubuntu/raring/maas/raring-updates

« back to all changes in this revision

Viewing changes to src/maasserver/static/jslibs/yui/3.4.1/build/node-pluginhost/node-pluginhost.js

  • Committer: Package Import Robot
  • Author(s): Andres Rodriguez
  • Date: 2012-07-03 17:42:37 UTC
  • mfrom: (1.1.13)
  • Revision ID: package-import@ubuntu.com-20120703174237-p8l0keuuznfg721k
Tags: 0.1+bzr709+dfsg-0ubuntu1
* New Upstream release
* debian/control:
  - Depends on python-celery, python-tempita, libjs-yui3-{full,min},
    libjs-raphael
* debian/maas.install:
  - Install apiclient, celeryconfig.py, maas-import-pxe-files, preseeds_v2.
  - Update to install various files from chroot, rather tha manually copy
    them from the source.
* debian/maas.links: symlink celeryconfig.py
* debian/maas.maas-celery.upstart: Add job.
* debian/rules:
  - Install celery upstart job.
  - Do not install jslibs as packages are now used.
  - Drop copying of maas_local_settings_sample.py as source now ships
    a maas_local_settings.py
* debian/patches:
  - 04-maas-http-fix.patch: Drop. Merged upstream.
  - 01-fix-database-settings.patch: Refreshed.
  - 99_enums_js.patch: Added until creation of enum.js / build process
    is fixed.
* debian/maas.postinst: Update bzr version to correctly handle upgrades.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
YUI 3.4.1 (build 4118)
3
 
Copyright 2011 Yahoo! Inc. All rights reserved.
4
 
Licensed under the BSD License.
5
 
http://yuilibrary.com/license/
6
 
*/
7
 
YUI.add('node-pluginhost', function(Y) {
8
 
 
9
 
/**
10
 
 * @module node
11
 
 * @submodule node-pluginhost
12
 
 */
13
 
 
14
 
/**
15
 
 * Registers plugins to be instantiated at the class level (plugins
16
 
 * which should be plugged into every instance of Node by default).
17
 
 *
18
 
 * @method plug
19
 
 * @static
20
 
 * @for Node
21
 
 * @param {Function | Array} plugin Either the plugin class, an array of plugin classes or an array of objects (with fn and cfg properties defined)
22
 
 * @param {Object} config (Optional) If plugin is the plugin class, the configuration for the plugin
23
 
 */
24
 
Y.Node.plug = function() {
25
 
    var args = Y.Array(arguments);
26
 
    args.unshift(Y.Node);
27
 
    Y.Plugin.Host.plug.apply(Y.Base, args);
28
 
    return Y.Node;
29
 
};
30
 
 
31
 
/**
32
 
 * Unregisters any class level plugins which have been registered by the Node
33
 
 *
34
 
 * @method unplug
35
 
 * @static
36
 
 *
37
 
 * @param {Function | Array} plugin The plugin class, or an array of plugin classes
38
 
 */
39
 
Y.Node.unplug = function() {
40
 
    var args = Y.Array(arguments);
41
 
    args.unshift(Y.Node);
42
 
    Y.Plugin.Host.unplug.apply(Y.Base, args);
43
 
    return Y.Node;
44
 
};
45
 
 
46
 
Y.mix(Y.Node, Y.Plugin.Host, false, null, 1);
47
 
 
48
 
// allow batching of plug/unplug via NodeList
49
 
// doesn't use NodeList.importMethod because we need real Nodes (not tmpNode)
50
 
Y.NodeList.prototype.plug = function() {
51
 
    var args = arguments;
52
 
    Y.NodeList.each(this, function(node) {
53
 
        Y.Node.prototype.plug.apply(Y.one(node), args);
54
 
    });
55
 
};
56
 
 
57
 
Y.NodeList.prototype.unplug = function() {
58
 
    var args = arguments;
59
 
    Y.NodeList.each(this, function(node) {
60
 
        Y.Node.prototype.unplug.apply(Y.one(node), args);
61
 
    });
62
 
};
63
 
 
64
 
 
65
 
}, '3.4.1' ,{requires:['node-base', 'pluginhost']});