File tree 1 file changed +11
-10
lines changed
1 file changed +11
-10
lines changed Original file line number Diff line number Diff line change 27
27
var $turtle = $ ( '<canvas class="turtle" width="' + o . width + '" height="' + o . height + '" style="position: absolute; top:0px; left:0px;" />' ) ;
28
28
var $drawing = $ ( '<canvas class="drawing" width="' + o . width + '" height="' + o . height + '" style="position: absolute; top:0px; left:0px;" />' ) ;
29
29
$wrapper . append ( $turtle ) . append ( $drawing ) ;
30
+ $this . append ( $wrapper ) ;
30
31
31
32
// Make a control area, append it in
32
- var $controls = $ ( '<ul class="controls" />' ) ;
33
- $controls . append ( '<li>Junk Control</li>' ) ;
34
- $controls . append ( '<li>Junk Control</li>' ) ;
35
- $controls . append ( '<li>Junk Control</li>' ) ;
36
-
37
- // Push the pieces into our current item
38
- $this . append ( $wrapper ) ;
39
- $this . append ( $controls ) ;
33
+ if ( o . controls ) {
34
+ var $controls = $ ( '<ul class="controls" />' ) ;
35
+ $controls . append ( '<li>Junk Control</li>' ) ;
36
+ $controls . append ( '<li>Junk Control</li>' ) ;
37
+ $controls . append ( '<li>Junk Control</li>' ) ;
38
+ $this . append ( $controls ) ;
39
+ } // if (o.controls)
40
40
} ) ; // return this.each(function()
41
41
} ; // $.fn.LOGO = function(options)
42
42
43
43
// ===== DEFAULTS =====
44
44
$ . fn . LOGO . defaults = {
45
- 'width' : 500 ,
46
- 'height' : 500
45
+ 'width' : 500 ,
46
+ 'height' : 500 ,
47
+ 'controls' : true
47
48
} ;
48
49
49
50
// ===== FUNCTIONS =====
You can’t perform that action at this time.
0 commit comments