New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 869286 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Sep 20
Cc:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 3
Type: Bug

Blocking:
issue 578890



Sign in to add a comment

[ozone/wayland] fix possible cursor offset due to wrong scale values.

Project Member Reported by msi...@igalia.com, Jul 31

Issue description

Open chromium with ozone/wayland backend.

Start surfing the net.

At some point, the cursor bitmap is shown with a certain offset, which makes it hard to press on ui elements.
 
Blocking: 578890
Summary: [ozone/wayland] fix possible cursor offset due to wrong scale values. (was: Wayland: fix possible cursor offset due to wrong scale values.)
Project Member

Comment 3 by bugdroid1@chromium.org, Sep 13

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/60bb0d36ae2b4635eff71be790df3a8adc5ff076

commit 60bb0d36ae2b4635eff71be790df3a8adc5ff076
Author: Maksim Sisov <msisov@igalia.com>
Date: Thu Sep 13 20:04:23 2018

Ensure default scale value of cursors is not 0.0f but 1.0f.

This patches fixes a pointer offset issues, which usually happens
with Ozone/Wayland (and can happen with Ozone/X11).

That is, on certain occasions, the pointer bitmap can have an offset,
which results in wrong visual location of the pointer. This makes
it hard to press ui elements in Chromium.

The reason of that behaviour is that default scale value of the
Cursor is 0.0f (when it is not explicitly set to something
else), but the SearchTable (cursors_aura) method checks for the
bitmap hotpoints based on the lowest possible scale value, which
is 1.0f. Thus, there was an inconsitancy between the scale value
and the hotpoints. When the cursor had a scale value implicitly
set to 0.0f (in the ctor), 2x hotpoints were used.

To fix this, CreateDefaultBitmapCursor must honor the scale factor,
and set it the lowest possible one, which is 1.0f.

Bug:  869286 
Change-Id: Ia792ae26a7573b58fa4dca7356c49cd4b5d8042a
Reviewed-on: https://chromium-review.googlesource.com/1203973
Reviewed-by: Scott Violet <sky@chromium.org>
Commit-Queue: Maksim Sisov <msisov@igalia.com>
Cr-Commit-Position: refs/heads/master@{#591125}
[modify] https://crrev.com/60bb0d36ae2b4635eff71be790df3a8adc5ff076/ui/base/cursor/ozone/bitmap_cursor_factory_ozone.cc

Status: Fixed (was: Started)

Sign in to add a comment