moebius#161: The Performance Resource Timing (make timestamps be relative to startTime)

https://github.com/MoonchildProductions/moebius/pull/161
This commit is contained in:
janekptacijarabaci 2018-04-29 14:15:18 +02:00 • committed by Roy Tam
commit e8dbb561f6
20 changed files with 520 additions and 154 deletions

View file

@ -18,7 +18,7 @@ namespace mozilla {
namespace dom {
// http://www.w3.org/TR/resource-timing/#performanceresourcetiming
class PerformanceResourceTiming final : public PerformanceEntry
class PerformanceResourceTiming : public PerformanceEntry
{
public:
typedef mozilla::TimeStamp TimeStamp;
@ -30,7 +30,8 @@ public:
PerformanceResourceTiming(PerformanceTiming* aPerformanceTiming,
Performance* aPerformance,
const nsAString& aName);
const nsAString& aName,
nsIHttpChannel* aChannel = nullptr);
virtual JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override;
@ -176,6 +177,7 @@ public:
protected:
virtual ~PerformanceResourceTiming();
void SetPropertiesFromChannel(nsIHttpChannel* aChannel);
nsString mInitiatorType;
nsString mNextHopProtocol;