Commit e2db81db authored by Alexander Cooper's avatar Alexander Cooper Committed by Commit Bot

Remove unused ScreenOrientation code in XRSession

Anything that actually used this code was removed a while ago, but a few
references remained.

Fixed: 840346
Change-Id: Ic5c42dd85dcfa446757a45be8e82a16179080a6f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2233600
Commit-Queue: Alexander Cooper <alcooper@chromium.org>
Commit-Queue: Brandon Jones <bajones@chromium.org>
Auto-Submit: Alexander Cooper <alcooper@chromium.org>
Reviewed-by: default avatarBrandon Jones <bajones@chromium.org>
Cr-Commit-Position: refs/heads/master@{#775766}
parent 2bfcd397
...@@ -27,7 +27,6 @@ ...@@ -27,7 +27,6 @@
#include "third_party/blink/renderer/core/resize_observer/resize_observer.h" #include "third_party/blink/renderer/core/resize_observer/resize_observer.h"
#include "third_party/blink/renderer/core/resize_observer/resize_observer_entry.h" #include "third_party/blink/renderer/core/resize_observer/resize_observer_entry.h"
#include "third_party/blink/renderer/modules/event_target_modules.h" #include "third_party/blink/renderer/modules/event_target_modules.h"
#include "third_party/blink/renderer/modules/screen_orientation/screen_orientation.h"
#include "third_party/blink/renderer/modules/xr/type_converters.h" #include "third_party/blink/renderer/modules/xr/type_converters.h"
#include "third_party/blink/renderer/modules/xr/xr_anchor_set.h" #include "third_party/blink/renderer/modules/xr/xr_anchor_set.h"
#include "third_party/blink/renderer/modules/xr/xr_bounded_reference_space.h" #include "third_party/blink/renderer/modules/xr/xr_bounded_reference_space.h"
...@@ -1711,16 +1710,6 @@ void XRSession::UpdateCanvasDimensions(Element* element) { ...@@ -1711,16 +1710,6 @@ void XRSession::UpdateCanvasDimensions(Element* element) {
update_views_next_frame_ = true; update_views_next_frame_ = true;
output_width_ = element->OffsetWidth() * devicePixelRatio; output_width_ = element->OffsetWidth() * devicePixelRatio;
output_height_ = element->OffsetHeight() * devicePixelRatio; output_height_ = element->OffsetHeight() * devicePixelRatio;
int output_angle = 0;
// TODO(crbug.com/836948): handle square canvases.
// TODO(crbug.com/840346): we should not need to use ScreenOrientation here.
ScreenOrientation* orientation = ScreenOrientation::Create(window);
if (orientation) {
output_angle = orientation->angle();
DVLOG(2) << __func__ << ": got angle=" << output_angle;
}
if (render_state_->baseLayer()) { if (render_state_->baseLayer()) {
render_state_->baseLayer()->OnResize(); render_state_->baseLayer()->OnResize();
......
...@@ -767,11 +767,6 @@ class MockRuntime extends EventTarget { ...@@ -767,11 +767,6 @@ class MockRuntime extends EventTarget {
this.dataProviderBinding_.close(); this.dataProviderBinding_.close();
} }
updateSessionGeometry(frame_size, display_rotation) {
// This function must exist to ensure that calls to it do not crash, but we
// do not have any use for this data at present.
}
// XREnvironmentIntegrationProvider implementation: // XREnvironmentIntegrationProvider implementation:
subscribeToHitTest(nativeOriginInformation, entityTypes, ray) { subscribeToHitTest(nativeOriginInformation, entityTypes, ray) {
if (!this.supportedModes_.includes(device.mojom.XRSessionMode.kImmersiveAr)) { if (!this.supportedModes_.includes(device.mojom.XRSessionMode.kImmersiveAr)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment