зеркало из https://github.com/mozilla/pjs.git
Bug 380454, r=benjamin, sr=sicking
This commit is contained in:
Родитель
38efd51236
Коммит
c57eb7ac12
|
@ -58,6 +58,7 @@
|
|||
#include "nsParserUtils.h"
|
||||
#include "nsContentUtils.h"
|
||||
#include "nsPIDOMWindow.h"
|
||||
#include "nsPLDOMEvent.h"
|
||||
|
||||
class nsHTMLLinkElement : public nsGenericHTMLElement,
|
||||
public nsIDOMHTMLLinkElement,
|
||||
|
@ -273,9 +274,10 @@ nsHTMLLinkElement::CreateAndDispatchEvent(nsIDocument* aDoc,
|
|||
strings, eIgnoreCase) != ATTR_VALUE_NO_MATCH)
|
||||
return;
|
||||
|
||||
nsContentUtils::DispatchTrustedEvent(aDoc,
|
||||
static_cast<nsIContent*>(this),
|
||||
aEventName, PR_TRUE, PR_TRUE);
|
||||
nsRefPtr<nsPLDOMEvent> event = new nsPLDOMEvent(this, aEventName);
|
||||
if (event) {
|
||||
event->PostDOMEvent();
|
||||
}
|
||||
}
|
||||
|
||||
nsresult
|
||||
|
|
|
@ -200,6 +200,9 @@ nsThreadManager::GetCurrentThread()
|
|||
if (data)
|
||||
return static_cast<nsThread *>(data);
|
||||
|
||||
if (!mInitialized)
|
||||
return nsnull;
|
||||
|
||||
// OK, that's fine. We'll dynamically create one :-)
|
||||
nsRefPtr<nsThread> thread = new nsThread();
|
||||
if (!thread || NS_FAILED(thread->InitCurrentThread()))
|
||||
|
|
|
@ -69,7 +69,8 @@ public:
|
|||
// method must be called when the given thread is the current thread.
|
||||
void UnregisterCurrentThread(nsThread *thread);
|
||||
|
||||
// Returns the current thread. Returns null if OOM.
|
||||
// Returns the current thread. Returns null if OOM or if ThreadManager isn't
|
||||
// initialized.
|
||||
nsThread *GetCurrentThread();
|
||||
|
||||
// This needs to be public in order to support static instantiation of this
|
||||
|
|
Загрузка…
Ссылка в новой задаче