Bug 845374 - Part f: Create a new nsDocElementCreatedNotificationRunner.h; r=khuey

--HG--
rename : content/base/public/nsContentUtils.h => content/base/public/nsDocElementCreatedNotificationRunner.h
This commit is contained in:
Ms2ger 2013-03-17 08:55:12 +01:00
parent 35ae411e5a
commit f8e13f3750
5 changed files with 35 additions and 17 deletions

View File

@ -19,6 +19,7 @@ nsIAttribute.h \
nsIContentIterator.h \
nsContentPolicyUtils.h \
nsContentUtils.h \
nsDocElementCreatedNotificationRunner.h \
nsIDocument.h \
nsIDocumentInlines.h \
nsDeprecatedOperationList.h \

View File

@ -2434,21 +2434,4 @@ private:
nsIMIMEHeaderParam* mService;
};
class nsDocElementCreatedNotificationRunner : public nsRunnable
{
public:
nsDocElementCreatedNotificationRunner(nsIDocument* aDoc)
: mDoc(aDoc)
{
}
NS_IMETHOD Run()
{
nsContentSink::NotifyDocElementCreated(mDoc);
return NS_OK;
}
nsCOMPtr<nsIDocument> mDoc;
};
#endif /* nsContentUtils_h___ */

View File

@ -0,0 +1,32 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef nsDocElementCreatedNotificationRunner_h
#define nsDocElementCreatedNotificationRunner_h
#include "nsThreadUtils.h" /* nsRunnable */
#include "nsContentSink.h"
#include "nsCOMPtr.h"
#include "nsIDocument.h"
class nsDocElementCreatedNotificationRunner : public nsRunnable
{
public:
nsDocElementCreatedNotificationRunner(nsIDocument* aDoc)
: mDoc(aDoc)
{
}
NS_IMETHOD Run()
{
nsContentSink::NotifyDocElementCreated(mDoc);
return NS_OK;
}
nsCOMPtr<nsIDocument> mDoc;
};
#endif /* nsDocElementCreatedNotificationRunner_h */

View File

@ -18,6 +18,7 @@
#include "nsCharsetSource.h" // kCharsetFrom* macro definition
#include "nsNodeInfoManager.h"
#include "nsContentUtils.h"
#include "nsDocElementCreatedNotificationRunner.h"
namespace mozilla {
namespace dom {

View File

@ -6,6 +6,7 @@
#include "nsHtml5TreeOperation.h"
#include "nsContentUtils.h"
#include "nsDocElementCreatedNotificationRunner.h"
#include "nsNodeUtils.h"
#include "nsAttrName.h"
#include "nsHtml5TreeBuilder.h"