1,295
edits
mNo edit summary |
No edit summary |
||
Line 12: | Line 12: | ||
# Make sure you can build and run Mozilla with your changes. Test it thoroughly. | # Make sure you can build and run Mozilla with your changes. Test it thoroughly. | ||
# Make a patch with CVS diff -utp8, and submit it as an attachment in the bug. Request review, e.g. from roc. | # Make a patch with CVS diff -utp8, and submit it as an attachment in the bug. Request review, e.g. from roc. | ||
Here are some places known to need deCOMtamination or general interface cleanup: | Here are some places known to need deCOMtamination or general interface cleanup: | ||
Line 21: | Line 18: | ||
* Not really deCOMtamination, but anyway: many frames have an mPresContext field. This should be removed, and uses of that field can just call GetPresContext on the frame. (Some work on this in https://bugzilla.mozilla.org/show_bug.cgi?id=301313) | * Not really deCOMtamination, but anyway: many frames have an mPresContext field. This should be removed, and uses of that field can just call GetPresContext on the frame. (Some work on this in https://bugzilla.mozilla.org/show_bug.cgi?id=301313) | ||
* Lots of the non-Box methods of nsIFrame could be cleaned up too. We can remove the nsPresContext parameter from almost all of them. Many of them return their result in an 'out' parameter and should just return the result directly. Understanding the best way to do this for various methods will require some more creativity and understanding of the existing code. | * Lots of the non-Box methods of nsIFrame could be cleaned up too. We can remove the nsPresContext parameter from almost all of them. Many of them return their result in an 'out' parameter and should just return the result directly. Understanding the best way to do this for various methods will require some more creativity and understanding of the existing code. | ||
* in many cases we have a singleton interface like nsIComboboxControlFrame | |||
that is only implemented by one class, is not defined in IDL (and is therefore | |||
not scriptable), and is not visible outside Gecko. In these cases we can save | |||
code and data size by eliminating the interface, moving its methods to the | |||
concrete class and devirtualizing them, and casting to the class directly, like | |||
we just did with nsGfxButtonControlFrame. We can even assign the class an IID | |||
so you can get to it with QueryInterface. For example you can QI to | |||
nsBlockFrame this way. |
edits