Bug 1560374 - Set testharness and reftest web-platform-tests to Tier-1; r=jmaher...
[gecko.git] / dom / html / HTMLMapElement.h
blob46290c7cfc9589d8541300344597432f2120eae4
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
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef mozilla_dom_HTMLMapElement_h
8 #define mozilla_dom_HTMLMapElement_h
10 #include "mozilla/Attributes.h"
11 #include "nsGenericHTMLElement.h"
12 #include "nsGkAtoms.h"
14 class nsContentList;
16 namespace mozilla {
17 namespace dom {
19 class HTMLMapElement final : public nsGenericHTMLElement {
20 public:
21 explicit HTMLMapElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
23 // nsISupports
24 NS_DECL_ISUPPORTS_INHERITED
26 virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
28 NS_DECL_CYCLE_COLLECTION_CLASS_INHERITED_NO_UNLINK(HTMLMapElement,
29 nsGenericHTMLElement)
31 void GetName(nsAString& aValue) { GetHTMLAttr(nsGkAtoms::name, aValue); }
32 void SetName(const nsAString& aName, ErrorResult& aError) {
33 SetHTMLAttr(nsGkAtoms::name, aName, aError);
35 nsIHTMLCollection* Areas();
37 virtual JSObject* WrapNode(JSContext* aCx,
38 JS::Handle<JSObject*> aGivenProto) override;
40 protected:
41 ~HTMLMapElement() {}
43 RefPtr<nsContentList> mAreas;
46 } // namespace dom
47 } // namespace mozilla
49 #endif // mozilla_dom_HTMLMapElement_h