summaryrefslogtreecommitdiffstats
path: root/dom/workers
diff options
context:
space:
mode:
authorjanekptacijarabaci <janekptacijarabaci@seznam.cz>2018-04-29 12:35:55 +0200
committerjanekptacijarabaci <janekptacijarabaci@seznam.cz>2018-04-29 12:35:55 +0200
commiteeaf0a73acf661662b9baf9929c9688c60d0bf38 (patch)
treeef7ef4082282eb967220c1493c07084c97cfc7c0 /dom/workers
parent089a0bd9a4dace03e5800878055b86854eee5002 (diff)
downloadUXP-eeaf0a73acf661662b9baf9929c9688c60d0bf38.tar
UXP-eeaf0a73acf661662b9baf9929c9688c60d0bf38.tar.gz
UXP-eeaf0a73acf661662b9baf9929c9688c60d0bf38.tar.lz
UXP-eeaf0a73acf661662b9baf9929c9688c60d0bf38.tar.xz
UXP-eeaf0a73acf661662b9baf9929c9688c60d0bf38.zip
Bug 1322292 - Some fixes for the Performance API in workers - part 3 - TimeStampToDOMHighRes() in workerPrivate
https://hg.mozilla.org/mozilla-central/rev/b827e4d0dc73
Diffstat (limited to 'dom/workers')
-rw-r--r--dom/workers/WorkerPrivate.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/dom/workers/WorkerPrivate.h b/dom/workers/WorkerPrivate.h
index e15beb955..28283bed7 100644
--- a/dom/workers/WorkerPrivate.h
+++ b/dom/workers/WorkerPrivate.h
@@ -577,6 +577,13 @@ public:
return mCreationTimeHighRes;
}
+ DOMHighResTimeStamp TimeStampToDOMHighRes(const TimeStamp& aTimeStamp) const
+ {
+ MOZ_ASSERT(!aTimeStamp.IsNull());
+ TimeDuration duration = aTimeStamp - mCreationTimeStamp;
+ return duration.ToMilliseconds();
+ }
+
nsIPrincipal*
GetPrincipal() const
{