Have nsBaseWidget derive from nsSupportsWeakReference

RESOLVED FIXED in Firefox 38

Status

()

Core
Widget
RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: botond, Assigned: dvander)

Tracking

Trunk
mozilla38
Points:
---

Firefox Tracking Flags

(firefox38 fixed)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Reporter)

Description

3 years ago
Bug 1127066 completed support for APZ in the root process by hooking up code in nsBaseWidget with APZ.

Platforms that make use of this support need to have their concrete widget type support weak references (by inheriting from nsSupportsWeakReference).

So far this support, where missing, has been added individually for each platform. Kats suggested in bug 1127066 comment 53, and I agree, that it would be better to just have nsBaseWidget provide the support.
Without this bug fixed OSX (and probably windows) desktop debug builds crash on startup if APZ is enabled.
Created attachment 8565734 [details] [diff] [review]
bug1133150.patch

Yep, Windows definitely crashes.
Assignee: nobody → dvander
Status: NEW → ASSIGNED
Attachment #8565734 - Flags: review?(botond)
(Reporter)

Comment 3

3 years ago
Comment on attachment 8565734 [details] [diff] [review]
bug1133150.patch

Review of attachment 8565734 [details] [diff] [review]:
-----------------------------------------------------------------

I believe you need to adjust the NS_IMPL_ISUPPORTS invocations for all the classes where you added or removed inheritance as well [1] [2] [3] [4] [5].

f+ with that change, but I'd like the final review to come from a widget peer/owner [6].

[1] http://mxr.mozilla.org/mozilla-central/source/widget/PuppetWidget.cpp?rev=b6c56fab513d#74
[2] http://mxr.mozilla.org/mozilla-central/source/widget/gonk/nsWindow.cpp?rev=4f4de86d9c3f#132
[3] http://mxr.mozilla.org/mozilla-central/source/widget/gtk/nsWindow.cpp?rev=29846628ba2b#426
[4] http://mxr.mozilla.org/mozilla-central/source/widget/qt/nsWindow.cpp?rev=28b5570caf86#1380
[5] http://mxr.mozilla.org/mozilla-central/source/widget/nsBaseWidget.cpp?rev=40a4e0b2dd08#98
[6] https://wiki.mozilla.org/Modules/All#Widget
Attachment #8565734 - Flags: review?(botond) → feedback+
Created attachment 8565770 [details] [diff] [review]
patch
Attachment #8565734 - Attachment is obsolete: true
Attachment #8565770 - Flags: review?(roc)
https://hg.mozilla.org/mozilla-central/rev/71d030563b18
Status: ASSIGNED → RESOLVED
Last Resolved: 3 years ago
status-firefox38: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla38
You need to log in before you can comment on or make changes to this bug.