1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ 2 /* This Source Code Form is subject to the terms of the Mozilla Public 3 * License, v. 2.0. If a copy of the MPL was not distributed with this 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 5 6 #ifndef _nsAccessibleRelation_H_ 7 #define _nsAccessibleRelation_H_ 8 9 #include "nsIAccessibleRelation.h" 10 11 #include "nsCOMPtr.h" 12 #include "nsTArray.h" 13 #include "nsIMutableArray.h" 14 #include "mozilla/Attributes.h" 15 #include "mozilla/a11y/ProxyAccessible.h" 16 17 namespace mozilla { 18 namespace a11y { 19 20 class Relation; 21 22 /** 23 * Class represents an accessible relation. 24 */ 25 class nsAccessibleRelation final : public nsIAccessibleRelation 26 { 27 public: 28 nsAccessibleRelation(uint32_t aType, Relation* aRel); 29 30 nsAccessibleRelation(uint32_t aType, 31 const nsTArray<ProxyAccessible*>* aTargets); 32 33 NS_DECL_ISUPPORTS 34 NS_DECL_NSIACCESSIBLERELATION 35 36 private: 37 nsAccessibleRelation(); 38 ~nsAccessibleRelation(); 39 40 nsAccessibleRelation(const nsAccessibleRelation&); 41 nsAccessibleRelation& operator = (const nsAccessibleRelation&); 42 43 uint32_t mType; 44 nsCOMPtr<nsIMutableArray> mTargets; 45 }; 46 47 } // namespace a11y 48 } // namespace mozilla 49 50 #endif 51