LCOV - code coverage report
Current view: top level - obj-x86_64-pc-linux-gnu/dom/bindings - ProgressEvent.cpp (source / functions) Hit Total Coverage
Test: output.info Lines: 29 38 76.3 %
Date: 2017-07-14 16:53:18 Functions: 12 16 75.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
       2             : /* vim:set ts=2 sw=2 sts=2 et cindent: */
       3             : /* This Source Code Form is subject to the terms of the Mozilla Public
       4             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       5             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
       6             : 
       7             : /* THIS FILE IS AUTOGENERATED FROM ProgressEvent.webidl BY Codegen.py - DO NOT EDIT */
       8             : 
       9             : #include "EventBinding.h"
      10             : #include "ProgressEvent.h"
      11             : #include "ProgressEventBinding.h"
      12             : #include "js/GCAPI.h"
      13             : #include "mozilla/dom/Nullable.h"
      14             : #include "mozilla/dom/PrimitiveConversions.h"
      15             : #include "mozilla/dom/ProgressEvent.h"
      16             : 
      17             : namespace mozilla {
      18             : namespace dom {
      19             : 
      20             : 
      21             : NS_IMPL_CYCLE_COLLECTION_CLASS(ProgressEvent)
      22             : 
      23          16 : NS_IMPL_ADDREF_INHERITED(ProgressEvent, Event)
      24          16 : NS_IMPL_RELEASE_INHERITED(ProgressEvent, Event)
      25             : 
      26           0 : NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INHERITED(ProgressEvent, Event)
      27           0 : NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
      28             : 
      29           8 : NS_IMPL_CYCLE_COLLECTION_TRACE_BEGIN_INHERITED(ProgressEvent, Event)
      30           8 : NS_IMPL_CYCLE_COLLECTION_TRACE_END
      31             : 
      32           0 : NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(ProgressEvent, Event)
      33           0 : NS_IMPL_CYCLE_COLLECTION_UNLINK_END
      34             : 
      35          80 : NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION_INHERITED(ProgressEvent)
      36          32 : NS_INTERFACE_MAP_END_INHERITING(Event)
      37             : 
      38          16 : ProgressEvent::ProgressEvent(mozilla::dom::EventTarget* aOwner)
      39          16 :   : Event(aOwner, nullptr, nullptr)
      40             : {
      41          16 : }
      42             : 
      43          16 : ProgressEvent::~ProgressEvent()
      44             : {
      45          24 : }
      46             : 
      47             : ProgressEvent*
      48           8 : ProgressEvent::AsProgressEvent()
      49             : {
      50           8 :   return this;
      51             : }
      52             : 
      53             : JSObject*
      54           0 : ProgressEvent::WrapObjectInternal(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
      55             : {
      56           0 :   return ProgressEventBinding::Wrap(aCx, this, aGivenProto);
      57             : }
      58             : 
      59             : already_AddRefed<ProgressEvent>
      60          16 : ProgressEvent::Constructor(mozilla::dom::EventTarget* aOwner, const nsAString& aType, const ProgressEventInit& aEventInitDict)
      61             : {
      62          32 :   RefPtr<ProgressEvent> e = new ProgressEvent(aOwner);
      63          16 :   bool trusted = e->Init(aOwner);
      64          16 :   e->InitEvent(aType, aEventInitDict.mBubbles, aEventInitDict.mCancelable);
      65          16 :   e->mLengthComputable = aEventInitDict.mLengthComputable;
      66          16 :   e->mLoaded = aEventInitDict.mLoaded;
      67          16 :   e->mTotal = aEventInitDict.mTotal;
      68          16 :   e->SetTrusted(trusted);
      69          16 :   e->SetComposed(aEventInitDict.mComposed);
      70          32 :   return e.forget();
      71             : }
      72             : 
      73             : already_AddRefed<ProgressEvent>
      74           0 : ProgressEvent::Constructor(const GlobalObject& aGlobal, const nsAString& aType, const ProgressEventInit& aEventInitDict, ErrorResult& aRv)
      75             : {
      76           0 :   nsCOMPtr<mozilla::dom::EventTarget> owner = do_QueryInterface(aGlobal.GetAsSupports());
      77           0 :   return Constructor(owner, aType, aEventInitDict);
      78             : }
      79             : 
      80             : bool
      81           8 : ProgressEvent::LengthComputable() const
      82             : {
      83           8 :   return mLengthComputable;
      84             : }
      85             : 
      86             : uint64_t
      87           8 : ProgressEvent::Loaded() const
      88             : {
      89           8 :   return mLoaded;
      90             : }
      91             : 
      92             : uint64_t
      93           8 : ProgressEvent::Total() const
      94             : {
      95           8 :   return mTotal;
      96             : }
      97             : 
      98             : 
      99             : } // namespace dom
     100             : } // namespace mozilla

Generated by: LCOV version 1.13