/* -*- 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 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ #ifndef DOM_VIEWTRANSITIONTYPESET_H_ #define DOM_VIEWTRANSITIONTYPESET_H_ #include "nsCycleCollectionParticipant.h" #include "nsWrapperCache.h" namespace mozilla { class ErrorResult; namespace dom { class ViewTransition; class ViewTransitionTypeSet final : public nsISupports, public nsWrapperCache { public: NS_DECL_CYCLE_COLLECTING_ISUPPORTS NS_DECL_CYCLE_COLLECTION_WRAPPERCACHE_CLASS(ViewTransitionTypeSet) public: explicit ViewTransitionTypeSet(ViewTransition&); MOZ_CAN_RUN_SCRIPT ViewTransitionTypeSet* Add(const nsAString&, ErrorResult&); MOZ_CAN_RUN_SCRIPT void Clear(ErrorResult&); MOZ_CAN_RUN_SCRIPT bool Delete(const nsAString&, ErrorResult&); protected: ~ViewTransitionTypeSet(); public: nsISupports* GetParentObject() const; JSObject* WrapObject(JSContext* aCx, JS::Handle aGivenProto) override; RefPtr mTransition; }; } // namespace dom } // namespace mozilla #endif // DOM_VIEWTRANSITIONTYPESET_H_