Have a native rendering for <progress> on Windows Vista and Windows 7

VERIFIED FIXED in mozilla6

Status

()

defect
VERIFIED FIXED
9 years ago
8 years ago

People

(Reporter: mounir, Assigned: mounir)

Tracking

Trunk
mozilla6
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(3 attachments, 4 obsolete attachments)

No description provided.
Attachment #519149 - Flags: review?(doug.turner)
what is the purpose of this change?

does it make sense to put up a before/after screenshot?
The purpose is to use the correct Windows Vista/7 API for progress bars instead of the XP one. Our rendering of the progress bar on Windows Vista/7 isn't really native for the moment. You can see that by downloading a file on Windows Vista/7 and look at the rendering. Then, look at what a native progress bar look like.

I will try to put some screenshots...
The difference might not be really obvious on the screenshot because there is an animated glow on progress bars on Windows Vista/7. You can see that by openning this data URL on Chrome: data:text/html,<progress value=1></progress>
Fix a warning.
Attachment #519149 - Attachment is obsolete: true
Attachment #519149 - Flags: review?(doug.turner)
Attachment #519435 - Flags: review?(doug.turner)
Unfortunately, our code isn't great for animations. To prevent keeping too many static variables, I'm only using PR_IntervalNow(). That means the position of the glow when the page is loaded isn't guaranteed to be at the left of the element.
In addition, all progress bars will share the same glow position. That means if you create multiple progress bars with the same size, the glow will be perfectly synchronized (even if some progress bars are added later).

I will refactor this code and create proper constants when I will implement the indeterminate rendering.
Attachment #519436 - Flags: review?(doug.turner)
Blocks: 641905
If you want to compare the rendering, please use this build:
https://ftp.mozilla.org/pub/mozilla.org/firefox/tryserver-builds/mlamouri@mozilla.com-d171ffeea1be/ (before)
and this one:
https://ftp.mozilla.org/pub/mozilla.org/firefox/tryserver-builds/mlamouri@mozilla.com-3665ab582961/ (after)

And open this data url: data:text/html,<progress value=1></progress>
Blocks: 641942
Blocks: 642127
Use consts and moving the review to Jim so he can review all the patches involved here.
Attachment #519435 - Attachment is obsolete: true
Attachment #519435 - Flags: review?(doug.turner)
Attachment #519973 - Flags: review?(jmathies)
Attachment #519436 - Attachment is obsolete: true
Attachment #519436 - Flags: review?(doug.turner)
Attachment #519974 - Flags: review?(jmathies)
Attachment #519974 - Attachment is obsolete: true
Attachment #519974 - Flags: review?(jmathies)
Attachment #519980 - Flags: review?(jmathies)
Comment on attachment 519973 [details] [diff] [review]
Part 1 - Use PP_FILL instead of PP_CHUNK

Review of attachment 519973 [details] [diff] [review]:

r+
Attachment #519973 - Flags: review?(jmathies) → review+
Comment on attachment 519980 [details] [diff] [review]
Part 2 - Add the animated glow

Review of attachment 519980 [details] [diff] [review]:

r+
Attachment #519980 - Flags: review?(jmathies) → review+
Whiteboard: [needs review]
Whiteboard: [ready to land][waits for dependencies]
Pushed:
http://hg.mozilla.org/mozilla-central/rev/f8ab655d503c
http://hg.mozilla.org/mozilla-central/rev/4a7b8019b83f
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Whiteboard: [ready to land][waits for dependencies]
Target Milestone: --- → mozilla6
Depends on: 655860
Backed out in http://hg.mozilla.org/mozilla-central/rev/dd9ba28d2bd9 to resolve bug 655860.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
The regression wasn't caused by these patches. Re-landed:
http://hg.mozilla.org/mozilla-central/rev/66bf0a9f32b2
http://hg.mozilla.org/mozilla-central/rev/75ced66ef579
Status: REOPENED → RESOLVED
Closed: 8 years ago8 years ago
Resolution: --- → FIXED
No longer depends on: 655860
Depends on: 656592
Duplicate of this bug: 378276
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:6.0) Gecko/20100101 Firefox/6.0

Verified patch on Win7 and animation is present -  behavior is a bit different from what can be observed in Chrome, the animation(the glow) being slower on Firefox. Was that expected?
(In reply to comment #16)
> Verified patch on Win7 and animation is present -  behavior is a bit
> different from what can be observed in Chrome, the animation(the glow) being
> slower on Firefox. Was that expected?

Our goal is certainly not to copy all Chrome bits...
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0a1) Gecko/20110725 Firefox/8.0a1

Considering last comment, setting status to Verified Fixed.
Status: RESOLVED → VERIFIED
Depends on: 711962
You need to log in before you can comment on or make changes to this bug.