Closed Bug 912166 Opened 11 years ago Closed 11 years ago

Make nsIWidget::GetDefaultScale return a typed scale value

Categories

(Core :: Widget, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla27

People

(Reporter: kats, Assigned: almasry.mina)

References

Details

Attachments

(1 file, 2 obsolete files)

As per https://bugzilla.mozilla.org/show_bug.cgi?id=910322#c7, we should make widget->GetDefaultScale calls return a CSSToLayoutDeviceScale rather than a simple float.
Version: 23 Branch → Trunk
Assignee: nobody → malmasry
Attached patch Patch (obsolete) (deleted) — Splinter Review
Patch!
Attachment #805705 - Flags: review?(roc)
Comment on attachment 805705 [details] [diff] [review] Patch Review of attachment 805705 [details] [diff] [review]: ----------------------------------------------------------------- Nice!
Attachment #805705 - Flags: review?(roc) → review+
Comment on attachment 805705 [details] [diff] [review] Patch Review of attachment 805705 [details] [diff] [review]: ----------------------------------------------------------------- ::: widget/xpwidgets/nsBaseWidget.cpp @@ +1138,5 @@ > + CSSToLayoutDeviceScale scale = BoundsUseDisplayPixels() > + ? GetDefaultScale() > + : CSSToLayoutDeviceScale(1.0); > + double invScale = 1.0 / scale.scale; > + aWidth = mBounds.width * invScale + (aWidth - clientBounds.width * invScale); How come you defined invScale here but not in the other two functions in this file?
Attached patch Patch v2 (obsolete) (deleted) — Splinter Review
Attachment #805705 - Attachment is obsolete: true
Attached patch Patch v2 (deleted) — Splinter Review
My bad looks like I missed a few places where GetDefaultScale was referenced. That was fixed and here is a good try push: https://tbpl.mozilla.org/?tree=Try&rev=3d003221783d
Attachment #805996 - Attachment is obsolete: true
Attachment #806003 - Flags: review?(roc)
Keywords: checkin-needed
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla27
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: