mirror of
https://github.com/overte-org/overte.git
synced 2025-08-06 13:49:46 +02:00
Merge branch 'master' of https://github.com/highfidelity/hifi into reset-hud-on-driving
This commit is contained in:
commit
22c8407e4a
2 changed files with 9 additions and 3 deletions
|
@ -178,7 +178,10 @@ var NON_LINEAR_DIVISOR = 2;
|
||||||
var MINIMUM_SEEK_DISTANCE = 0.01;
|
var MINIMUM_SEEK_DISTANCE = 0.01;
|
||||||
function updateSeeking() {
|
function updateSeeking() {
|
||||||
if (!Reticle.visible || isShakingMouse()) {
|
if (!Reticle.visible || isShakingMouse()) {
|
||||||
isSeeking = true;
|
if (!isSeeking) {
|
||||||
|
print('Start seeking mouse.');
|
||||||
|
isSeeking = true;
|
||||||
|
}
|
||||||
} // e.g., if we're about to turn it on with first movement.
|
} // e.g., if we're about to turn it on with first movement.
|
||||||
if (!isSeeking) {
|
if (!isSeeking) {
|
||||||
return;
|
return;
|
||||||
|
@ -203,6 +206,7 @@ function updateSeeking() {
|
||||||
}
|
}
|
||||||
var okX = !updateDimension('x'), okY = !updateDimension('y'); // Evaluate both. Don't short-circuit.
|
var okX = !updateDimension('x'), okY = !updateDimension('y'); // Evaluate both. Don't short-circuit.
|
||||||
if (okX && okY) {
|
if (okX && okY) {
|
||||||
|
print('Finished seeking mouse');
|
||||||
isSeeking = false;
|
isSeeking = false;
|
||||||
} else {
|
} else {
|
||||||
Reticle.setPosition(copy); // Not setReticlePosition
|
Reticle.setPosition(copy); // Not setReticlePosition
|
||||||
|
@ -444,7 +448,7 @@ function update() {
|
||||||
updateVisualization(controllerPosition, controllerDirection, hudPoint3d, hudPoint2d);
|
updateVisualization(controllerPosition, controllerDirection, hudPoint3d, hudPoint2d);
|
||||||
}
|
}
|
||||||
|
|
||||||
var UPDATE_INTERVAL = 20; // milliseconds. Script.update is too frequent.
|
var UPDATE_INTERVAL = 50; // milliseconds. Script.update is too frequent.
|
||||||
var updater = Script.setInterval(update, UPDATE_INTERVAL);
|
var updater = Script.setInterval(update, UPDATE_INTERVAL);
|
||||||
Script.scriptEnding.connect(function () {
|
Script.scriptEnding.connect(function () {
|
||||||
Script.clearInterval(updater);
|
Script.clearInterval(updater);
|
||||||
|
|
|
@ -352,7 +352,9 @@ var toolBar = (function() {
|
||||||
gridTool.setVisible(true);
|
gridTool.setVisible(true);
|
||||||
grid.setEnabled(true);
|
grid.setEnabled(true);
|
||||||
propertiesTool.setVisible(true);
|
propertiesTool.setVisible(true);
|
||||||
Window.setFocus();
|
// Not sure what the following was meant to accomplish, but it currently causes
|
||||||
|
// everybody else to think that Interface has lost focus overall. fogbugzid:558
|
||||||
|
// Window.setFocus();
|
||||||
}
|
}
|
||||||
that.showTools(isActive);
|
that.showTools(isActive);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue