Closed Bug 1540965 Opened 5 years ago Closed 5 years ago

Make nsIControllerContext builtinclass

Categories

(Core :: XUL, defect, P3)

defect

Tracking

()

RESOLVED FIXED
mozilla68
Tracking Status
firefox68 --- fixed

People

(Reporter: masayuki, Assigned: masayuki)

References

Details

Attachments

(1 file)

nsIControllerContext isn't implemented with JS even in comm-central nor
BlueGriffon. Therefore, it can be a builtinclass.

Additionally, it's init() returns always NS_OK, and always called with
null from JS, and always called with an instance from C++. So that its the
only implementation, nsBaseCommandController can have 2 constructors which
does what Init() currently does.

Priority: -- → P3

Thanks, Masakuki-san, the three C-C call sites look like the were used only in SeaMonkey, but I could be wrong. I'll file a bug.

Depends on: 1541144
Pushed by masayuki@d-toybox.com:
https://hg.mozilla.org/integration/autoland/rev/42b4d2faa543
Make nsIControllerContext builtinclass and removes its init() method r=bzbarsky
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla68

That caused us C++ bustage here:
https://searchfox.org/comm-central/rev/10bc0c1569fab6ccdce1c31413067d1ec0de8c61/common/src/nsCommonModule.cpp#18

nsCommonModule.cpp(18,32): error: call to constructor of 'nsBaseCommandController' is ambiguous
0:18.05 NS_GENERIC_FACTORY_CONSTRUCTOR(nsBaseCommandController)

I'll have to see how to fix that. The constructor now takes a command table:
https://hg.mozilla.org/mozilla-central/rev/42b4d2faa543#l2.14

Blocks: 1542352
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: