LEFT | RIGHT |
(no file at all) | |
1 'use strict'; | 1 'use strict'; |
2 | 2 |
3 YUI.add('juju-topology', function(Y) { | 3 YUI.add('juju-topology', function(Y) { |
4 var views = Y.namespace('juju.views'), | 4 var views = Y.namespace('juju.views'), |
5 models = Y.namespace('juju.models'), | 5 models = Y.namespace('juju.models'), |
6 d3ns = Y.namespace('d3'); | 6 d3ns = Y.namespace('d3'); |
7 | 7 |
8 /** | 8 /** |
9 * Topology models and renders the SVG of the envionment topology | 9 * Topology models and renders the SVG of the envionment topology |
10 * with its associated behaviors. | 10 * with its associated behaviors. |
(...skipping 13 matching lines...) Expand all Loading... |
24 * @class Topology | 24 * @class Topology |
25 * @namespace views | 25 * @namespace views |
26 **/ | 26 **/ |
27 var Topology = Y.Base.create('Topology', d3ns.Component, [], { | 27 var Topology = Y.Base.create('Topology', d3ns.Component, [], { |
28 initializer: function(options) { | 28 initializer: function(options) { |
29 Topology.superclass.constructor.apply(this, arguments); | 29 Topology.superclass.constructor.apply(this, arguments); |
30 this.options = Y.mix(options || { | 30 this.options = Y.mix(options || { |
31 minZoom: 25, | 31 minZoom: 25, |
32 maxZoom: 200 | 32 maxZoom: 200 |
33 }); | 33 }); |
| 34 |
| 35 // Build a service.id -> BoundingBox map for services. |
| 36 this.service_boxes = {}; |
34 | 37 |
35 this._subscriptions = []; | 38 this._subscriptions = []; |
36 }, | 39 }, |
37 | 40 |
38 /** | 41 /** |
39 * Called by render, conditionally attach container to the DOM if | 42 * Called by render, conditionally attach container to the DOM if |
40 * it isn't already. The framework calls this before module | 43 * it isn't already. The framework calls this before module |
41 * rendering so that d3 Events will have attached DOM elements. If | 44 * rendering so that d3 Events will have attached DOM elements. If |
42 * your application doesn't need this behavior feel free to override. | 45 * your application doesn't need this behavior feel free to override. |
43 * | 46 * |
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
189 'event', | 192 'event', |
190 'juju-templates', | 193 'juju-templates', |
191 'juju-models', | 194 'juju-models', |
192 'juju-env', | 195 'juju-env', |
193 'juju-topology-service', | 196 'juju-topology-service', |
194 'juju-topology-relation', | 197 'juju-topology-relation', |
195 'juju-topology-panzoom', | 198 'juju-topology-panzoom', |
196 'juju-topology-viewport' | 199 'juju-topology-viewport' |
197 ] | 200 ] |
198 }); | 201 }); |
LEFT | RIGHT |