summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--webkit/glue/devtools/js/devtools.js10
-rw-r--r--webkit/glue/devtools/js/inspector_controller.js3
2 files changed, 13 insertions, 0 deletions
diff --git a/webkit/glue/devtools/js/devtools.js b/webkit/glue/devtools/js/devtools.js
index 47034a4..522e698 100644
--- a/webkit/glue/devtools/js/devtools.js
+++ b/webkit/glue/devtools/js/devtools.js
@@ -426,3 +426,13 @@ WebInspector.ResourcesPanel.prototype._createResourceView = function(
return orig.apply(this, arguments);
};
})();
+
+// Temporary workaround for a patch from WebKit bug 30328.
+// TODO(mnaganov): Remove when after WebKit roll.
+if (!('addProfile' in WebInspector)) {
+ WebInspector.addProfile = function(profile) {
+ WebInspector.__fullProfiles = WebInspector.__fullProfiles || {};
+ WebInspector.__fullProfiles[profile.uid] = profile;
+ WebInspector.addProfileHeader(profile);
+ };
+}
diff --git a/webkit/glue/devtools/js/inspector_controller.js b/webkit/glue/devtools/js/inspector_controller.js
index 435d26e..474b0b5 100644
--- a/webkit/glue/devtools/js/inspector_controller.js
+++ b/webkit/glue/devtools/js/inspector_controller.js
@@ -466,6 +466,9 @@ devtools.InspectorController.prototype.getProfileHeaders = function(callId) {
* Async function for lazy loading an existing profile.
*/
devtools.InspectorController.prototype.getProfile = function(callId, uid) {
+ if (WebInspector.__fullProfiles && (uid in WebInspector.__fullProfiles)) {
+ WebInspector.didGetProfile(callId, WebInspector.__fullProfiles[uid]);
+ }
};