mirror of
https://github.com/overte-org/overte.git
synced 2025-04-14 06:29:03 +02:00
Tablet goto button now properly tracks address bar shown state
This commit is contained in:
parent
353b38286a
commit
e30d77eba1
1 changed files with 1 additions and 3 deletions
|
@ -14,7 +14,6 @@
|
|||
(function() { // BEGIN LOCAL_SCOPE
|
||||
|
||||
var tablet = Tablet.getTablet("com.highfidelity.interface.tablet.system");
|
||||
var isActive = false
|
||||
var button = tablet.addButton({
|
||||
icon: "icons/tablet-icons/goto-i.svg",
|
||||
text:"GOTO"
|
||||
|
@ -22,14 +21,13 @@ var button = tablet.addButton({
|
|||
|
||||
|
||||
function onAddressBarShown(visible) {
|
||||
button.editProperties({isActive: visible});
|
||||
}
|
||||
|
||||
function setActive(active) {
|
||||
isActive = active;
|
||||
}
|
||||
function onClicked(){
|
||||
setActive(!isActive);
|
||||
button.editProperties({isActive: isActive});
|
||||
DialogsManager.toggleAddressBar();
|
||||
}
|
||||
button.clicked.connect(onClicked);
|
||||
|
|
Loading…
Reference in a new issue