Closed Bug 397792 Opened 17 years ago Closed 17 years ago

Widgets rotated in the wrong direction

Categories

(Core :: Widget: Cocoa, defect)

x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: cbarrett, Assigned: cbarrett)

References

Details

Attachments

(2 files)

Attached file testcase
Similar to bug 379429, but basic widgets are rotating in the wrong direction instead of images. (buttons don't rotate at all, but I think that's because we're using compositeToPoint instead of drawAtPoint. Haven't verified though).

Testcase based on roc's testcase for bug 380203.
Attached patch fix v1.0Splinter Review
Turns out cairo's transform matrix is defined as:
[xx yx 0]
[xy yy 0]
[x0 y0 1]

while CG's is defined:
[a  b  0]
[c  d  0]
[tx ty 1]

We weren't passing in the params in the right order (we had xy and yx backwards), so the transform matrix was screwed up. Thanks to vlad for helping me figure this out over IRC.
Attachment #282786 - Flags: review?(joshmoz)
Attachment #282786 - Flags: review?(joshmoz)
Attachment #282786 - Flags: review+
Attachment #282786 - Flags: approval1.9+
Attachment #282786 - Flags: superreview?(pavlov)
Attachment #282786 - Flags: superreview?(pavlov)
Checking in widget/src/cocoa/nsNativeThemeCocoa.mm;
/cvsroot/mozilla/widget/src/cocoa/nsNativeThemeCocoa.mm,v  <--  nsNativeThemeCocoa.mm
new revision: 1.60; previous revision: 1.59
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
There's still a lot broken with the testcase: the dropdown's text is outside of the dropdown, things disappear when clicked, and the button never rotates.  Are there bugs on those other issues?
There will be, yes.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: