Coverage Report

Created: 2018-09-25 14:53

/src/mozilla-central/dom/xhr/XMLHttpRequestEventTarget.h
Line
Count
Source (jump to first uncovered line)
1
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
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 file,
5
 * You can obtain one at http://mozilla.org/MPL/2.0/. */
6
7
#ifndef mozilla_dom_XMLHttpRequestEventTarget_h
8
#define mozilla_dom_XMLHttpRequestEventTarget_h
9
10
#include "mozilla/DOMEventTargetHelper.h"
11
12
namespace mozilla {
13
namespace dom {
14
15
class XMLHttpRequestEventTarget : public DOMEventTargetHelper
16
{
17
protected:
18
  explicit XMLHttpRequestEventTarget(DOMEventTargetHelper* aOwner)
19
    : DOMEventTargetHelper(aOwner)
20
0
  {}
21
22
  XMLHttpRequestEventTarget()
23
0
  {}
24
25
  virtual ~XMLHttpRequestEventTarget() {}
26
27
public:
28
  NS_DECL_ISUPPORTS_INHERITED
29
  NS_DECL_CYCLE_COLLECTION_CLASS_INHERITED(XMLHttpRequestEventTarget,
30
                                           DOMEventTargetHelper)
31
32
  IMPL_EVENT_HANDLER(loadstart)
33
  IMPL_EVENT_HANDLER(progress)
34
  IMPL_EVENT_HANDLER(abort)
35
  IMPL_EVENT_HANDLER(error)
36
  IMPL_EVENT_HANDLER(load)
37
  IMPL_EVENT_HANDLER(timeout)
38
  IMPL_EVENT_HANDLER(loadend)
39
40
  nsISupports* GetParentObject() const
41
  {
42
    return GetOwner();
43
  }
44
45
  virtual void DisconnectFromOwner() override;
46
};
47
48
} // dom namespace
49
} // mozilla namespace
50
51
#endif // mozilla_dom_XMLHttpRequestEventTarget_h