Reviewed by Eric Seidel.
Remove unused member of PendingScript
https://bugs.webkit.org/show_bug.cgi?id=51684
This was used when HTMLScriptRunner::runScript created a PendingScript
for inline scripts. But now it just calls executeScript() directly.
External scripts always have the minimum starting line number.
No new tests because no changed functionality.
* dom/PendingScript.cpp:
(WebCore::PendingScript::releaseElementAndClear):
* dom/PendingScript.h:
(WebCore::PendingScript::PendingScript):
(WebCore::PendingScript::operator=):
* html/parser/HTMLScriptRunner.cpp:
(WebCore::HTMLScriptRunner::sourceFromPendingScript):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@74724
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2010-12-28 Tony Gentilcore <tonyg@chromium.org>
+
+ Reviewed by Eric Seidel.
+
+ Remove unused member of PendingScript
+ https://bugs.webkit.org/show_bug.cgi?id=51684
+
+ This was used when HTMLScriptRunner::runScript created a PendingScript
+ for inline scripts. But now it just calls executeScript() directly.
+ External scripts always have the minimum starting line number.
+
+ No new tests because no changed functionality.
+
+ * dom/PendingScript.cpp:
+ (WebCore::PendingScript::releaseElementAndClear):
+ * dom/PendingScript.h:
+ (WebCore::PendingScript::PendingScript):
+ (WebCore::PendingScript::operator=):
+ * html/parser/HTMLScriptRunner.cpp:
+ (WebCore::HTMLScriptRunner::sourceFromPendingScript):
+
2010-12-20 Antonio Gomes <agomes@rim.com>
Reviewed by Daniel Bates.
PassRefPtr<Element> PendingScript::releaseElementAndClear()
{
setCachedScript(0);
- m_startingPosition = TextPosition1::belowRangePosition();
m_watchingForLoad = false;
return m_element.release();
}
class PendingScript : public CachedResourceClient {
public:
PendingScript()
- : m_startingPosition(TextPosition1::belowRangePosition())
- , m_watchingForLoad(false)
+ : m_watchingForLoad(false)
{
}
PendingScript(const PendingScript& other)
: CachedResourceClient(other)
- , m_startingPosition(other.m_startingPosition)
, m_watchingForLoad(other.m_watchingForLoad)
, m_element(other.m_element)
{
if (this == &other)
return *this;
- m_startingPosition = other.m_startingPosition;
m_watchingForLoad = other.m_watchingForLoad;
m_element = other.m_element;
setCachedScript(other.cachedScript());
return *this;
}
- // FIXME: No setter means this is never set to anything other than 0.
- // This is either unnecessary or incorrect.
- TextPosition1 startingPosition() const { return m_startingPosition; }
-
bool watchingForLoad() const { return m_watchingForLoad; }
void setWatchingForLoad(bool b) { m_watchingForLoad = b; }
virtual void notifyFinished(CachedResource*);
private:
- TextPosition1 m_startingPosition; // Only used for inline script tags.
bool m_watchingForLoad;
RefPtr<Element> m_element;
CachedResourceHandle<CachedScript> m_cachedScript;
return ScriptSourceCode(script.cachedScript());
}
errorOccurred = false;
- return ScriptSourceCode(script.element()->textContent(), documentURLForScriptExecution(m_document), script.startingPosition());
+ return ScriptSourceCode(script.element()->textContent(), documentURLForScriptExecution(m_document));
}
bool HTMLScriptRunner::isPendingScriptReady(const PendingScript& script)