Merge pull request #4176 from huffman/fix-inspect

Fix inspect + editEntities cameras from clashing
This commit is contained in:
Brad Hefta-Gaub 2015-01-27 13:05:33 -08:00
commit 0c4dc4100d
2 changed files with 7 additions and 1 deletions

View file

@ -158,6 +158,11 @@ function handleModes() {
avatarOrientation.w != MyAvatar.orientation.w)) {
newMode = noMode;
}
if (mode == noMode && newMode != noMode && Camera.mode == "independent") {
newMode = noMode;
}
// if leaving noMode
if (mode == noMode && newMode != noMode) {
saveCameraState();

View file

@ -80,7 +80,8 @@ CameraManager = function() {
that.lastMousePosition = { x: 0, y: 0 };
that.enable = function() {
if (that.enabled) return;
if (Camera.mode == "independent" || that.enabled) return;
that.enabled = true;
that.mode = MODE_INACTIVE;