| changeset 293 | fba23fde14ba |
| parent 284 | fa8035885814 |
| child 433 | e457ec945e50 |
| 292:f67047a16084 | 293:fba23fde14ba |
|---|---|
1 "use strict"; |
|
2 |
1 |
3 define(['jquery', 'underscore', 'requtils', 'renderer/baserepresentation'], function ($, _, requtils, BaseRepresentation) { |
2 define(['jquery', 'underscore', 'requtils', 'renderer/baserepresentation'], function ($, _, requtils, BaseRepresentation) { |
4 |
3 'use strict'; |
4 |
|
5 var Utils = requtils.getUtils(); |
5 var Utils = requtils.getUtils(); |
6 |
6 |
7 /* _BaseEditor Begin */ |
7 /* _BaseEditor Begin */ |
8 //var _BaseEditor = Renderer._BaseEditor = Utils.inherit(Renderer._BaseRepresentation); |
8 //var _BaseEditor = Renderer._BaseEditor = Utils.inherit(Renderer._BaseRepresentation); |
9 var _BaseEditor = Utils.inherit(BaseRepresentation); |
9 var _BaseEditor = Utils.inherit(BaseRepresentation); |
15 this.editor_block = new paper.Path(); |
15 this.editor_block = new paper.Path(); |
16 var _pts = _(_.range(8)).map(function() {return [0,0];}); |
16 var _pts = _(_.range(8)).map(function() {return [0,0];}); |
17 this.editor_block.add.apply(this.editor_block, _pts); |
17 this.editor_block.add.apply(this.editor_block, _pts); |
18 this.editor_block.strokeWidth = this.options.tooltip_border_width; |
18 this.editor_block.strokeWidth = this.options.tooltip_border_width; |
19 this.editor_block.strokeColor = this.options.tooltip_border_color; |
19 this.editor_block.strokeColor = this.options.tooltip_border_color; |
20 this.editor_block.opacity = .8; |
20 this.editor_block.opacity = 0.8; |
21 this.editor_$ = $('<div>') |
21 this.editor_$ = $('<div>') |
22 .appendTo(this.renderer.editor_$) |
22 .appendTo(this.renderer.editor_$) |
23 .css({ |
23 .css({ |
24 position: "absolute", |
24 position: "absolute", |
25 opacity: .8 |
25 opacity: 0.8 |
26 }) |
26 }) |
27 .hide(); |
27 .hide(); |
28 }, |
28 }, |
29 destroy: function() { |
29 destroy: function() { |
30 this.editor_block.remove(); |
30 this.editor_block.remove(); |
31 this.editor_$.remove(); |
31 this.editor_$.remove(); |
32 } |
32 } |
33 }); |
33 }); |
34 |
34 |
35 /* _BaseEditor End */ |
35 /* _BaseEditor End */ |
36 |
36 |
37 return _BaseEditor; |
37 return _BaseEditor; |
38 |
38 |
39 }); |
39 }); |