Skip to content

Commit e258186

Browse files
committed
Simple modeas default in App.Light
1 parent 5230484 commit e258186

File tree

3 files changed

+16
-6
lines changed

3 files changed

+16
-6
lines changed

‎Source/App/Dom.js‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,13 @@ declare( 'LibCanvas.App.Dom',{
4646
this.name=this.settings.get('name')||'';
4747
this.createSize();
4848
this.createElement();
49-
this.zIndex=this.settings.get('zIndex')||0;
5049
},
5150

5251
setzIndex(z){
5352
this.z=z;
54-
this.element.css('zIndex',z);
53+
if(!this.container.isSimple){
54+
this.element.css('zIndex',z);
55+
}
5556
},
5657

5758
getzIndex(){
@@ -134,6 +135,8 @@ declare( 'LibCanvas.App.Dom',{
134135
.attr({'data-name': this.name})
135136
.css({'position' : 'absolute'})
136137
.appendTo(this.container.bounds);
138+
139+
this.zIndex=this.settings.get('zIndex')||0;
137140
}
138141
}
139142
});

‎Source/App/Light/Light.js‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,15 @@ declare( 'LibCanvas.App.Light',{
2828
varmouse,mouseHandler;
2929

3030
this.settings=newSettings({
31-
size : Size(size),
31+
size : Size.from(size),
3232
name : 'main',
3333
mouse : true,
3434
invoke : false,
35+
simple : true,
3536
appendTo: 'body',
3637
intersection: 'auto'
3738
}).set(settings||{});
39+
3840
this.app=newApp(this.settings.subset(['size','appendTo','simple']));
3941
this.layer=this.app.createLayer(this.settings.subset(['name','invoke','intersection']));
4042
if(this.settings.get('mouse')===true){

‎libcanvas-full-compiled.js‎

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -492,12 +492,13 @@ declare( 'LibCanvas.App.Dom',{
492492
this.name=this.settings.get('name')||'';
493493
this.createSize();
494494
this.createElement();
495-
this.zIndex=this.settings.get('zIndex')||0;
496495
},
497496

498497
setzIndex(z){
499498
this.z=z;
500-
this.element.css('zIndex',z);
499+
if(!this.container.isSimple){
500+
this.element.css('zIndex',z);
501+
}
501502
},
502503

503504
getzIndex(){
@@ -580,6 +581,8 @@ declare( 'LibCanvas.App.Dom',{
580581
.attr({'data-name': this.name})
581582
.css({'position' : 'absolute'})
582583
.appendTo(this.container.bounds);
584+
585+
this.zIndex=this.settings.get('zIndex')||0;
583586
}
584587
}
585588
});
@@ -6618,13 +6621,15 @@ declare( 'LibCanvas.App.Light',{
66186621
varmouse,mouseHandler;
66196622

66206623
this.settings=newSettings({
6621-
size : Size(size),
6624+
size : Size.from(size),
66226625
name : 'main',
66236626
mouse : true,
66246627
invoke : false,
6628+
simple : true,
66256629
appendTo: 'body',
66266630
intersection: 'auto'
66276631
}).set(settings||{});
6632+
66286633
this.app=newApp(this.settings.subset(['size','appendTo','simple']));
66296634
this.layer=this.app.createLayer(this.settings.subset(['name','invoke','intersection']));
66306635
if(this.settings.get('mouse')===true){

0 commit comments

Comments
(0)