#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "chrome/browser/vr/test/mock_xr_device_hook_base.h"
#include "content/public/test/xr_test_utils.h"
#include "device/vr/public/mojom/isolated_xr_service.mojom.h"
#include "mojo/public/cpp/bindings/sync_call_restrictions.h"
device_test::mojom::ControllerRole DeviceToMojoControllerRole(
device::ControllerRole role) { … }
device_test::mojom::ControllerFrameDataPtr DeviceToMojoControllerFrameData(
const device::ControllerFrameData& data) { … }
MockXRDeviceHookBase::MockXRDeviceHookBase()
: … { … }
MockXRDeviceHookBase::~MockXRDeviceHookBase() { … }
void MockXRDeviceHookBase::StopHooking() { … }
void MockXRDeviceHookBase::OnFrameSubmitted(
std::vector<device_test::mojom::ViewDataPtr> views,
device_test::mojom::XRTestHook::OnFrameSubmittedCallback callback) { … }
void MockXRDeviceHookBase::WaitGetDeviceConfig(
device_test::mojom::XRTestHook::WaitGetDeviceConfigCallback callback) { … }
void MockXRDeviceHookBase::WaitGetPresentingPose(
device_test::mojom::XRTestHook::WaitGetPresentingPoseCallback callback) { … }
void MockXRDeviceHookBase::WaitGetMagicWindowPose(
device_test::mojom::XRTestHook::WaitGetMagicWindowPoseCallback callback) { … }
void MockXRDeviceHookBase::WaitGetControllerRoleForTrackedDeviceIndex(
unsigned int index,
device_test::mojom::XRTestHook::
WaitGetControllerRoleForTrackedDeviceIndexCallback callback) { … }
void MockXRDeviceHookBase::WaitGetTrackedDeviceClass(
unsigned int index,
device_test::mojom::XRTestHook::WaitGetTrackedDeviceClassCallback
callback) { … }
void MockXRDeviceHookBase::WaitGetControllerData(
unsigned int index,
device_test::mojom::XRTestHook::WaitGetControllerDataCallback callback) { … }
void MockXRDeviceHookBase::WaitGetEventData(
device_test::mojom::XRTestHook::WaitGetEventDataCallback callback) { … }
unsigned int MockXRDeviceHookBase::ConnectController(
const device::ControllerFrameData& initial_data) { … }
void MockXRDeviceHookBase::TerminateDeviceServiceProcessForTesting() { … }
void MockXRDeviceHookBase::UpdateController(
unsigned int index,
const device::ControllerFrameData& updated_data) { … }
void MockXRDeviceHookBase::DisconnectController(unsigned int index) { … }
device::ControllerFrameData MockXRDeviceHookBase::CreateValidController(
device::ControllerRole role) { … }
void MockXRDeviceHookBase::PopulateEvent(device_test::mojom::EventData data) { … }
void MockXRDeviceHookBase::WaitGetCanCreateSession(
device_test::mojom::XRTestHook::WaitGetCanCreateSessionCallback callback) { … }
void MockXRDeviceHookBase::SetCanCreateSession(bool can_create_session) { … }