Closed Bug 1466673 Opened 6 years ago Closed 6 years ago

Remove nsITreeColumns

Categories

(Core :: XUL, enhancement, P3)

enhancement

Tracking

()

RESOLVED FIXED
mozilla62
Tracking Status
firefox62 --- fixed

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

Details

Attachments

(5 files)

      No description provided.
Jorg, this one is going to need some mailnews changes.
Component: Layout → XUL
Blocks: 1466727
There are no JS implementors.
Attachment #8983299 - Flags: review?(dtownsend)
Attachment #8983303 - Flags: review?(dtownsend)
Comment on attachment 8983301 [details] [diff] [review]
part 3.  Stop using nsITreeColumns in accessibility code

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

::: accessible/base/nsCoreUtils.cpp
@@ +527,4 @@
>    if (!cols)
>      return nullptr;
>  
> +  RefPtr<nsTreeColumn> column = cols->GetFirstColumn();

It doesn't have to be a refptr, but the change will bloat your patch. If you could file a follow up good-first-bug on this, it'd be great.

::: accessible/xul/XULTreeAccessible.cpp
@@ +626,5 @@
>  
>    if (endCol == -1) {
> +    // We need to make sure to cast to int32_t before we do the subtraction, in
> +    // case the column count is 0.
> +    endCol = int32_t(treeColumns->Count()) - 1;

shouldn't you use static_cast instead of c-style casting?
Attachment #8983301 - Flags: review?(surkov.alexander) → review+
> If you could file a follow up good-first-bug on this, it'd be great.

You mean to make it a TreeColumn*?

> shouldn't you use static_cast instead of c-style casting?

I can do that, sure.
(In reply to Boris Zbarsky [:bz] (no decent commit message means r-) from comment #8)
> > If you could file a follow up good-first-bug on this, it'd be great.
> 
> You mean to make it a TreeColumn*?

Right, that would require to make nsCoreUtils::GetFirstSensibleColumn returning a raw pointer as well, plus bunch of related changes.
Attachment #8983299 - Flags: review?(dtownsend) → review+
Attachment #8983300 - Flags: review?(dtownsend) → review+
Attachment #8983302 - Flags: review?(dtownsend) → review+
Attachment #8983303 - Flags: review?(dtownsend) → review+
Pushed by bzbarsky@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/34467aba5393
part 1.  Mark nsITreeColumns builtinclass.  r=mossop
https://hg.mozilla.org/integration/mozilla-inbound/rev/a122097d4ec3
part 2.  Remove use of nsITreeColumns in other xpidl interfaces.  r=mossop
https://hg.mozilla.org/integration/mozilla-inbound/rev/1ce9fe4210ce
part 3.  Stop using nsITreeColumns in accessibility code.  r=surkov
https://hg.mozilla.org/integration/mozilla-inbound/rev/2095e4b302d2
part 4.  Stop using nsITreeColumns in various other C++ code.  r=mossop
https://hg.mozilla.org/integration/mozilla-inbound/rev/2628bc75afae
part 5.  Remove the nsITreeColumns interface.  r=mossop
Priority: -- → P3
You need to log in before you can comment on or make changes to this bug.