/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim:set ts=2 sw=2 sts=2 et cindent: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
/* THIS FILE IS AUTOGENERATED FROM CharacterBoundsUpdateEvent.webidl BY Codegen.py - DO NOT EDIT */
#include "CharacterBoundsUpdateEvent.h"
#include "CharacterBoundsUpdateEventBinding.h"
#include "EventBinding.h"
#include "js/GCAPI.h"
#include "mozilla/HoldDropJSObjects.h"
#include "mozilla/dom/BindingCallContext.h"
#include "mozilla/dom/CharacterBoundsUpdateEvent.h"
#include "mozilla/dom/Nullable.h"
#include "mozilla/dom/PrimitiveConversions.h"
namespace mozilla::dom {
CharacterBoundsUpdateEvent::CharacterBoundsUpdateEvent(mozilla::dom::EventTarget* aOwner)
: Event(aOwner, nullptr, nullptr)
{
}
CharacterBoundsUpdateEvent::~CharacterBoundsUpdateEvent()
{
}
CharacterBoundsUpdateEvent*
CharacterBoundsUpdateEvent::AsCharacterBoundsUpdateEvent()
{
return this;
}
JSObject*
CharacterBoundsUpdateEvent::WrapObjectInternal(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
{
return CharacterBoundsUpdateEvent_Binding::Wrap(aCx, this, aGivenProto);
}
already_AddRefed<CharacterBoundsUpdateEvent>
CharacterBoundsUpdateEvent::Constructor(mozilla::dom::EventTarget* aOwner, const nsAString& aType, const CharacterBoundsUpdateEventInit& aOptions)
{
RefPtr<CharacterBoundsUpdateEvent> e = new CharacterBoundsUpdateEvent(aOwner);
bool trusted = e->Init(aOwner);
e->InitEvent(aType, aOptions.mBubbles, aOptions.mCancelable);
e->mRangeStart = aOptions.mRangeStart;
e->mRangeEnd = aOptions.mRangeEnd;
e->SetTrusted(trusted);
e->SetComposed(aOptions.mComposed);
return e.forget();
}
already_AddRefed<CharacterBoundsUpdateEvent>
CharacterBoundsUpdateEvent::Constructor(const GlobalObject& aGlobal, const nsAString& aType, const CharacterBoundsUpdateEventInit& aOptions)
{
nsCOMPtr<mozilla::dom::EventTarget> owner = do_QueryInterface(aGlobal.GetAsSupports());
return Constructor(owner, aType, aOptions);
}
uint32_t
CharacterBoundsUpdateEvent::RangeStart() const
{
return mRangeStart;
}
uint32_t
CharacterBoundsUpdateEvent::RangeEnd() const
{
return mRangeEnd;
}
} // namespace mozilla::dom