fix compatibility issue for new sciter

This commit is contained in:
rustdesk 2021-07-26 01:50:47 +08:00
parent 879c300563
commit 9a86a595ff
3 changed files with 13 additions and 4 deletions

View File

@ -19,6 +19,12 @@ header #screen {
color: color(light-text);
}
@media platform == "OSX" {
header #screen {
line-height: 11px;
}
}
header #secure {
position: absolute;
left: -10px;
@ -64,4 +70,4 @@ span#fullscreen.active {
button:disabled {
opacity: 0.3;
}
}

View File

@ -168,11 +168,15 @@ class Header: Reactor.Component {
var scale = 16. / h;
var screens = pi.displays.map(function(d, i) {
var min_wh = d.width > d.height ? d.height : d.width;
var fs = min_wh * 0.9 * scale;
var style = "width:" + (d.width * scale) + "px;" +
"height:" + (d.height * scale) + "px;" +
"left:" + ((d.x - x0) * scale) + "px;" +
"top:" + ((d.y - y0) * scale) + "px;" +
"font-size:" + (min_wh * 0.9 * scale) + "px;";
"font-size:" + fs + "px;";
if (is_osx) {
style += "line-height:" + fs + "px;";
}
return <div style={style} class={pi.current_display == i ? "current" : ""}>{i+1}</div>;
});

View File

@ -14,7 +14,6 @@ video#handler {
size: *;
margin: *;
foreground-size: contain;
position: relative;
}
img#cursor {
@ -34,4 +33,4 @@ table#remote-folder-view {
table#local-folder-view {
context-menu: selector(menu#local-folder-view);
}
}