Closed Bug 622285 Opened 14 years ago Closed 14 years ago

CSS warnings: "Error in parsing value for 'size'/'position'. Declaration dropped." Solution: remove Rect_css method and instead allow iQ's css method to accept Rect arguments

Categories

(Firefox Graveyard :: Panorama, defect, P2)

defect

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mitcho, Assigned: mitcho)

References

Details

(Whiteboard: [qa-][good first bug][cleanup])

Attachments

(1 file, 2 obsolete files)

When Panorama is open, a lot of CSS warnings show up:

> Warning: Error in parsing value for 'size'.  Declaration dropped.
> Source File: chrome://browser/content/tabview.html
> Line: 0

> Warning: Error in parsing value for 'position'.  Declaration dropped.
> Source File: chrome://browser/content/tabview.html
> Line: 0

We need to clean these up. They're messy and unprofessional, and may actually indicate that there are CSS declarations or dynamic styles which are not being applied as intended.
So this has to do with the few instances where we give iQ's css() a Rect object. This is because right now we can't pass a rect into css(), but have to pass rect.css() into css(). This can be confusing and, as the warnings indicate, we have forgotten it in some places.

Solution: make it so iQ's css() *does* accept Rect objects directly. If the argument is a Rect, css() can turn it into the appropriate properties object.

This makes more sense than our current approach, as we ultimately want to move to using Geometry.jsm (bug 585672). The Rect class offered by Geometry.jsm has no .css(). As iQ is already aware of the Rect class, the proposed solution makes more sense and will alleviate a developer papercut.
Assignee: nobody → mitcho
Blocks: 585672
Status: NEW → ASSIGNED
Summary: CSS warnings: Error in parsing value for 'size'/'position'. Declaration dropped. → CSS warnings: "Error in parsing value for 'size'/'position'. Declaration dropped." Solution: remove Rect_css method and instead allow iQ's css method to accept Rect arguments
Attached patch Patch v1 (obsolete) — Splinter Review
Attachment #500541 - Flags: review?(ian)
Comment on attachment 500541 [details] [diff] [review]
Patch v1

Looks good, but to be complete you need to do the same for iQ's .animate.

R+ with that.
Attachment #500541 - Flags: review?(ian) → review+
Attached patch Patch v1.1 (obsolete) — Splinter Review
Thanks Ian. Added the same treatment to animate.

Can we land this without a mochitest?
Attachment #500541 - Attachment is obsolete: true
Attachment #501166 - Flags: approval2.0?
Pushed patch v1.1 to try today. Passed.
Yeah, I don't think it needs a test.
Comment on attachment 501166 [details] [diff] [review]
Patch v1.1

a=beltzner
Attachment #501166 - Flags: approval2.0? → approval2.0+
Attachment #501166 - Attachment is obsolete: true
http://hg.mozilla.org/mozilla-central/rev/bbec1daa766b
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Product: Firefox → Firefox Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: