mirror of
https://github.com/overte-org/overte.git
synced 2025-04-24 14:33:26 +02:00
constrain toolbar based on setting. (ui for settings to come.)
This commit is contained in:
parent
8eb6699420
commit
f3d4821579
1 changed files with 4 additions and 3 deletions
|
@ -51,8 +51,9 @@ OriginalDesktop.Desktop {
|
|||
Toolbar {
|
||||
id: sysToolbar;
|
||||
objectName: "com.highfidelity.interface.toolbar.system";
|
||||
// Literal 50 is overwritten by settings from previous session, and sysToolbar.x comes from settings.
|
||||
x: settings.firstRun ? (desktop.width - sysToolbar.width) / 2 : sysToolbar.x;
|
||||
anchors.horizontalCenter: settings.systemToolbarHorizontalConstraint ? desktop.horizontalCenter : undefined;
|
||||
// Literal 50 is overwritten by settings from previous session, and sysToolbar.x comes from settings when not constrained.
|
||||
x: sysToolbar.x
|
||||
y: 50
|
||||
}
|
||||
property var toolbars: (function (map) { // answer dictionary preloaded with sysToolbar
|
||||
|
@ -61,7 +62,7 @@ OriginalDesktop.Desktop {
|
|||
|
||||
Settings {
|
||||
id: settings
|
||||
property bool firstRun: true
|
||||
property bool systemToolbarHorizontalConstraint: true
|
||||
}
|
||||
Component.onCompleted: {
|
||||
WebEngine.settings.javascriptCanOpenWindows = true;
|
||||
|
|
Loading…
Reference in a new issue