mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1227377: Change ImageRequest::mRequests hashtable to use more specific type in its key (s/nsISupports/nsIDocument/). r=khuey
This commit is contained in:
parent
5ffe53a84d
commit
8bc3913e4d
@ -2480,18 +2480,9 @@ css::ImageValue::ImageValue(nsIURI* aURI, nsStringBuffer* aString,
|
||||
css::ImageValue::~ImageValue()
|
||||
{
|
||||
for (auto iter = mRequests.Iter(); !iter.Done(); iter.Next()) {
|
||||
nsISupports* key = iter.Key();
|
||||
nsIDocument* doc = iter.Key();
|
||||
RefPtr<imgRequestProxy>& proxy = iter.Data();
|
||||
|
||||
nsIDocument* doc = static_cast<nsIDocument*>(key);
|
||||
|
||||
#ifdef DEBUG
|
||||
{
|
||||
nsCOMPtr<nsIDocument> slowDoc = do_QueryInterface(key);
|
||||
MOZ_ASSERT(slowDoc == doc);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (doc) {
|
||||
doc->StyleImageLoader()->DeregisterCSSImage(this);
|
||||
}
|
||||
|
@ -147,7 +147,7 @@ private:
|
||||
public:
|
||||
// Inherit operator== from URLValue
|
||||
|
||||
nsRefPtrHashtable<nsPtrHashKey<nsISupports>, imgRequestProxy> mRequests;
|
||||
nsRefPtrHashtable<nsPtrHashKey<nsIDocument>, imgRequestProxy> mRequests;
|
||||
|
||||
// Override AddRef and Release to not only log ourselves correctly, but
|
||||
// also so that we delete correctly without a virtual destructor (assuming
|
||||
|
Loading…
Reference in New Issue
Block a user