Closed
Bug 1447940
Opened 7 years ago
Closed 7 years ago
Port bug 1444143 and bug 1447098 to TB: Replace use of nsIFrameLoader and rename FromContent to FromNode
Categories
(MailNews Core :: Composition, enhancement)
MailNews Core
Composition
Tracking
(Not tracked)
RESOLVED
FIXED
Thunderbird 61.0
People
(Reporter: Paenglab, Assigned: jorgk-bmo)
References
Details
Attachments
(1 file, 2 obsolete files)
8.87 KB,
patch
|
bzbarsky
:
review+
|
Details | Diff | Splinter Review |
Both bugs need to be ported.
Reporter | ||
Comment 1•7 years ago
|
||
This is my approach with my zero C++ skills.
It still fails with:
0:20.58 nsMsgContentPolicy.cpp
0:20.58 z:/Mozilla/comm-central/mailnews/base/src/nsMsgContentPolicy.cpp(757): error C2039: 'GetFrameLoaderXPCOM': is not a member of 'nsIFrameLoaderOwner'
0:20.58 z:/Mozilla/TB/dist/include\nsIFrameLoaderOwner.h(28): note: see declaration of 'nsIFrameLoaderOwner'
0:20.58 z:/Mozilla/comm-central/mailnews/base/src/nsMsgContentPolicy.cpp(762): error C2027: use of undefined type 'nsFrameLoader'
0:20.58 z:\mozilla\tb\dist\include\nsIMessageManager.h(29): note: see declaration of 'nsFrameLoader'
0:20.58 z:/Mozilla/comm-central/mailnews/base/src/nsMsgContentPolicy.cpp(762): error C2039: 'GetDocShell': is not a member of 'nsCOMPtr<nsFrameLoader>'
0:20.58 z:/Mozilla/comm-central/mailnews/base/src/nsMsgContentPolicy.cpp(756): note: see declaration of 'nsCOMPtr<nsFrameLoader>'
Assignee | ||
Comment 2•7 years ago
|
||
Yes, GetFrameLoaderXPCOM() was removed:
https://hg.mozilla.org/integration/mozilla-inbound/rev/f550087a772e#l1.19
https://hg.mozilla.org/integration/mozilla-inbound/rev/f550087a772e#l3.13
So we really need advice from Boris.
Flags: needinfo?(bzbarsky)
Assignee | ||
Updated•7 years ago
|
Summary: Port bug 1444143 and bug 1447098 to TB → Port bug 1444143 and bug 1447098 to TB: Replace use of nsIFrameLoader and rename FromContent to FromNode
Assignee | ||
Comment 3•7 years ago
|
||
This goes closer, now only: 'IgnoreErrors': identifier not found
Attachment #8961312 -
Attachment is obsolete: true
Attachment #8961390 -
Flags: feedback?(bzbarsky)
Assignee | ||
Comment 4•7 years ago
|
||
That does the job.
Assignee: nobody → jorgk
Attachment #8961390 -
Attachment is obsolete: true
Status: NEW → ASSIGNED
Attachment #8961390 -
Flags: feedback?(bzbarsky)
Flags: needinfo?(bzbarsky)
Attachment #8961407 -
Flags: review?(bzbarsky)
Assignee | ||
Comment 5•7 years ago
|
||
Comment 6•7 years ago
|
||
Comment on attachment 8961407 [details] [diff] [review]
Bustage.patch
>+ mozilla::dom::HTMLImageElement::FromNodeOrNull(element);
This is to do with bug 1447098, but ok. Sorry, I should have realized comm-central used FromContent....
>+ RefPtr<nsFrameLoader> frameLoader = flOwner ?
flOwner shouldn't be null here, since the QI succeeded. The old code certainly didn't null-check. Just drop the null-check, please:
RefPtr<nsFrameLoader> frameLoader = flOwner->GetFrameLoader();
Also, you need to use mozilla::dom::nsFrameLoader as the type, no? Or add some "using" declarations to make it simpler.
r=me. Thank you for dealing with this!
Attachment #8961407 -
Flags: review?(bzbarsky) → review+
Assignee | ||
Comment 7•7 years ago
|
||
(In reply to Boris Zbarsky [:bz] (no decent commit message means r-) from comment #6)
> Also, you need to use mozilla::dom::nsFrameLoader as the type, no?
Apparently not since it compiles like this: RefPtr<nsFrameLoader> frameLoader = flOwner->GetFrameLoader();
RefPtr<mozilla::dom::nsFrameLoader> frameLoader = flOwner->GetFrameLoader();
doesn't compile.
nsFrameLoader.h just has |class nsFrameLoader final :|.
So I'll land this just with the null-check removed.
Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/5c4b9489b3ba
Port bug 1444143 and bug 1447098 to TB: Replace use of nsIFrameLoader and rename FromContent to FromNode. r=bz
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Assignee | ||
Updated•7 years ago
|
Target Milestone: --- → Thunderbird 61.0
Comment 9•7 years ago
|
||
Oh, I forgot that nsFrameLoader is not namespaced. OK. I keep thinking it's already mozilla::dom::FrameLoader. ;)
You need to log in
before you can comment on or make changes to this bug.
Description
•