Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(133)

Unified Diff: chrome/browser/resources/vr_shell/vr_shell_ui_api.js

Issue 2433253002: Add passive and FOV-locked properties to UI elements. (Closed)
Patch Set: Address nits. Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/android/vr_shell/vr_shell.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/vr_shell/vr_shell_ui_api.js
diff --git a/chrome/browser/resources/vr_shell/vr_shell_ui_api.js b/chrome/browser/resources/vr_shell/vr_shell_ui_api.js
index 085af162bf2600f6efc5969974201dd2424f0cea..e90757e343bf59fd9639aa12ffd0d8d8d2251774 100644
--- a/chrome/browser/resources/vr_shell/vr_shell_ui_api.js
+++ b/chrome/browser/resources/vr_shell/vr_shell_ui_api.js
@@ -163,6 +163,21 @@ var api = (function() {
setVisible(visible) {
this.visible = !!visible;
}
+
+ /**
+ * Hit-testable implies that the reticle will hit the element, if visible.
+ */
+ setHitTestable(testable) {
+ this.hitTestable = !!testable;
+ }
+
+ /**
+ * Causes an element to be rendered relative to the field of view, rather
+ * than the scene. Elements locked in this way should not have a parent.
+ */
+ setLockToFieldOfView(locked) {
+ this.lockToFov = !!locked;
+ }
};
/**
« no previous file with comments | « chrome/browser/android/vr_shell/vr_shell.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698