Open Bug 1604753 Opened 5 years ago Updated 5 years ago

Changing document title resets cursor style... some of the time?

Categories

(Core :: Widget: Cocoa, defect, P3)

72 Branch
x86_64
macOS
defect

Tracking

()

People

(Reporter: naktinis, Unassigned)

Details

(Keywords: steps-wanted, testcase)

Attachments

(2 files)

Attached file title_cursor_bug.html

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:71.0) Gecko/20100101 Firefox/71.0

Steps to reproduce:

Create an element with a custom cursor style, while hovering that element set document.title to a new value with JavaScript (e.g. with a click event or using SetTimeout). I've only tried it on MacOS, by the way.

Actual results:

Cursor was reset to the default style.

Expected results:

Cursor should not have been affected by title change.

Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:71.0) Gecko/20100101 Firefox/71.0
20191202093317

Works for me. Setting platform to macOS.

Has STR: --- → yes
Component: Untriaged → DOM: Core & HTML
Keywords: testcase
OS: Unspecified → macOS
Product: Firefox → Core
Hardware: Unspecified → x86_64

WFM on linux.

Not sure about component, but perhaps browser UI does something unexpected on MacOS.

Component: DOM: Core & HTML → General
Product: Core → Firefox

The priority flag is not set for this bug.
:Dolske, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(dolske)

I can't reproduce this on macOS either. Can you clarify if you've tested on a clean profile? ( https://support.mozilla.org/en-US/kb/profile-manager-create-and-remove-firefox-profiles )

If it fails for you with a clean profile on current nightly ( https://nightly.mozilla.org/ ), can you attach your about:support information from nightly? Thank you!

Flags: needinfo?(dolske) → needinfo?(naktinis)

I did some more testing and it seems that it takes some time to reproduce, but I always get into this state. I have cleared the profile as you've suggested and restarted Firefox, and the behaviour was gone for a while, I could also not reproduce it this morning, but I left the browser open and checked back a few minutes ago and the behaviour was back. Then I restarted the browser and it was gone again.

Some observations:

  1. It happens on other machines too. I could reproduce it on Firefox on my colleague's MacBook Pro.
  2. Restarting the browser seems to temporarily fix it.
  3. Latest version I could reproduce it on is 72.0.2.
  4. It may depend on activity outside the page in question (other tabs, network state, memory consumption, browser running time...).

I could not yet reproduce it on Nightly, but maybe just because I use the stable version more.

Flags: needinfo?(naktinis)
Version: 71 Branch → 72 Branch

I just reproduced this in my normal beta profile, but like the reporter, can't reproduce immediately on a clean nightly profile...

Emilio, any idea what could influence cursor / layout like this, or who I should ask about this instead?

I'm pretty sure the title setting itself doesn't / isn't supposed to affect cursors... but I'm not sure how to narrow it down when I can't reproduce in a clean profile, and the cursor stuff itself is not frontend code (so can't use e.g. the js debugger).

Status: UNCONFIRMED → NEW
Ever confirmed: true
Flags: needinfo?(emilio)
Keywords: steps-wanted
Summary: Changing document title resets cursor style → Changing document title resets cursor style... some of the time?

My guess would be in the cocoa code. Changing document.title needs to update the titlebar or what not I guess, so it seems possible that some of the native state gets confused...

This is the part of the code where we set the cursor if I'm not wrong: https://searchfox.org/mozilla-central/rev/2e355fa82aaa87e8424a9927c8136be184eeb6c7/widget/cocoa/nsChildView.mm#662

I'd move this to the cocoa component and maybe ask mstange or spohl.

Flags: needinfo?(emilio)

(In reply to Emilio Cobos Álvarez (:emilio) from comment #8)

My guess would be in the cocoa code. Changing document.title needs to update the titlebar or what not I guess, so it seems possible that some of the native state gets confused...

This is the part of the code where we set the cursor if I'm not wrong: https://searchfox.org/mozilla-central/rev/2e355fa82aaa87e8424a9927c8136be184eeb6c7/widget/cocoa/nsChildView.mm#662

I'd move this to the cocoa component and maybe ask mstange or spohl.

:spohl, hopefully you have some idea?

Component: General → Widget: Cocoa
Flags: needinfo?(spohl.mozilla.bugs)
Product: Firefox → Core

Not off the top of my head, but I've added this bug to the backlog.

Flags: needinfo?(spohl.mozilla.bugs)
Priority: -- → P3
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: