mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 536567 - call InitUploadLastDir only when needed. r=ehsan
This commit is contained in:
parent
1fef158783
commit
532283056f
@ -291,8 +291,6 @@ nsLayoutStatics::Initialize()
|
||||
|
||||
NS_SealStaticAtomTable();
|
||||
|
||||
nsFileControlFrame::InitUploadLastDir();
|
||||
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
@ -165,6 +165,9 @@ nsFileControlFrame::Init(nsIContent* aContent,
|
||||
mMouseListener = new MouseListener(this);
|
||||
NS_ENSURE_TRUE(mMouseListener, NS_ERROR_OUT_OF_MEMORY);
|
||||
|
||||
if (!gUploadLastDir)
|
||||
nsFileControlFrame::InitUploadLastDir();
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
||||
@ -498,7 +501,8 @@ void nsFileControlFrame::InitUploadLastDir() {
|
||||
}
|
||||
|
||||
void nsFileControlFrame::DestroyUploadLastDir() {
|
||||
NS_RELEASE(gUploadLastDir);
|
||||
if (gUploadLastDir)
|
||||
NS_RELEASE(gUploadLastDir);
|
||||
}
|
||||
|
||||
UploadLastDir::UploadLastDir():
|
||||
|
Loading…
Reference in New Issue
Block a user