Index: tracing/tracing/model/model.html |
diff --git a/tracing/tracing/model/model.html b/tracing/tracing/model/model.html |
index dbc4e2cc62a51149b5e1e67da1063688849ee0e0..b47840a5d9e0e72f25f3845c4e19b8b305a8ebb7 100644 |
--- a/tracing/tracing/model/model.html |
+++ b/tracing/tracing/model/model.html |
@@ -110,11 +110,22 @@ tr.exportTo('tr', function() { |
this.doesHelperGUIDSupportThisModel_ = {}; |
this.helpersByConstructorGUID_ = {}; |
+ this.eventsByStableId_ = undefined; |
} |
Model.prototype = { |
__proto__: tr.model.EventContainer.prototype, |
+ getEventByStableId: function(stableId) { |
+ if (this.eventsByStableId_ === undefined) { |
+ this.eventsByStableId_ = {}; |
+ this.iterateAllEvents(function(event) { |
+ this.eventsByStableId_[event.stableId] = event; |
+ }, this); |
+ } |
+ return this.eventsByStableId_[stableId]; |
+ }, |
+ |
getOrCreateHelper: function(constructor) { |
if (!constructor.guid) |
throw new Error('Helper constructors must have GUIDs'); |