| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
| 3 * Copyright (C) 2012 Intel Inc. All rights reserved. | 3 * Copyright (C) 2012 Intel Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 59 ASSERT(m_referenceTime); | 59 ASSERT(m_referenceTime); |
| 60 ScriptWrappable::init(this); | 60 ScriptWrappable::init(this); |
| 61 } | 61 } |
| 62 | 62 |
| 63 Performance::~Performance() | 63 Performance::~Performance() |
| 64 { | 64 { |
| 65 } | 65 } |
| 66 | 66 |
| 67 const AtomicString& Performance::interfaceName() const | 67 const AtomicString& Performance::interfaceName() const |
| 68 { | 68 { |
| 69 return eventNames().interfaceForPerformance; | 69 return EventTargetNames::Performance; |
| 70 } | 70 } |
| 71 | 71 |
| 72 ExecutionContext* Performance::executionContext() const | 72 ExecutionContext* Performance::executionContext() const |
| 73 { | 73 { |
| 74 if (!frame()) | 74 if (!frame()) |
| 75 return 0; | 75 return 0; |
| 76 return frame()->document(); | 76 return frame()->document(); |
| 77 } | 77 } |
| 78 | 78 |
| 79 PassRefPtr<MemoryInfo> Performance::memory() const | 79 PassRefPtr<MemoryInfo> Performance::memory() const |
| (...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 275 m_userTiming = UserTiming::create(this); | 275 m_userTiming = UserTiming::create(this); |
| 276 m_userTiming->clearMeasures(measureName); | 276 m_userTiming->clearMeasures(measureName); |
| 277 } | 277 } |
| 278 | 278 |
| 279 double Performance::now() const | 279 double Performance::now() const |
| 280 { | 280 { |
| 281 return 1000.0 * (monotonicallyIncreasingTime() - m_referenceTime); | 281 return 1000.0 * (monotonicallyIncreasingTime() - m_referenceTime); |
| 282 } | 282 } |
| 283 | 283 |
| 284 } // namespace WebCore | 284 } // namespace WebCore |
| OLD | NEW |