bug 1262233 - add ProxyAccessible::IsEmbeddedObject() r=lsocks
authorTrevor Saunders <tbsaunde@tbsaunde.org>
Mon, 04 Apr 2016 15:39:33 -0400
changeset 331804 6987bce671f5b70b99b2b7a7e0aee89e02faad11
parent 331803 dc6cc76f3c7e096d15b84bd7736c59723984dfec
child 331805 0efc1ab6080b7aa38f90050bc050790236e5c752
push id6048
push userkmoir@mozilla.com
push dateMon, 06 Jun 2016 19:02:08 +0000
treeherdermozilla-beta@46d72a56c57d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerslsocks
bugs1262233
milestone48.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
bug 1262233 - add ProxyAccessible::IsEmbeddedObject() r=lsocks
accessible/ipc/ProxyAccessible.h
--- a/accessible/ipc/ProxyAccessible.h
+++ b/accessible/ipc/ProxyAccessible.h
@@ -86,16 +86,27 @@ public:
 
   Accessible* OuterDocOfRemoteBrowser() const;
 
   /**
    * Get the role of the accessible we're proxying.
    */
   role Role() const { return mRole; }
 
+  /**
+   * Return true if this is an embedded object.
+   */
+  bool IsEmbeddedObject() const
+  {
+    role role = Role();
+    return role != roles::TEXT_LEAF &&
+           role != roles::WHITESPACE &&
+           role != roles::STATICTEXT;
+  }
+
   /*
    * Return the states for the proxied accessible.
    */
   uint64_t State() const;
 
   /*
    * Return the native states for the proxied accessible.
    */