Coverage Report

Created: 2018-09-25 14:53

/work/obj-fuzz/dist/include/mozilla/dom/MediaTrackSettingsBinding.h
Line
Count
Source (jump to first uncovered line)
1
/* THIS FILE IS AUTOGENERATED FROM MediaTrackSettings.webidl BY Codegen.py - DO NOT EDIT */
2
3
#ifndef mozilla_dom_MediaTrackSettingsBinding_h
4
#define mozilla_dom_MediaTrackSettingsBinding_h
5
6
#include "GeckoProfiler.h"
7
#include "js/RootingAPI.h"
8
#include "jspubtd.h"
9
#include "mozilla/ErrorResult.h"
10
#include "mozilla/dom/BindingDeclarations.h"
11
#include "mozilla/dom/Nullable.h"
12
13
namespace mozilla {
14
namespace dom {
15
16
struct MediaTrackSettingsAtoms;
17
struct NativePropertyHooks;
18
class ProtoAndIfaceCache;
19
20
} // namespace dom
21
} // namespace mozilla
22
23
namespace mozilla {
24
namespace dom {
25
26
struct MediaTrackSettings : public DictionaryBase
27
{
28
  MOZ_INIT_OUTSIDE_CTOR Optional<bool> mAutoGainControl;
29
  MOZ_INIT_OUTSIDE_CTOR Optional<int64_t> mBrowserWindow;
30
  MOZ_INIT_OUTSIDE_CTOR Optional<int32_t> mChannelCount;
31
  MOZ_INIT_OUTSIDE_CTOR Optional<nsString> mDeviceId;
32
  MOZ_INIT_OUTSIDE_CTOR Optional<bool> mEchoCancellation;
33
  MOZ_INIT_OUTSIDE_CTOR Optional<nsString> mFacingMode;
34
  MOZ_INIT_OUTSIDE_CTOR Optional<double> mFrameRate;
35
  MOZ_INIT_OUTSIDE_CTOR Optional<int32_t> mHeight;
36
  MOZ_INIT_OUTSIDE_CTOR Optional<nsString> mMediaSource;
37
  MOZ_INIT_OUTSIDE_CTOR Optional<bool> mNoiseSuppression;
38
  MOZ_INIT_OUTSIDE_CTOR Optional<bool> mScrollWithPage;
39
  MOZ_INIT_OUTSIDE_CTOR Optional<int32_t> mViewportHeight;
40
  MOZ_INIT_OUTSIDE_CTOR Optional<int32_t> mViewportOffsetX;
41
  MOZ_INIT_OUTSIDE_CTOR Optional<int32_t> mViewportOffsetY;
42
  MOZ_INIT_OUTSIDE_CTOR Optional<int32_t> mViewportWidth;
43
  MOZ_INIT_OUTSIDE_CTOR Optional<int32_t> mWidth;
44
45
  MediaTrackSettings();
46
47
  explicit inline MediaTrackSettings(const FastDictionaryInitializer& )
48
0
  {
49
0
    // Do nothing here; this is used by our "Fast" subclass
50
0
  }
51
52
  explicit inline MediaTrackSettings(const MediaTrackSettings& aOther)
53
0
  {
54
0
    *this = aOther;
55
0
  }
56
57
  bool
58
  Init(JSContext* cx, JS::Handle<JS::Value> val, const char* sourceDescription = "Value", bool passedToJSImpl = false);
59
60
  bool
61
  Init(const nsAString& aJSON);
62
63
  bool
64
  ToObjectInternal(JSContext* cx, JS::MutableHandle<JS::Value> rval) const;
65
66
  bool
67
  ToJSON(nsAString& aJSON) const;
68
69
  void
70
  TraceDictionary(JSTracer* trc);
71
72
  MediaTrackSettings&
73
  operator=(const MediaTrackSettings& aOther);
74
75
private:
76
  static bool
77
  InitIds(JSContext* cx, MediaTrackSettingsAtoms* atomsCache);
78
};
79
80
namespace binding_detail {
81
struct FastMediaTrackSettings : public MediaTrackSettings
82
{
83
  inline FastMediaTrackSettings()
84
    : MediaTrackSettings(FastDictionaryInitializer())
85
0
  {
86
0
    // Doesn't matter what int we pass to the parent constructor
87
0
  }
88
};
89
} // namespace binding_detail
90
91
92
} // namespace dom
93
} // namespace mozilla
94
95
#endif // mozilla_dom_MediaTrackSettingsBinding_h