| Index: ui/ozone/platform/egltest/ozone_platform_egltest.cc
|
| diff --git a/ui/ozone/platform/egltest/ozone_platform_egltest.cc b/ui/ozone/platform/egltest/ozone_platform_egltest.cc
|
| index 447d3a346b184a156cbfc217b8c13a01efe82ae2..371ba339e323b24303e981fb98aca9e2bc7d5c75 100644
|
| --- a/ui/ozone/platform/egltest/ozone_platform_egltest.cc
|
| +++ b/ui/ozone/platform/egltest/ozone_platform_egltest.cc
|
| @@ -59,7 +59,7 @@ void ScaleTouchEvent(TouchEvent* event, const gfx::SizeF& size) {
|
| for (const auto& device :
|
| DeviceDataManager::GetInstance()->touchscreen_devices()) {
|
| if (device.id == event->source_device_id()) {
|
| - gfx::SizeF touchscreen_size = device.size;
|
| + gfx::SizeF touchscreen_size = gfx::SizeF(device.size);
|
| gfx::PointF location = event->location_f();
|
|
|
| location.Scale(size.width() / touchscreen_size.width(),
|
| @@ -194,8 +194,10 @@ bool EgltestWindow::CanDispatchEvent(const ui::PlatformEvent& ne) {
|
| uint32_t EgltestWindow::DispatchEvent(const ui::PlatformEvent& native_event) {
|
| DCHECK(native_event);
|
| Event* event = static_cast<Event*>(native_event);
|
| - if (event->IsTouchEvent())
|
| - ScaleTouchEvent(static_cast<TouchEvent*>(event), bounds_.size());
|
| + if (event->IsTouchEvent()) {
|
| + ScaleTouchEvent(static_cast<TouchEvent*>(event),
|
| + gfx::SizeF(bounds_.size()));
|
| + }
|
|
|
| DispatchEventFromNativeUiEvent(
|
| native_event, base::Bind(&PlatformWindowDelegate::DispatchEvent,
|
|
|