[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
commit-queue at webkit.org
commit-queue at webkit.org
Wed Dec 22 16:32:39 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 4411109eb73de599b9d163af5853f50651d75782
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Thu Nov 25 16:37:33 2010 +0000
2010-11-25 Sheriff Bot <webkit.review.bot at gmail.com>
Unreviewed, rolling out r72727.
http://trac.webkit.org/changeset/72727
https://bugs.webkit.org/show_bug.cgi?id=50084
Broke dom-breakpoints test on chromium win (Requested by
podivilov on #webkit).
* inspector/InspectorController.cpp:
(WebCore::InspectorController::setNativeBreakpoint):
* inspector/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::InspectorDOMAgent):
(WebCore::InspectorDOMAgent::discardBindings):
(WebCore::InspectorDOMAgent::setDOMBreakpoint):
(WebCore::InspectorDOMAgent::removeDOMBreakpoint):
(WebCore::InspectorDOMAgent::descriptionForDOMEvent):
(WebCore::InspectorDOMAgent::removeBreakpointsForNode):
(WebCore::InspectorDOMAgent::createBreakpointId):
* inspector/InspectorDOMAgent.h:
* inspector/front-end/BreakpointManager.js:
(WebInspector.BreakpointManager.prototype.reset):
(WebInspector.BreakpointManager.prototype.createDOMBreakpoint):
(WebInspector.BreakpointManager.prototype._updateNativeBreakpointsInSettings):
(WebInspector.BreakpointManager.prototype.restoreBreakpoints):
(WebInspector.BreakpointManager.prototype.restoreDOMBreakpoints):
(WebInspector.DOMBreakpoint):
(WebInspector.DOMBreakpoint.prototype.populateLabelElement):
(WebInspector.EventListenerBreakpoint):
(WebInspector.XHRBreakpoint):
* inspector/front-end/BreakpointsSidebarPane.js:
(WebInspector.BreakpointsSidebarPane):
(WebInspector.BreakpointsSidebarPane.prototype.reset):
(WebInspector.EventListenerBreakpointsSidebarPane):
(WebInspector.EventListenerBreakpointsSidebarPane.prototype.reset):
* inspector/front-end/DOMAgent.js:
(WebInspector.DOMAgent.prototype._setDocument):
* inspector/front-end/ElementsPanel.js:
(WebInspector.ElementsPanel.prototype.reset):
* inspector/front-end/ElementsTreeOutline.js:
(WebInspector.ElementsTreeElement.prototype._populateTagContextMenu.handlerFunction):
(WebInspector.ElementsTreeElement.prototype._populateTagContextMenu):
* inspector/front-end/ScriptsPanel.js:
(WebInspector.ScriptsPanel.prototype.reset):
* inspector/front-end/inspector.js:
(WebInspector.reset):
(WebInspector.didCommitLoad):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@72733 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index c3a19ef..1f2e0eb 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,51 @@
+2010-11-25 Sheriff Bot <webkit.review.bot at gmail.com>
+
+ Unreviewed, rolling out r72727.
+ http://trac.webkit.org/changeset/72727
+ https://bugs.webkit.org/show_bug.cgi?id=50084
+
+ Broke dom-breakpoints test on chromium win (Requested by
+ podivilov on #webkit).
+
+ * inspector/InspectorController.cpp:
+ (WebCore::InspectorController::setNativeBreakpoint):
+ * inspector/InspectorDOMAgent.cpp:
+ (WebCore::InspectorDOMAgent::InspectorDOMAgent):
+ (WebCore::InspectorDOMAgent::discardBindings):
+ (WebCore::InspectorDOMAgent::setDOMBreakpoint):
+ (WebCore::InspectorDOMAgent::removeDOMBreakpoint):
+ (WebCore::InspectorDOMAgent::descriptionForDOMEvent):
+ (WebCore::InspectorDOMAgent::removeBreakpointsForNode):
+ (WebCore::InspectorDOMAgent::createBreakpointId):
+ * inspector/InspectorDOMAgent.h:
+ * inspector/front-end/BreakpointManager.js:
+ (WebInspector.BreakpointManager.prototype.reset):
+ (WebInspector.BreakpointManager.prototype.createDOMBreakpoint):
+ (WebInspector.BreakpointManager.prototype._updateNativeBreakpointsInSettings):
+ (WebInspector.BreakpointManager.prototype.restoreBreakpoints):
+ (WebInspector.BreakpointManager.prototype.restoreDOMBreakpoints):
+ (WebInspector.DOMBreakpoint):
+ (WebInspector.DOMBreakpoint.prototype.populateLabelElement):
+ (WebInspector.EventListenerBreakpoint):
+ (WebInspector.XHRBreakpoint):
+ * inspector/front-end/BreakpointsSidebarPane.js:
+ (WebInspector.BreakpointsSidebarPane):
+ (WebInspector.BreakpointsSidebarPane.prototype.reset):
+ (WebInspector.EventListenerBreakpointsSidebarPane):
+ (WebInspector.EventListenerBreakpointsSidebarPane.prototype.reset):
+ * inspector/front-end/DOMAgent.js:
+ (WebInspector.DOMAgent.prototype._setDocument):
+ * inspector/front-end/ElementsPanel.js:
+ (WebInspector.ElementsPanel.prototype.reset):
+ * inspector/front-end/ElementsTreeOutline.js:
+ (WebInspector.ElementsTreeElement.prototype._populateTagContextMenu.handlerFunction):
+ (WebInspector.ElementsTreeElement.prototype._populateTagContextMenu):
+ * inspector/front-end/ScriptsPanel.js:
+ (WebInspector.ScriptsPanel.prototype.reset):
+ * inspector/front-end/inspector.js:
+ (WebInspector.reset):
+ (WebInspector.didCommitLoad):
+
2010-11-25 Peter Hartmann <peter.hartmann at nokia.com>
Reviewed by Andreas Kling.
diff --git a/WebCore/inspector/InspectorController.cpp b/WebCore/inspector/InspectorController.cpp
index 224477d..243b7ac 100644
--- a/WebCore/inspector/InspectorController.cpp
+++ b/WebCore/inspector/InspectorController.cpp
@@ -1426,13 +1426,15 @@ void InspectorController::setNativeBreakpoint(PassRefPtr<InspectorObject> breakp
} else if (type == domNativeBreakpointType) {
if (!m_domAgent)
return;
- String path;
- if (!condition->getString("path", &path))
+ double nodeIdNumber;
+ if (!condition->getNumber("nodeId", &nodeIdNumber))
return;
- double domBreakpointType;
- if (!condition->getNumber("type", &domBreakpointType))
+ double domBreakpointTypeNumber;
+ if (!condition->getNumber("type", &domBreakpointTypeNumber))
return;
- *breakpointId = m_domAgent->setDOMBreakpoint(path, static_cast<long>(domBreakpointType));
+ long nodeId = (long) nodeIdNumber;
+ long domBreakpointType = (long) domBreakpointTypeNumber;
+ *breakpointId = m_domAgent->setDOMBreakpoint(nodeId, domBreakpointType);
if (!breakpointId->isEmpty())
m_nativeBreakpoints.set(*breakpointId, type);
}
diff --git a/WebCore/inspector/InspectorDOMAgent.cpp b/WebCore/inspector/InspectorDOMAgent.cpp
index 41eb90a..894e4b2 100644
--- a/WebCore/inspector/InspectorDOMAgent.cpp
+++ b/WebCore/inspector/InspectorDOMAgent.cpp
@@ -223,7 +223,6 @@ InspectorDOMAgent::InspectorDOMAgent(InspectorCSSStore* cssStore, InspectorFront
, m_domListener(0)
, m_lastNodeId(1)
, m_matchJobsTimer(this, &InspectorDOMAgent::onMatchJobsTimer)
- , m_lastBreakpointId(0)
{
}
@@ -399,8 +398,6 @@ void InspectorDOMAgent::discardBindings()
m_childrenRequested.clear();
m_inspectedNodes.clear();
m_breakpoints.clear();
- m_idToBreakpoint.clear();
- m_breakpointToId.clear();
}
Node* InspectorDOMAgent::nodeForId(long id)
@@ -765,40 +762,36 @@ void InspectorDOMAgent::searchCanceled()
m_searchResults.clear();
}
-String InspectorDOMAgent::setDOMBreakpoint(const String& path, long type)
+String InspectorDOMAgent::setDOMBreakpoint(long nodeId, long type)
{
- Node* node = nodeForPath(path);
+ Node* node = nodeForId(nodeId);
if (!node)
return "";
- uint32_t rootBit = 1 << type;
- uint32_t mask = m_breakpoints.get(node);
- if (mask & rootBit)
+ String breakpointId = createBreakpointId(nodeId, type);
+ if (m_idToBreakpoint.contains(breakpointId))
return "";
- m_breakpoints.set(node, mask | rootBit);
+ m_idToBreakpoint.set(breakpointId, std::make_pair(nodeId, type));
+
+ uint32_t rootBit = 1 << type;
+ m_breakpoints.set(node, m_breakpoints.get(node) | rootBit);
if (rootBit & inheritableDOMBreakpointTypesMask) {
for (Node* child = innerFirstChild(node); child; child = innerNextSibling(child))
updateSubtreeBreakpoints(child, rootBit, true);
}
- String breakpointId = makeString("dom:", String::number(++m_lastBreakpointId));
- Breakpoint breakpoint(node, type);
- m_idToBreakpoint.set(breakpointId, breakpoint);
- m_breakpointToId.set(breakpoint, breakpointId);
return breakpointId;
}
void InspectorDOMAgent::removeDOMBreakpoint(const String& breakpointId)
{
- HashMap<String, Breakpoint>::iterator it = m_idToBreakpoint.find(breakpointId);
- if (it == m_idToBreakpoint.end())
+ Breakpoint breakpoint = m_idToBreakpoint.take(breakpointId);
+
+ Node* node = nodeForId(breakpoint.first);
+ if (!node)
return;
- Breakpoint breakpoint = it->second;
- m_idToBreakpoint.remove(it);
- m_breakpointToId.remove(breakpoint);
- Node* node = breakpoint.first;
uint32_t rootBit = 1 << breakpoint.second;
uint32_t mask = m_breakpoints.get(node) & ~rootBit;
if (mask)
@@ -869,8 +862,9 @@ PassRefPtr<InspectorValue> InspectorDOMAgent::descriptionForDOMEvent(Node* targe
description->setBoolean("insertion", insertion);
}
- String breakpointId = m_breakpointToId.get(Breakpoint(breakpointOwner, breakpointType));
- description->setString("breakpointId", breakpointId);
+ long breakpointOwnerNodeId = m_documentNodeToIdMap.get(breakpointOwner);
+ ASSERT(breakpointOwnerNodeId);
+ description->setString("breakpointId", createBreakpointId(breakpointOwnerNodeId, breakpointType));
return description;
}
@@ -1193,15 +1187,20 @@ void InspectorDOMAgent::removeBreakpointsForNode(Node* node)
uint32_t mask = m_breakpoints.take(node);
if (!mask)
return;
+ long nodeId = m_documentNodeToIdMap.get(node);
+ if (!nodeId)
+ return;
for (int type = 0; type < DOMBreakpointTypesCount; ++type) {
- if (mask & (1 << type)) {
- Breakpoint breakpoint(node, type);
- String breakpointId = m_breakpointToId.take(breakpoint);
- m_idToBreakpoint.remove(breakpointId);
- }
+ if (mask && (1 << type))
+ m_idToBreakpoint.remove(createBreakpointId(nodeId, type));
}
}
+String InspectorDOMAgent::createBreakpointId(long nodeId, long type)
+{
+ return makeString("dom:", String::number(nodeId), ':', String::number(type));
+}
+
void InspectorDOMAgent::getStyles(long nodeId, bool authorOnly, RefPtr<InspectorValue>* styles)
{
Node* node = nodeForId(nodeId);
diff --git a/WebCore/inspector/InspectorDOMAgent.h b/WebCore/inspector/InspectorDOMAgent.h
index 6655476..84ca027 100644
--- a/WebCore/inspector/InspectorDOMAgent.h
+++ b/WebCore/inspector/InspectorDOMAgent.h
@@ -158,7 +158,7 @@ namespace WebCore {
String documentURLString(Document* document) const;
- String setDOMBreakpoint(const String& path, long type);
+ String setDOMBreakpoint(long nodeId, long type);
void removeDOMBreakpoint(const String& breakpointId);
private:
@@ -178,6 +178,7 @@ namespace WebCore {
void updateSubtreeBreakpoints(Node* root, uint32_t rootMask, bool value);
void removeBreakpointsForNode(Node* node);
PassRefPtr<InspectorValue> descriptionForDOMEvent(Node* target, long breakpointType, bool insertion);
+ String createBreakpointId(long nodeId, long type);
PassRefPtr<InspectorObject> buildObjectForAttributeStyles(Element* element);
PassRefPtr<InspectorArray> buildArrayForCSSRules(Document* ownerDocument, CSSRuleList*);
@@ -232,10 +233,8 @@ namespace WebCore {
HashSet<RefPtr<Node> > m_searchResults;
Vector<long> m_inspectedNodes;
HashMap<Node*, uint32_t> m_breakpoints;
- typedef pair<Node*, long> Breakpoint;
+ typedef pair<long, long> Breakpoint;
HashMap<String, Breakpoint> m_idToBreakpoint;
- HashMap<Breakpoint, String> m_breakpointToId;
- unsigned int m_lastBreakpointId;
};
#endif
diff --git a/WebCore/inspector/front-end/BreakpointManager.js b/WebCore/inspector/front-end/BreakpointManager.js
index d120033..3d51092 100644
--- a/WebCore/inspector/front-end/BreakpointManager.js
+++ b/WebCore/inspector/front-end/BreakpointManager.js
@@ -88,7 +88,6 @@ WebInspector.BreakpointManager.prototype = {
this._breakpoints = {};
delete this._oneTimeBreakpoint;
this._nativeBreakpoints = {};
- this.dispatchEventToListeners("reset");
},
_setBreakpoint: function(sourceID, url, line, enabled, condition)
@@ -129,17 +128,16 @@ WebInspector.BreakpointManager.prototype = {
InspectorBackend.setBreakpoint(breakpoint.sourceID, breakpoint.line, breakpoint.enabled, breakpoint.condition, didSetBreakpoint.bind(this));
},
- createDOMBreakpoint: function(path, domEventType, disabled)
+ createDOMBreakpoint: function(nodeId, domEventType, disabled)
{
- var frontendId = "dom:" + path + ":" + domEventType;
+ var frontendId = "dom:" + nodeId + ":" + domEventType;
if (frontendId in this._nativeBreakpoints)
return;
- var breakpoint = new WebInspector.DOMBreakpoint(this, frontendId, path, domEventType);
+ var breakpoint = new WebInspector.DOMBreakpoint(this, frontendId, nodeId, domEventType);
this._nativeBreakpoints[frontendId] = breakpoint;
this.dispatchEventToListeners("dom-breakpoint-added", breakpoint);
breakpoint.enabled = !disabled;
- InspectorBackend.pushNodeByPathToFrontend(path, breakpoint.setNodeId.bind(breakpoint));
return breakpoint;
},
@@ -224,7 +222,8 @@ WebInspector.BreakpointManager.prototype = {
var persistentBreakpoints = [];
for (var id in this._nativeBreakpoints) {
var breakpoint = this._nativeBreakpoints[id];
- persistentBreakpoints.push({ type: breakpoint._type, enabled: breakpoint.enabled, condition: breakpoint._condition });
+ if (breakpoint._persistentCondition)
+ persistentBreakpoints.push({ type: breakpoint._type, enabled: breakpoint.enabled, condition: breakpoint._persistentCondition });
}
WebInspector.settings.nativeBreakpoints = persistentBreakpoints;
},
@@ -265,14 +264,41 @@ WebInspector.BreakpointManager.prototype = {
{
var breakpoints = this._persistentBreakpoints();
for (var i = 0; i < breakpoints.length; ++i) {
- var type = breakpoints[i].type;
- var condition = breakpoints[i].condition;
- if (type === "DOM")
- this.createDOMBreakpoint(condition.path, condition.type, !breakpoints[i].enabled);
- else if (type === "EventListener")
- this.createEventListenerBreakpoint(condition.eventName);
- else if (type === "XHR")
- this.createXHRBreakpoint(condition.url, !breakpoints[i].enabled);
+ if (breakpoints[i].type === "EventListener")
+ this.createEventListenerBreakpoint(breakpoints[i].condition.eventName);
+ else if (breakpoints[i].type === "XHR")
+ this.createXHRBreakpoint(breakpoints[i].condition.url, !breakpoints[i].enabled);
+ }
+ },
+
+ restoreDOMBreakpoints: function()
+ {
+ function didPushNodeByPathToFrontend(path, nodeId)
+ {
+ pathToNodeId[path] = nodeId;
+ pendingCalls -= 1;
+ if (pendingCalls)
+ return;
+ for (var i = 0; i < breakpoints.length; ++i) {
+ var breakpoint = breakpoints[i];
+ var nodeId = pathToNodeId[breakpoint.condition.path];
+ if (nodeId)
+ this.createDOMBreakpoint(nodeId, breakpoint.condition.type, !breakpoint.enabled);
+ }
+ }
+
+ var breakpoints = this._persistentBreakpoints();
+ var pathToNodeId = {};
+ var pendingCalls = 0;
+ for (var i = 0; i < breakpoints.length; ++i) {
+ if (breakpoints[i].type !== "DOM")
+ continue;
+ var path = breakpoints[i].condition.path;
+ if (path in pathToNodeId)
+ continue;
+ pathToNodeId[path] = 0;
+ pendingCalls += 1;
+ InspectorBackend.pushNodeByPathToFrontend(path, didPushNodeByPathToFrontend.bind(this, path));
}
},
@@ -443,26 +469,21 @@ WebInspector.NativeBreakpoint.prototype = {
WebInspector.NativeBreakpoint.prototype.__proto__ = WebInspector.Object.prototype;
-WebInspector.DOMBreakpoint = function(manager, frontendId, path, domEventType)
+WebInspector.DOMBreakpoint = function(manager, frontendId, nodeId, domEventType)
{
WebInspector.NativeBreakpoint.call(this, manager, frontendId, "DOM");
- this._path = path;
+ this._nodeId = nodeId;
this._domEventType = domEventType;
- this._condition = { path: this._path, type: this._domEventType };
+ this._condition = { nodeId: this._nodeId, type: this._domEventType };
+
+ var node = WebInspector.domAgent.nodeForId(this._nodeId);
+ if (node) {
+ node.breakpoints[this._domEventType] = this;
+ this._persistentCondition = { path: node.path(), type: this._domEventType };
+ }
}
WebInspector.DOMBreakpoint.prototype = {
- setNodeId: function(nodeId)
- {
- this._nodeId = nodeId;
- var node = WebInspector.domAgent.nodeForId(this._nodeId);
- if (node) {
- node.breakpoints[this._domEventType] = this;
- this.dispatchEventToListeners("label-changed");
- } else
- this.remove();
- },
-
compareTo: function(other)
{
return this._compare(this._domEventType, other._domEventType);
@@ -471,9 +492,6 @@ WebInspector.DOMBreakpoint.prototype = {
populateLabelElement: function(element)
{
// FIXME: this should belong to the view, not the manager.
- if (!this._nodeId)
- return;
-
var linkifiedNode = WebInspector.panels.elements.linkifyNodeById(this._nodeId);
linkifiedNode.addStyleClass("monospace");
element.appendChild(linkifiedNode);
@@ -526,6 +544,7 @@ WebInspector.EventListenerBreakpoint = function(manager, frontendId, eventName)
WebInspector.NativeBreakpoint.call(this, manager, frontendId, "EventListener");
this._eventName = eventName;
this._condition = { eventName: this._eventName };
+ this._persistentCondition = this._condition;
}
WebInspector.EventListenerBreakpoint.eventNameForUI = function(eventName)
@@ -570,6 +589,7 @@ WebInspector.XHRBreakpoint = function(manager, frontendId, url)
WebInspector.NativeBreakpoint.call(this, manager, frontendId, "XHR");
this._url = url;
this._condition = { url: this._url };
+ this._persistentCondition = this._condition;
}
WebInspector.XHRBreakpoint.prototype = {
diff --git a/WebCore/inspector/front-end/BreakpointsSidebarPane.js b/WebCore/inspector/front-end/BreakpointsSidebarPane.js
index 552fa88..47194da 100644
--- a/WebCore/inspector/front-end/BreakpointsSidebarPane.js
+++ b/WebCore/inspector/front-end/BreakpointsSidebarPane.js
@@ -35,12 +35,10 @@ WebInspector.BreakpointsSidebarPane = function(title)
this.emptyElement.textContent = WebInspector.UIString("No Breakpoints");
this.bodyElement.appendChild(this.emptyElement);
-
- WebInspector.breakpointManager.addEventListener("reset", this._reset, this);
}
WebInspector.BreakpointsSidebarPane.prototype = {
- _reset: function()
+ reset: function()
{
this.listElement.removeChildren();
if (this.listElement.parentElement) {
@@ -259,7 +257,6 @@ WebInspector.EventListenerBreakpointsSidebarPane = function()
this.bodyElement.appendChild(this.categoriesElement);
WebInspector.breakpointManager.addEventListener("event-listener-breakpoint-added", this._breakpointAdded, this);
- WebInspector.breakpointManager.addEventListener("reset", this._reset, this);
this._breakpointItems = {};
this._createCategory("Keyboard", "listener", ["keydown", "keyup", "keypress", "textInput"]);
@@ -386,7 +383,7 @@ WebInspector.EventListenerBreakpointsSidebarPane.prototype = {
categoryItem.checkbox.indeterminate = hasEnabled && hasDisabled;
},
- _reset: function()
+ reset: function()
{
for (var eventName in this._breakpointItems) {
var breakpointItem = this._breakpointItems[eventName];
diff --git a/WebCore/inspector/front-end/DOMAgent.js b/WebCore/inspector/front-end/DOMAgent.js
index ad1eb94..37bf549 100644
--- a/WebCore/inspector/front-end/DOMAgent.js
+++ b/WebCore/inspector/front-end/DOMAgent.js
@@ -379,6 +379,7 @@ WebInspector.DOMAgent.prototype = {
this.document = new WebInspector.DOMDocument(this, this._window, payload);
this._idToDOMNode[payload.id] = this.document;
this._bindNodes(this.document.children);
+ WebInspector.breakpointManager.restoreDOMBreakpoints();
} else
this.document = null;
WebInspector.panels.elements.setDocument(this.document);
diff --git a/WebCore/inspector/front-end/ElementsPanel.js b/WebCore/inspector/front-end/ElementsPanel.js
index b1cd24c..61ba33e 100644
--- a/WebCore/inspector/front-end/ElementsPanel.js
+++ b/WebCore/inspector/front-end/ElementsPanel.js
@@ -169,6 +169,9 @@ WebInspector.ElementsPanel.prototype = {
this.recentlyModifiedNodes = [];
delete this.currentQuery;
+
+ if (Preferences.nativeInstrumentationEnabled)
+ this.sidebarPanes.domBreakpoints.reset();
},
setDocument: function(inspectedRootDocument)
diff --git a/WebCore/inspector/front-end/ElementsTreeOutline.js b/WebCore/inspector/front-end/ElementsTreeOutline.js
index 20b3ac5..f893ca0 100644
--- a/WebCore/inspector/front-end/ElementsTreeOutline.js
+++ b/WebCore/inspector/front-end/ElementsTreeOutline.js
@@ -765,9 +765,9 @@ WebInspector.ElementsTreeElement.prototype = {
// Add debbuging-related actions
contextMenu.appendSeparator();
- function handlerFunction(path, breakType)
+ function handlerFunction(nodeId, breakType)
{
- WebInspector.breakpointManager.createDOMBreakpoint(path, breakType);
+ WebInspector.breakpointManager.createDOMBreakpoint(nodeId, breakType);
WebInspector.panels.elements.sidebarPanes.domBreakpoints.expand();
}
var node = this.representedObject;
@@ -776,7 +776,7 @@ WebInspector.ElementsTreeElement.prototype = {
var label = WebInspector.domBreakpointTypeContextMenuLabel(type);
var breakpoint = node.breakpoints[type];
if (!breakpoint)
- var handler = handlerFunction.bind(this, node.path(), type);
+ var handler = handlerFunction.bind(this, node.id, type);
else
var handler = breakpoint.remove.bind(breakpoint);
contextMenu.appendCheckboxItem(label, handler, !!breakpoint);
diff --git a/WebCore/inspector/front-end/ScriptsPanel.js b/WebCore/inspector/front-end/ScriptsPanel.js
index e018a2f..0a3c7a9 100644
--- a/WebCore/inspector/front-end/ScriptsPanel.js
+++ b/WebCore/inspector/front-end/ScriptsPanel.js
@@ -456,8 +456,15 @@ WebInspector.ScriptsPanel.prototype = {
this._sourceIDMap = {};
this.sidebarPanes.watchExpressions.refreshExpressions();
- if (!preserveItems)
+ if (!preserveItems) {
+ this.sidebarPanes.jsBreakpoints.reset();
+ if (Preferences.nativeInstrumentationEnabled) {
+ this.sidebarPanes.domBreakpoints.reset();
+ this.sidebarPanes.xhrBreakpoints.reset();
+ this.sidebarPanes.eventListenerBreakpoints.reset();
+ }
this.sidebarPanes.workers.reset();
+ }
},
get visibleView()
diff --git a/WebCore/inspector/front-end/inspector.js b/WebCore/inspector/front-end/inspector.js
index 0356dbb..78592ff 100644
--- a/WebCore/inspector/front-end/inspector.js
+++ b/WebCore/inspector/front-end/inspector.js
@@ -1375,6 +1375,8 @@ WebInspector.reset = function()
this.console.clearMessages();
this.extensionServer.notifyInspectorReset();
+
+ this.breakpointManager.restoreBreakpoints();
}
WebInspector.resetProfilesPanel = function()
@@ -1403,7 +1405,6 @@ WebInspector.didCommitLoad = function()
{
// Cleanup elements panel early on inspected page refresh.
WebInspector.setDocument(null);
- this.breakpointManager.restoreBreakpoints();
}
WebInspector.updateConsoleMessageExpiredCount = function(count)
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list