make layer opaque on click
This commit is contained in:
parent
a8a797e669
commit
444fabdb39
3 changed files with 22 additions and 5 deletions
|
@ -34,8 +34,8 @@ Dialog
|
||||||
*/
|
*/
|
||||||
|
|
||||||
.OxThemeClassic .OxDialog {
|
.OxThemeClassic .OxDialog {
|
||||||
-moz-box-shadow: 0 0 8px rgba(0, 0, 0, 0.75);
|
-moz-box-shadow: 0 2px 4px rgba(0, 0, 0, 0.75);
|
||||||
-webkit-box-shadow: 0 0 8px rgba(0, 0, 0, 0.75);
|
-webkit-box-shadow: 0 2px 4px rgba(0, 0, 0, 0.75);
|
||||||
}
|
}
|
||||||
|
|
||||||
.OxThemeClassic .OxDialog .OxBar {
|
.OxThemeClassic .OxDialog .OxBar {
|
||||||
|
|
|
@ -66,6 +66,7 @@ Dialog
|
||||||
//right: 0;
|
//right: 0;
|
||||||
//bottom: 0;
|
//bottom: 0;
|
||||||
//margin: auto;
|
//margin: auto;
|
||||||
|
z-index: 11;
|
||||||
-moz-border-radius: 8px;
|
-moz-border-radius: 8px;
|
||||||
-webkit-border-radius: 8px;
|
-webkit-border-radius: 8px;
|
||||||
}
|
}
|
||||||
|
@ -396,6 +397,8 @@ Layers
|
||||||
position: absolute;
|
position: absolute;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
background: rgb(0, 0, 0);
|
||||||
|
opacity: 0;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
z-index: 10;
|
z-index: 10;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1299,8 +1299,10 @@ requires
|
||||||
.appendTo(that.$buttonsbar);
|
.appendTo(that.$buttonsbar);
|
||||||
});
|
});
|
||||||
that.$buttons[0].focus();
|
that.$buttons[0].focus();
|
||||||
that.$layer = new Ox.Element()
|
that.$layer = new Ox.Element() // fixme: Layer widget, that would handle click?
|
||||||
.addClass("OxLayer");
|
.addClass("OxLayer")
|
||||||
|
.mousedown(mousedownLayer)
|
||||||
|
.mouseup(mouseupLayer);
|
||||||
|
|
||||||
function center() {
|
function center() {
|
||||||
that.css({
|
that.css({
|
||||||
|
@ -1348,6 +1350,18 @@ requires
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function mousedownLayer() {
|
||||||
|
that.$layer.stop().animate({
|
||||||
|
opacity: 0.5
|
||||||
|
}, 100);
|
||||||
|
}
|
||||||
|
|
||||||
|
function mouseupLayer() {
|
||||||
|
that.$layer.stop().animate({
|
||||||
|
opacity: 0
|
||||||
|
}, 100);
|
||||||
|
}
|
||||||
|
|
||||||
function reset() {
|
function reset() {
|
||||||
that.width(self.options.width);
|
that.width(self.options.width);
|
||||||
that.height(self.options.height);
|
that.height(self.options.height);
|
||||||
|
@ -1432,7 +1446,7 @@ requires
|
||||||
reset();
|
reset();
|
||||||
that.css({
|
that.css({
|
||||||
opacity: 0
|
opacity: 0
|
||||||
}).appendTo(that.$layer).animate({
|
}).appendTo($body).animate({
|
||||||
opacity: 1
|
opacity: 1
|
||||||
}, 200);
|
}, 200);
|
||||||
return that;
|
return that;
|
||||||
|
|
Loading…
Reference in a new issue