Update ATSPI code according to DALi coding rule 81/260281/9
authorSeoyeon Kim <seoyeon2.kim@samsung.com>
Wed, 23 Jun 2021 06:11:07 +0000 (15:11 +0900)
committerSeoyeon Kim <seoyeon2.kim@samsung.com>
Mon, 5 Jul 2021 06:37:18 +0000 (15:37 +0900)
- Updated accessibility and bridge code, such as description or coding style.
- Changed 'Caret' to 'Cursor' for dali text style.

The patches below should be applied together.
https://review.tizen.org/gerrit/#/c/platform/core/uifw/dali-toolkit/+/260282/
https://review.tizen.org/gerrit/#/c/platform/core/uifw/dali-csharp-binder/+/260322/

Change-Id: Ie1a2f0185ed90846fba61a999bcea81038621ae0
Signed-off-by: Seoyeon Kim <seoyeon2.kim@samsung.com>
22 files changed:
dali/devel-api/adaptor-framework/accessibility-impl.cpp
dali/devel-api/adaptor-framework/accessibility-impl.h
dali/devel-api/adaptor-framework/accessibility.h
dali/devel-api/adaptor-framework/atspi-accessibility.cpp
dali/internal/accessibility/bridge/accessible.cpp
dali/internal/accessibility/bridge/bridge-accessible.cpp
dali/internal/accessibility/bridge/bridge-accessible.h
dali/internal/accessibility/bridge/bridge-base.cpp
dali/internal/accessibility/bridge/bridge-base.h
dali/internal/accessibility/bridge/bridge-component.cpp
dali/internal/accessibility/bridge/bridge-component.h
dali/internal/accessibility/bridge/bridge-impl.cpp
dali/internal/accessibility/bridge/bridge-object.cpp
dali/internal/accessibility/bridge/bridge-object.h
dali/internal/accessibility/bridge/bridge-text.cpp
dali/internal/accessibility/bridge/bridge-text.h
dali/internal/accessibility/bridge/component.cpp
dali/internal/accessibility/bridge/dummy-atspi.cpp
dali/internal/accessibility/bridge/dummy-atspi.h
dali/internal/adaptor/common/adaptor-impl.cpp
dali/internal/adaptor/common/adaptor-impl.h
dali/internal/window-system/common/window-impl.cpp

index dfbaa4d..48b1a10 100644 (file)
@@ -547,27 +547,27 @@ std::string Accessible::GetRoleName()
 
 Dali::Actor Accessible::GetCurrentlyHighlightedActor()
 {
-  return IsUp() ? Bridge::GetCurrentBridge()->data->currentlyHighlightedActor : Dali::Actor{};
+  return IsUp() ? Bridge::GetCurrentBridge()->mData->mCurrentlyHighlightedActor : Dali::Actor{};
 }
 
 void Accessible::SetCurrentlyHighlightedActor(Dali::Actor actor)
 {
   if(IsUp())
   {
-    Bridge::GetCurrentBridge()->data->currentlyHighlightedActor = actor;
+    Bridge::GetCurrentBridge()->mData->mCurrentlyHighlightedActor = actor;
   }
 }
 
 Dali::Actor Accessible::GetHighlightActor()
 {
-  return IsUp() ? Bridge::GetCurrentBridge()->data->highlightActor : Dali::Actor{};
+  return IsUp() ? Bridge::GetCurrentBridge()->mData->mHighlightActor : Dali::Actor{};
 }
 
 void Accessible::SetHighlightActor(Dali::Actor actor)
 {
   if(IsUp())
   {
-    Bridge::GetCurrentBridge()->data->highlightActor = actor;
+    Bridge::GetCurrentBridge()->mData->mHighlightActor = actor;
   }
 }
 
@@ -576,18 +576,18 @@ void Bridge::ForceDown()
   auto highlighted = Accessible::GetCurrentlyHighlightedActor();
   if(highlighted)
   {
-    auto p = dynamic_cast<Component*>(Accessible::Get(highlighted));
-    if(p)
+    auto component = dynamic_cast<Component*>(Accessible::Get(highlighted));
+    if(component)
     {
-      p->ClearHighlight();
+      component->ClearHighlight();
     }
   }
-  data = {};
+  mData = {};
 }
 
-void Bridge::SetIsOnRootLevel(Accessible* o)
+void Bridge::SetIsOnRootLevel(Accessible* owner)
 {
-  o->isOnRootLevel = true;
+  owner->mIsOnRootLevel = true;
 }
 
 namespace
@@ -595,12 +595,12 @@ namespace
 class NonControlAccessible : public virtual Accessible, public virtual Collection, public virtual Component
 {
 protected:
-  Dali::WeakHandle<Dali::Actor> self;
-  bool                          root = false;
+  Dali::WeakHandle<Dali::Actor> mSelf;
+  bool                          mRoot = false;
 
   Dali::Actor Self()
   {
-    auto handle = self.GetHandle();
+    auto handle = mSelf.GetHandle();
 
     // NonControlAccessible is deleted on ObjectDestroyedSignal
     // for the respective actor (see `nonControlAccessibles`).
@@ -610,13 +610,13 @@ protected:
   }
 
 public:
-  NonControlAccessible(Dali::Actor actor, bool root)
-  : self(actor),
-    root(root)
+  NonControlAccessible(Dali::Actor actor, bool isRoot)
+  : mSelf(actor),
+    mRoot(isRoot)
   {
   }
 
-  Dali::Rect<> GetExtents(Dali::Accessibility::CoordType ctype) override
+  Dali::Rect<> GetExtents(Dali::Accessibility::CoordinateType type) override
   {
     Dali::Actor actor                   = Self();
     Vector2     screenPosition          = actor.GetProperty(Actor::Property::SCREEN_POSITION).Get<Vector2>();
@@ -627,64 +627,77 @@ public:
 
     return {position.x, position.y, size.x, size.y};
   }
+
   Dali::Accessibility::ComponentLayer GetLayer() override
   {
     return Dali::Accessibility::ComponentLayer::WINDOW;
   }
-  int16_t GetMdiZOrder()
+
+  int16_t GetMdiZOrder() override
   {
     return 0;
   }
-  double GetAlpha()
+
+  double GetAlpha() override
   {
     return 0;
   }
+
   bool GrabFocus() override
   {
     return false;
   }
+
   bool GrabHighlight() override
   {
     return false;
   }
+
   bool ClearHighlight() override
   {
     return false;
   }
+
   bool IsScrollable() override
   {
     return false;
   }
+
   std::string GetName() override
   {
     return Self().GetProperty<std::string>(Dali::Actor::Property::NAME);
   }
+
   std::string GetDescription() override
   {
     return "";
   }
+
   Accessible* GetParent() override
   {
-    if(GetIsOnRootLevel())
+    if(IsOnRootLevel())
     {
-      auto b = GetBridgeData();
-      return b->bridge->GetApplication();
+      auto data = GetBridgeData();
+      return data->mBridge->GetApplication();
     }
     return Get(Self().GetParent());
   }
+
   size_t GetChildCount() override
   {
     return static_cast<size_t>(Self().GetChildCount());
   }
+
   Accessible* GetChildAtIndex(size_t index) override
   {
-    auto s = static_cast<size_t>(Self().GetChildCount());
-    if(index >= s)
+    auto numberOfChildren = static_cast<size_t>(Self().GetChildCount());
+    if(index >= numberOfChildren)
     {
-      throw std::domain_error{"invalid index " + std::to_string(index) + " for object with " + std::to_string(s) + " children"};
+      throw std::domain_error{"invalid index " + std::to_string(index) + " for object with " + std::to_string(numberOfChildren) + " children"};
     }
     return Get(Self().GetChildAt(static_cast<unsigned int>(index)));
   }
+
   size_t GetIndexInParent() override
   {
     auto parent = Self().GetParent();
@@ -702,34 +715,38 @@ public:
     }
     throw std::domain_error{"actor is not a child of it's parent"};
   }
+
   Role GetRole() override
   {
-    return root ? Role::WINDOW : Role::REDUNDANT_OBJECT;
+    return mRoot ? Role::WINDOW : Role::REDUNDANT_OBJECT;
   }
+
   States GetStates() override
   {
-    States s;
-    if(root)
+    States state;
+    if(mRoot)
     {
-      s[State::ENABLED]   = true;
-      s[State::SENSITIVE] = true;
-      s[State::SHOWING]   = true;
-      s[State::VISIBLE]   = true;
-      s[State::ACTIVE]    = true;
+      state[State::ENABLED]   = true;
+      state[State::SENSITIVE] = true;
+      state[State::SHOWING]   = true;
+      state[State::VISIBLE]   = true;
+      state[State::ACTIVE]    = true;
     }
     else
     {
-      auto t            = GetParent()->GetStates();
-      s[State::SHOWING] = t[State::SHOWING];
-      s[State::VISIBLE] = t[State::VISIBLE];
+      auto parentState = GetParent()->GetStates();
+      state[State::SHOWING] = parentState[State::SHOWING];
+      state[State::VISIBLE] = parentState[State::VISIBLE];
     }
-    return s;
+    return state;
   }
+
   Attributes GetAttributes() override
   {
     Dali::TypeInfo type;
     Self().GetTypeInfo(type);
-    return {
+    return
+    {
       {"class", type.GetName()},
     };
   }
@@ -766,12 +783,13 @@ void Accessible::RegisterControlAccessibilityGetter(std::function<Accessible*(Da
   convertingFunctor = functor;
 }
 
-Accessible* Accessible::Get(Dali::Actor actor, bool root)
+Accessible* Accessible::Get(Dali::Actor actor, bool isRoot)
 {
   if(!actor)
   {
     return nullptr;
   }
+
   auto accessible = convertingFunctor(actor);
   if(!accessible)
   {
@@ -781,12 +799,12 @@ Accessible* Accessible::Get(Dali::Actor actor, bool root)
         nonControlAccessibles.erase(obj);
       });
     }
-    auto it = nonControlAccessibles.emplace(&actor.GetBaseObject(), nullptr);
-    if(it.second)
+    auto pair = nonControlAccessibles.emplace(&actor.GetBaseObject(), nullptr);
+    if(pair.second)
     {
-      it.first->second.reset(new NonControlAccessible(actor, root));
+      pair.first->second.reset(new NonControlAccessible(actor, isRoot));
     }
-    accessible = it.first->second.get();
+    accessible = pair.first->second.get();
   }
   return accessible;
 }
index f8032fc..304f2c1 100644 (file)
@@ -49,7 +49,7 @@ class DALI_ADAPTOR_API Collection;
 class DALI_ADAPTOR_API Action;
 
 /**
- * @brief Base class for different accessibility bridges
+ * @brief Base class for different accessibility bridges.
  *
  * Bridge is resposible for initializing and managing connection on accessibility bus.
  * Accessibility clients will not get any information about UI without initialized and upraised bridge.
@@ -71,84 +71,94 @@ struct DALI_ADAPTOR_API Bridge
   virtual ~Bridge() = default;
 
   /**
-   * @brief Get bus name which bridge is initialized on
+   * @brief Gets bus name which bridge is initialized on.
    */
   virtual const std::string& GetBusName() const = 0;
 
   /**
-   * @brief Registers top level window
+   * @brief Registers top level window.
    *
    * Hierarchy of objects visible for accessibility clients is based on tree-like
    * structure created from Actors objects. This method allows to connect chosen
    * object as direct ancestor of application and therefore make it visible for
    * accessibility clients.
+   *
+   * @param[in] object The accessible object
    */
-  virtual void AddTopLevelWindow(Accessible*) = 0;
+  virtual void AddTopLevelWindow(Accessible* object) = 0;
 
   /**
-   * @brief Removes top level window
+   * @brief Removes top level window.
    *
    * Hierarchy of objects visible for accessibility clients is based on tree-like
    * structure created from Actors objects. This method removes previously added
    * window from visible accessibility objects.
+   *
+   * @param[in] object The accessible object
    */
-  virtual void RemoveTopLevelWindow(Accessible*) = 0;
+  virtual void RemoveTopLevelWindow(Accessible* object) = 0;
 
   /**
-   * @brief Adds popup window
+   * @brief Adds popup window.
    *
    * Hierarchy of objects visible for accessibility clients is based on tree-like
    * structure created from Actors objects. This method adds new popup to the tree.
+   *
+   * @param[in] object The accessible object
    */
-  virtual void AddPopup(Accessible*) = 0;
+  virtual void AddPopup(Accessible* object) = 0;
 
   /**
-   * @brief Removes popup window
+   * @brief Removes popup window.
    *
    * Hierarchy of objects visible for accessibility clients is based on tree-like
    * structure created from Actors objects. This method removes previously added
    * popup window.
+   *
+   * @param[in] object The accessible object
    */
-  virtual void RemovePopup(Accessible*) = 0;
+  virtual void RemovePopup(Accessible* object) = 0;
 
   /**
-   * @brief Set name of current application which will be visible on accessibility bus
+   * @brief Sets name of current application which will be visible on accessibility bus.
+   *
+   * @param[in] name The application name
    */
-  virtual void SetApplicationName(std::string) = 0;
+  virtual void SetApplicationName(std::string name) = 0;
 
   /**
-   * @brief Get object being root of accessibility tree
+   * @brief Gets object being root of accessibility tree.
    *
    * @return handler to accessibility object
    */
   virtual Accessible* GetApplication() const = 0;
 
   /**
-   * @brief Find an object in accessibility tree
+   * @brief Finds an object in accessibility tree.
    *
-   * @param[in] s path to object
+   * @param[in] path The path to object
    *
-   * @return handler to accessibility object
+   * @return The handler to accessibility object
    */
-  virtual Accessible* FindByPath(const std::string& s) const = 0;
+  virtual Accessible* FindByPath(const std::string& path) const = 0;
 
   /**
-   * @brief Show application on accessibility bus
+   * @brief Shows application on accessibility bus.
    */
   virtual void ApplicationShown() = 0;
 
   /**
-   * @brief Hide application on accessibility bus
+   * @brief Hides application on accessibility bus.
    */
   virtual void ApplicationHidden() = 0;
 
   /**
-   * @brief Initialize accessibility bus
+   * @brief Initializes accessibility bus.
    */
   virtual void Initialize() = 0;
 
   /**
-   * @brief Terminate accessibility bus
+   * @brief Terminates accessibility bus.
    */
   virtual void Terminate() = 0;
 
@@ -157,12 +167,12 @@ struct DALI_ADAPTOR_API Bridge
    */
   virtual ForceUpResult ForceUp()
   {
-    if(data)
+    if(mData)
     {
       return ForceUpResult::ALREADY_UP;
     }
-    data         = std::make_shared<Data>();
-    data->bridge = this;
+    mData = std::make_shared<Data>();
+    mData->mBridge = this;
     return ForceUpResult::JUST_STARTED;
   }
 
@@ -172,46 +182,73 @@ struct DALI_ADAPTOR_API Bridge
   virtual void ForceDown() = 0;
 
   /**
-   * @brief Check if bridge is activated or not.
+   * @brief Checks if bridge is activated or not.
    * @return True if brige is activated.
    */
   bool IsUp() const
   {
-    return bool(data);
+    return bool(mData);
   }
 
   /**
-   * @brief Emits caret-moved event on at-spi bus.
+   * @brief Emits cursor-moved event on at-spi bus.
+   *
+   * @param[in] obj The accessible object
+   * @param[in] cursorPosition The new cursor position
    **/
-  virtual void EmitCaretMoved(Accessible* obj, unsigned int cursorPosition) = 0;
+  virtual void EmitCursorMoved(Accessible* obj, unsigned int cursorPosition) = 0;
 
   /**
    * @brief Emits active-descendant-changed event on at-spi bus.
+   *
+   * @param[in] obj The accessible object
+   * @param[in] child The child of the object
    **/
   virtual void EmitActiveDescendantChanged(Accessible* obj, Accessible* child) = 0;
 
   /**
    * @brief Emits text-changed event on at-spi bus.
+   *
+   * @param[in] obj The accessible object
+   * @param[in] state The changed state for text, such as Inserted or Deleted
+   * @param[in] position The cursor position
+   * @param[in] length The text length
+   * @param[in] content The changed text
    **/
   virtual void EmitTextChanged(Accessible* obj, TextChangedState state, unsigned int position, unsigned int length, const std::string& content) = 0;
 
   /**
    * @brief Emits state-changed event on at-spi bus.
+   *
+   * @param[in] obj The accessible object
+   * @param[in] state The accessibility state (SHOWING, HIGHLIGHTED, etc)
+   * @param[in] newValue Whether the state value is changed to new value or not.
+   * @param[in] reserved Reserved. (Currently, this argument is not implemented in dali)
    **/
-  virtual void EmitStateChanged(Accessible* obj, State state, int val1, int val2 = 0) = 0;
+  virtual void EmitStateChanged(Accessible* obj, State state, int newValue, int reserved = 0) = 0;
 
   /**
    * @brief Emits window event on at-spi bus.
+   *
+   * @param[in] obj The accessible object
+   * @param[in] event The enumerated window event
+   * @param[in] detail The additional parameter which interpretation depends on chosen event
    **/
-  virtual void Emit(Accessible* obj, WindowEvent we, unsigned int detail1 = 0) = 0;
+  virtual void Emit(Accessible* obj, WindowEvent event, unsigned int detail = 0) = 0;
 
   /**
    * @brief Emits property-changed event on at-spi bus.
+   *
+   * @param[in] obj The accessible object
+   * @param[in] event Property changed event
    **/
   virtual void Emit(Accessible* obj, ObjectPropertyChangeEvent event) = 0;
 
   /**
    * @brief Emits bounds-changed event on at-spi bus.
+   *
+   * @param[in] obj The accessible object
+   * @param[in] rect The rectangle for changed bounds
    **/
   virtual void EmitBoundsChanged(Accessible* obj, Rect<> rect) = 0;
 
@@ -220,16 +257,23 @@ struct DALI_ADAPTOR_API Bridge
    *
    * Screen-reader might receive this event and reply, that given keycode is consumed. In that case
    * further processing of the keycode should be ignored.
+   *
+   * @param[in] type Key event type
+   * @param[in] keyCode Key code
+   * @param[in] keyName Key name
+   * @param[in] timeStamp Time stamp
+   * @param[in] isText Whether it's text or not
+   * @return Whether this event is consumed or not
    **/
   virtual Consumed Emit(KeyEventType type, unsigned int keyCode, const std::string& keyName, unsigned int timeStamp, bool isText) = 0;
 
   /**
    * @brief Reads given text by screen reader
    *
-   * @param text The text to read
-   * @param discardable If TRUE, reading can be discarded by subsequent reading requests,
+   * @param[in] text The text to read
+   * @param[in] discardable If TRUE, reading can be discarded by subsequent reading requests,
    * if FALSE the reading must finish before next reading request can be started
-   * @param callback the callback function that is called on reading signals emitted
+   * @param[in] callback the callback function that is called on reading signals emitted
    * during processing of this reading request.
    * Callback can be one of the following signals:
    * ReadingCancelled, ReadingStopped, ReadingSkipped
@@ -249,29 +293,35 @@ struct DALI_ADAPTOR_API Bridge
   /**
    * @brief Cancels anything screen-reader is reading / has queued to read
    *
-   * @param alsoNonDiscardable whether to cancel non-discardable readings as well
+   * @param[in] alsoNonDiscardable whether to cancel non-discardable readings as well
    */
   virtual void StopReading(bool alsoNonDiscardable) = 0;
 
   /**
    * @brief Suppresses reading of screen-reader
    *
-   * @param suppress whether to suppress reading of screen-reader
+   * @param[in] suppress whether to suppress reading of screen-reader
    */
   virtual void SuppressScreenReader(bool suppress) = 0;
 
   /**
-   * @brief Get screen reader status.
+   * @brief Gets screen reader status.
+   *
+   * @return True if screen reader is enabled
    */
   virtual bool GetScreenReaderEnabled() = 0;
 
   /**
-   * @brief Get ATSPI status.
+   * @brief Gets ATSPI status.
+   *
+   * @return True if ATSPI is enabled
    */
-  virtual bool GetIsEnabled() = 0;
+  virtual bool IsEnabled() = 0;
 
   /**
    * @brief Returns instance of bridge singleton object.
+   *
+   * @return The current bridge object
    **/
   static Bridge* GetCurrentBridge();
 
@@ -306,12 +356,13 @@ struct DALI_ADAPTOR_API Bridge
 protected:
   struct Data
   {
-    std::unordered_set<Accessible*> knownObjects;
-    std::string                     busName;
-    Bridge*                         bridge = nullptr;
-    Actor                           highlightActor, currentlyHighlightedActor;
+    std::unordered_set<Accessible*> mKnownObjects;
+    std::string                     mBusName;
+    Bridge*                         mBridge = nullptr;
+    Actor                           mHighlightActor;
+    Actor                           mCurrentlyHighlightedActor;
   };
-  std::shared_ptr<Data> data;
+  std::shared_ptr<Data> mData;
   friend class Accessible;
 
   enum class AutoInitState
@@ -319,28 +370,33 @@ protected:
     DISABLED,
     ENABLED
   };
+
   inline static AutoInitState autoInitState = AutoInitState::ENABLED;
 
   /**
-   * @brief Registers accessible object to be known in bridge object
+   * @brief Registers accessible object to be known in bridge object.
    *
    * Bridge must known about all currently alive accessible objects, as some requst
    * might come and object will be identified by number id (it's memory address).
    * To avoid memory corruption number id is checked against set of known objects.
+   *
+   * @param[in] object The accessible object
    **/
-  void RegisterOnBridge(Accessible*);
+  void RegisterOnBridge(Accessible* object);
 
   /**
    * @brief Tells bridge, that given object is considered root (doesn't have any parents).
    *
    * All root objects will have the same parent - application object. Application object
    * is controlled by bridge and private.
+   *
+   * @param[in] owner The accessible object
    **/
-  void SetIsOnRootLevel(Accessible*);
+  void SetIsOnRootLevel(Accessible* owner);
 };
 
 /**
- * @brief Check if ATSPI is activated or not.
+ * @brief Checks if ATSPI is activated or not.
  * @return True if ATSPI is activated.
  */
 inline bool IsUp()
@@ -349,15 +405,17 @@ inline bool IsUp()
   {
     return false;
   }
-  if(Bridge::GetCurrentBridge()->GetIsEnabled() == false)
+
+  if(Bridge::GetCurrentBridge()->IsEnabled() == false)
   {
     return false;
   }
+
   return Bridge::GetCurrentBridge()->IsUp();
 }
 
 /**
- * @brief Basic interface implemented by all accessibility objects
+ * @brief Basic interface implemented by all accessibility objects.
  */
 class Accessible
 {
@@ -367,160 +425,180 @@ public:
   using utf8_t = unsigned char;
 
   /**
-   * @brief Calculaties word boundaries in given utf8 text.
+   * @brief Calculates and finds word boundaries in given utf8 text.
    *
-   * s and length represents source text pointer and it's length respectively. langauge represents
-   * language to use. Word boundaries are returned as non-zero values in table breaks, which
-   * must be of size at least length.
-   **/
-  void FindWordSeparationsUtf8(const utf8_t* s, size_t length, const char* language, char* breaks);
+   * @param[in] string The source text to find
+   * @param[in] length The length of text to find
+   * @param[in] language The language to use
+   * @param[out] breaks The word boundaries in given text
+   *
+   * @note Word boundaries are returned as non-zero values in table breaks, which must be of size at least length.
+   */
+  void FindWordSeparationsUtf8(const utf8_t* string, size_t length, const char* language, char* breaks);
 
   /**
-   * @brief Calculaties line boundaries in given utf8 text.
+   * @brief Calculates and finds line boundaries in given utf8 text.
    *
-   * s and length represents source text pointer and it's length respectively. langauge represents
-   * language to use. Line boundaries are returned as non-zero values in table breaks, which
-   * must be of size at least length.
-   **/
-  void FindLineSeparationsUtf8(const utf8_t* s, size_t length, const char* language, char* breaks);
+   * @param[in] string The source text to find
+   * @param[in] length The length of text to find
+   * @param[in] language The language to use
+   * @param[out] breaks The line boundaries in given text
+   *
+   * @note Line boundaries are returned as non-zero values in table breaks, which must be of size at least length.
+   */
+  void FindLineSeparationsUtf8(const utf8_t* string, size_t length, const char* language, char* breaks);
 
   /**
-   * @brief Helper function for emiting active-descendant-changed event
-   **/
+   * @brief Helper function for emiting active-descendant-changed event.
+   *
+   * @param[in] obj The accessible object
+   * @param[in] child The child of the object
+   */
   void EmitActiveDescendantChanged(Accessible* obj, Accessible* child);
 
   /**
-   * @brief Helper function for emiting state-changed event
-   **/
-  void EmitStateChanged(State state, int newValue1, int newValue2 = 0);
+   * @brief Helper function for emiting state-changed event.
+   *
+   * @param[in] state The accessibility state (SHOWING, HIGHLIGHTED, etc)
+   * @param[in] newValue Whether the state value is changed to new value or not.
+   * @param[in] reserved Reserved. (TODO : Currently, this argument is not implemented in dali)
+   *
+   * @note The second argument determines which value is depending on State.
+   * For instance, if the state is PRESSED, newValue means isPressed or isSelected.
+   * If the state is SHOWING, newValue means isShowing.
+   */
+  void EmitStateChanged(State state, int newValue, int reserved = 0);
 
   /**
-   * @brief Helper function for emiting bounds-changed event
-   **/
+   * @brief Helper function for emiting bounds-changed event.
+   *
+   * @param rect The rectangle for changed bounds
+   */
   void EmitBoundsChanged(Rect<> rect);
 
   /**
-   * @brief Emit "showing" event.
-   * The method inform accessibility clients about "showing" state
+   * @brief Emits "showing" event.
+   * The method informs accessibility clients about "showing" state.
    *
-   * @param[in] showing flag pointing if object is showing
+   * @param[in] isShowing The flag pointing if object is showing
    */
-  void EmitShowing(bool showing);
+  void EmitShowing(bool isShowing);
 
   /**
-   * @brief Emit "visible" event.
-   * The method inform accessibility clients about "visible" state
+   * @brief Emits "visible" event.
+   * The method informs accessibility clients about "visible" state.
    *
-   * @param[in] visible flag pointing if object is visible
+   * @param[in] isVisible The flag pointing if object is visible
    */
-  void EmitVisible(bool visible);
+  void EmitVisible(bool isVisible);
 
   /**
-   * @brief Emit "highlighted" event.
-   * The method inform accessibility clients about "highlighted" state
+   * @brief Emits "highlighted" event.
+   * The method informs accessibility clients about "highlighted" state.
    *
-   * @param[in] set flag pointing if object is highlighted
+   * @param[in] isHighlighted The flag pointing if object is highlighted
    */
-  void EmitHighlighted(bool set);
+  void EmitHighlighted(bool isHighlighted);
 
   /**
-   * @brief Emit "focused" event.
-   * The method inform accessibility clients about "focused" state
+   * @brief Emits "focused" event.
+   * The method informs accessibility clients about "focused" state.
    *
-   * @param[in] set flag pointing if object is focused
+   * @param[in] isFocused The flag pointing if object is focused
    */
-  void EmitFocused(bool set);
+  void EmitFocused(bool isFocused);
 
   /**
-   * @brief Emit "text inserted" event
+   * @brief Emits "text inserted" event.
    *
-   * @param[in] position caret position
-   * @param[in] length text length
-   * @param[in] content inserted text
+   * @param[in] position The cursor position
+   * @param[in] length The text length
+   * @param[in] content The inserted text
    */
   void EmitTextInserted(unsigned int position, unsigned int length, const std::string& content);
 
   /**
-   * @brief Emit "text deleted" event
+   * @brief Emits "text deleted" event.
    *
-   * @param[in] position caret position
-   * @param[in] length text length
-   * @param[in] content deleted text
+   * @param[in] position The cursor position
+   * @param[in] length The text length
+   * @param[in] content The deleted text
    */
   void EmitTextDeleted(unsigned int position, unsigned int length, const std::string& content);
 
   /**
-   * @brief Emit "caret moved" event
+   * @brief Emits "cursor moved" event.
    *
-   * @param[in] cursorPosition new caret position
+   * @param[in] cursorPosition The new cursor position
    */
-  void EmitTextCaretMoved(unsigned int cursorPosition);
+  void EmitTextCursorMoved(unsigned int cursorPosition);
 
   /**
-   * @brief Emit "highlighted" event
+   * @brief Emits "highlighted" event.
    *
-   * @param[in] we enumerated window event
-   * @param[in] detail1 additional parameter which interpretation depends on chosen event
+   * @param[in] event The enumerated window event
+   * @param[in] detail The additional parameter which interpretation depends on chosen event
    */
-  void Emit(WindowEvent we, unsigned int detail1 = 0);
+  void Emit(WindowEvent event, unsigned int detail = 0);
 
   /**
-   * @brief Emits property-changed event
+   * @brief Emits property-changed event.
+   *
    * @param[in] event Property changed event
    **/
   void Emit(ObjectPropertyChangeEvent event);
 
   /**
-   * @brief Get accessibility name
+   * @brief Gets accessibility name.
    *
-   * @return string with name
+   * @return The string with name
    */
   virtual std::string GetName() = 0;
 
   /**
-   * @brief Get accessibility description
+   * @brief Gets accessibility description.
    *
-   * @return string with description
+   * @return The string with description
    */
   virtual std::string GetDescription() = 0;
 
   /**
-   * @brief Get parent
+   * @brief Gets parent.
    *
-   * @return handler to accessibility object
+   * @return The handler to accessibility object
    */
   virtual Accessible* GetParent() = 0;
 
   /**
-   * @brief Get count of children
+   * @brief Gets the number of children.
    *
-   * @return unsigned integer value
+   * @return The number of children
    */
   virtual size_t GetChildCount() = 0;
 
   /**
-   * @brief Get collection with all children
+   * @brief Gets collection with all children.
    *
-   * @return collection of accessibility objects
+   * @return The collection of accessibility objects
    */
   virtual std::vector<Accessible*> GetChildren();
 
   /**
-   * @brief Get nth child
+   * @brief Gets child of the index.
    *
-   * @return accessibility object
+   * @return The child object
    */
   virtual Accessible* GetChildAtIndex(size_t index) = 0;
 
   /**
-   * @brief Get index that current object has in its parent's children collection
+   * @brief Gets index that current object has in its parent's children collection.
    *
-   * @return unsigned integer index
+   * @return The index of the current object
    */
   virtual size_t GetIndexInParent() = 0;
 
   /**
-   * @brief Get accessibility role
+   * @brief Gets accessibility role.
    *
    * @return Role enumeration
    *
@@ -529,9 +607,9 @@ public:
   virtual Role GetRole() = 0;
 
   /**
-   * @brief Get name of accessibility role
+   * @brief Gets name of accessibility role.
    *
-   * @return string with human readable role converted from enumeration
+   * @return The string with human readable role converted from enumeration
    *
    * @see Dali::Accessibility::Role
    * @see Accessibility::Accessible::GetRole
@@ -539,9 +617,9 @@ public:
   virtual std::string GetRoleName();
 
   /**
-   * @brief Get localized name of accessibility role
+   * @brief Gets localized name of accessibility role.
    *
-   * @return string with human readable role translated according to current
+   * @return The string with human readable role translated according to current
    * translation domain
    *
    * @see Dali::Accessibility::Role
@@ -553,9 +631,9 @@ public:
   virtual std::string GetLocalizedRoleName();
 
   /**
-   * @brief Get accessibility states
+   * @brief Gets accessibility states.
    *
-   * @return collection of states
+   * @return The collection of states
    *
    * @note States class is instatation of ArrayBitset template class
    *
@@ -565,37 +643,39 @@ public:
   virtual States GetStates() = 0;
 
   /**
-   * @brief Get accessibility attributes
+   * @brief Gets accessibility attributes.
    *
-   * @return map of attributes and their values
+   * @return The map of attributes and their values
    */
   virtual Attributes GetAttributes() = 0;
 
   /**
-   * @brief Check if this is proxy
+   * @brief Checks if this is proxy.
    *
    * @return True if this is proxy
    */
   virtual bool IsProxy();
 
   /**
-   * @brief Get unique address on accessibility bus
+   * @brief Gets unique address on accessibility bus.
    *
-   * @return class containing address
+   * @return The Address class containing address
    *
    * @see Dali::Accessibility::Address
    */
   virtual Address GetAddress();
 
   /**
-   * @brief Get accessibility object, which is "default label" for this object
+   * @brief Gets accessibility object, which is "default label" for this object.
+   *
+   * @return The Accessible object
    */
   virtual Accessible* GetDefaultLabel();
 
   /**
-   * @brief Depute an object to perform provided gesture
+   * @brief Deputes an object to perform provided gesture.
    *
-   * @param[in] gestureInfo structure describing the gesture
+   * @param[in] gestureInfo The structure describing the gesture
    *
    * @return true on success, false otherwise
    *
@@ -604,53 +684,55 @@ public:
   virtual bool DoGesture(const GestureInfo& gestureInfo) = 0;
 
   /**
-   * @brief Re-emits selected states of an Accessibility Object
+   * @brief Re-emits selected states of an Accessibility Object.
    *
-   * @param[in] states chosen states to re-emit
-   * @param[in] doRecursive if true all children of the Accessibility Object will also re-emit the states
+   * @param[in] states The chosen states to re-emit
+   * @param[in] isRecursive If true, all children of the Accessibility object will also re-emit the states
    */
-  void NotifyAccessibilityStateChange(Dali::Accessibility::States states, bool doRecursive);
+  void NotifyAccessibilityStateChange(Dali::Accessibility::States states, bool isRecursive);
 
   /**
-   * @brief Get information about current object and all relations that connects
-   * it with other accessibility objects
+   * @brief Gets information about current object and all relations that connects
+   * it with other accessibility objects.
    *
-   * @return iterable collection of Relation objects
+   * @return The iterable collection of Relation objects
    *
    * @see Dali::Accessibility::Relation
    */
   virtual std::vector<Relation> GetRelationSet() = 0;
 
   /**
-   * @brief Get all implemented interfaces
+   * @brief Gets all implemented interfaces.
    *
-   * @return collection of strings with implemented interfaces
+   * @return The collection of strings with implemented interfaces
    */
   std::vector<std::string> GetInterfaces();
 
   /**
-   * @brief Check if object is on root level
+   * @brief Checks if object is on root level.
+   *
+   * @return Whether object is on root level or not
    */
-  bool GetIsOnRootLevel() const
+  bool IsOnRootLevel() const
   {
-    return isOnRootLevel;
+    return mIsOnRootLevel;
   }
 
   /**
-   * @brief The method registers functor resposible for converting Actor into Accessible
-   * @param functor returning Accessible handle from Actor object
+   * @brief The method registers functor resposible for converting Actor into Accessible.
+   * @param functor The returning Accessible handle from Actor object
    */
   static void RegisterControlAccessibilityGetter(std::function<Accessible*(Dali::Actor)> functor);
 
   /**
-   * @brief Acquire Accessible object from Actor object
+   * @brief Acquires Accessible object from Actor object.
    *
    * @param[in] actor Actor object
-   * @param[in] root true, if it's top level object (window)
+   * @param[in] isRoot True, if it's top level object (window)
    *
-   * @return handle to Accessible object
+   * @return The handle to Accessible object
    */
-  static Accessible* Get(Dali::Actor actor, bool root = false);
+  static Accessible* Get(Dali::Actor actor, bool isRoot = false);
 
 protected:
   Accessible();
@@ -661,83 +743,114 @@ protected:
   std::shared_ptr<Bridge::Data> GetBridgeData();
 
 public:
+  /**
+   * @brief Gets the highlight actor.
+   *
+   * This method is to get the highlight itself.
+   * @return The highlight actor
+   */
   static Dali::Actor GetHighlightActor();
-  static void        SetHighlightActor(Dali::Actor actor);
+
+  /**
+   * @brief Sets the highlight actor.
+   *
+   * This method is to set the highlight itself.
+   * @param[in] actor The highlight actor
+   */
+  static void SetHighlightActor(Dali::Actor actor);
+
+  /**
+   * @brief Gets the currently highlighted actor.
+   *
+   * @return The current highlighted actor
+   */
   static Dali::Actor GetCurrentlyHighlightedActor();
-  static void        SetCurrentlyHighlightedActor(Dali::Actor);
-  static void        SetObjectRegistry(ObjectRegistry registry);
+
+  /**
+   * @brief Sets currently highlighted actor.
+   *
+   * @param[in] actor The highlight actor
+   */
+  static void SetCurrentlyHighlightedActor(Dali::Actor actor);
+
+  /**
+   * @brief Sets ObjectRegistry.
+   *
+   * @param[in] registry ObjectRegistry instance
+   */
+  static void SetObjectRegistry(ObjectRegistry registry);
 
 private:
   friend class Bridge;
 
-  std::weak_ptr<Bridge::Data> bridgeData;
-  bool                        isOnRootLevel = false;
+  std::weak_ptr<Bridge::Data> mBridgeData;
+  bool                        mIsOnRootLevel = false;
 };
 
 /**
- * @brief Interface enabling to perform provided actions
+ * @brief Interface enabling to perform provided actions.
  */
 class Action : public virtual Accessible
 {
 public:
   /**
-   * @brief Get name of action with given index
+   * @brief Gets name of action with given index.
    *
-   * @param[in] index index of action
+   * @param[in] index The index of action
    *
-   * @return string with name of action
+   * @return The string with name of action
    */
   virtual std::string GetActionName(size_t index) = 0;
 
   /**
-   * @brief Get translated name of action with given index
+   * @brief Gets translated name of action with given index.
    *
-   * @param[in] index index of action
+   * @param[in] index The index of action
    *
-   * @return string with name of action translated according to current translation domain
+   * @return The string with name of action translated according to current translation domain
    *
-   * @note translation is not supported in this version
+   * @note The translation is not supported in this version
    */
   virtual std::string GetLocalizedActionName(size_t index) = 0;
 
   /**
-   * @brief Get description of action with given index
+   * @brief Gets description of action with given index.
    *
-   * @param[in] index index of action
+   * @param[in] index The index of action
    *
-   * @return string with description of action
+   * @return The string with description of action
    */
   virtual std::string GetActionDescription(size_t index) = 0;
 
   /**
-   * @brief Get key code binded to action with given index
+   * @brief Gets key code binded to action with given index.
    *
-   * @param[in] index index of action
+   * @param[in] index The index of action
    *
-   * @return string with key name
+   * @return The string with key name
    */
   virtual std::string GetActionKeyBinding(size_t index) = 0;
 
   /**
-   * @brief Get number of provided actions
+   * @brief Gets number of provided actions.
    *
-   * @return unsigned integer with number of actions
+   * @return The number of actions
    */
   virtual size_t GetActionCount() = 0;
 
   /**
-   * @brief Perform an action with given index
+   * @brief Performs an action with given index.
    *
-   * @param index index of action
+   * @param index The index of action
    *
    * @return true on success, false otherwise
    */
   virtual bool DoAction(size_t index) = 0;
 
   /**
-   * @brief Perform an action with given name
+   * @brief Performs an action with given name.
    *
-   * @param name name of action
+   * @param name The name of action
    *
    * @return true on success, false otherwise
    */
@@ -745,7 +858,7 @@ public:
 };
 
 /**
- * @brief Interface enabling advanced quering of accessibility objects
+ * @brief Interface enabling advanced quering of accessibility objects.
  *
  * @note since all mathods can be implemented inside bridge,
  * none methods have to be overrided
@@ -756,54 +869,57 @@ public:
 };
 
 /**
- * @brief Interface representing objects having screen coordinates
+ * @brief Interface representing objects having screen coordinates.
  */
 class Component : public virtual Accessible
 {
 public:
   /**
-   * @brief Get rectangle describing size
+   * @brief Gets rectangle describing size.
    *
-   * @param[in] ctype enumeration with type of coordinate systems
+   * @param[in] type The enumeration with type of coordinate systems
    *
    * @return Rect<> object
    *
    * @see Dali::Rect
    */
-  virtual Rect<> GetExtents(CoordType ctype) = 0;
+  virtual Rect<> GetExtents(CoordinateType type) = 0;
 
   /**
-   * @brief Get layer current object is localized on
+   * @brief Gets layer current object is localized on.
    *
-   * @return enumeration pointing layer
+   * @return The enumeration pointing layer
    *
    * @see Dali::Accessibility::ComponentLayer
    */
   virtual ComponentLayer GetLayer() = 0;
 
   /**
-   * @brief Get value of z-order
+   * @brief Gets value of z-order.
    *
-   * @return value of z-order
+   * @return The value of z-order
+   * @remarks MDI means "Multi Document Interface" (https://en.wikipedia.org/wiki/Multiple-document_interface)
+   * which in short means that many stacked windows can be displayed within a single application.
+   * In such model, the concept of z-order of UI element became important to deal with element overlapping.
    */
   virtual int16_t GetMdiZOrder() = 0;
 
   /**
-   * @brief Set current object as "focused"
+   * @brief Sets current object as "focused".
    *
    * @return true on success, false otherwise
    */
   virtual bool GrabFocus() = 0;
 
   /**
-   * @brief Get value of alpha channel
+   * @brief Gets value of alpha channel.
    *
-   * @return alpha channel value in range [0.0, 1.0]
+   * @return The alpha channel value in range [0.0, 1.0]
    */
   virtual double GetAlpha() = 0;
 
   /**
-   * @brief Set current object as "highlighted"
+   * @brief Sets current object as "highlighted".
    *
    * The method assings "highlighted" state, simultaneously removing it
    * from currently highlighted object.
@@ -813,7 +929,7 @@ public:
   virtual bool GrabHighlight() = 0;
 
   /**
-   * @brief Set current object as "unhighlighted"
+   * @brief Sets current object as "unhighlighted".
    *
    * The method removes "highlighted" state from object.
    *
@@ -824,7 +940,7 @@ public:
   virtual bool ClearHighlight() = 0;
 
   /**
-   * @brief Check whether object can be scrolled
+   * @brief Checks whether object can be scrolled.
    *
    * @return true if object is scrollable, false otherwise
    *
@@ -833,76 +949,77 @@ public:
   virtual bool IsScrollable();
 
   /**
-   * @brief Get Accessible object containing given point
+   * @brief Gets Accessible object containing given point.
    *
-   * @param[in] p two-dimensional point
-   * @param[in] ctype enumeration with type of coordinate system
+   * @param[in] point The two-dimensional point
+   * @param[in] type The enumeration with type of coordinate system
    *
-   * @return handle to last child of current object which contains given point
+   * @return The handle to last child of current object which contains given point
    *
    * @see Dali::Accessibility::Point
    */
-  virtual Accessible* GetAccessibleAtPoint(Point p, CoordType ctype);
+  virtual Accessible* GetAccessibleAtPoint(Point point, CoordinateType type);
 
   /**
-   * @brief Check if current object contains given point
+   * @brief Checks if current object contains given point.
    *
-   * @param[in] p two-dimensional point
-   * @param[in] ctype enumeration with type of coordinate system
+   * @param[in] point The two-dimensional point
+   * @param[in] type The enumeration with type of coordinate system
    *
-   * @return handle to Accessible object
+   * @return True if accessible contains in point, otherwise false.
    *
+   * @remarks This method is `Contains` in DBus method.
    * @see Dali::Accessibility::Point
    */
-  virtual bool Contains(Point p, CoordType ctype);
+  virtual bool IsAccessibleContainedAtPoint(Point point, CoordinateType type);
 };
 
 /**
- * @brief Interface representing objects which can store numeric value
+ * @brief Interface representing objects which can store numeric value.
  */
 class Value : public virtual Accessible
 {
 public:
   /**
-   * @brief Get the lowest possible value
+   * @brief Gets the lowest possible value.
    *
-   * @return double value
+   * @return The minimum value
   */
   virtual double GetMinimum() = 0;
 
   /**
-   * @brief Get current value
+   * @brief Gets the current value.
    *
-   * @return double value
+   * @return The current value
   */
   virtual double GetCurrent() = 0;
 
   /**
-   * @brief Get the highest possible value
+   * @brief Gets the highest possible value.
    *
-   * @return double value
+   * @return The highest value.
   */
   virtual double GetMaximum() = 0;
 
   /**
-   * @brief Set value
+   * @brief Sets the current value.
    *
-   * @param[in] val double value
+   * @param[in] value The current value to set
    *
    * @return true if value could have been assigned, false otherwise
   */
-  virtual bool SetCurrent(double val) = 0;
+  virtual bool SetCurrent(double value) = 0;
 
   /**
-   * @brief Get the lowest increment that can be distinguished
+   * @brief Gets the lowest increment that can be distinguished.
    *
-   * @return double value
+   * @return The lowest increment
   */
   virtual double GetMinimumIncrement() = 0;
 };
 
 /**
- * @brief Interface representing objects which can store immutable texts
+ * @brief Interface representing objects which can store immutable texts.
  *
  * @see Dali::Accessibility::EditableText
  */
@@ -910,43 +1027,46 @@ class DALI_ADAPTOR_API Text : public virtual Accessible
 {
 public:
   /**
-   * @brief Get stored text in given range
+   * @brief Gets stored text in given range.
    *
-   * @param[in] startOffset index of first character
-   * @param[in] endOffset index of first character after the last one expected
+   * @param[in] startOffset The index of first character
+   * @param[in] endOffset The index of first character after the last one expected
    *
-   * @return substring of stored text
+   * @return The substring of stored text
    */
   virtual std::string GetText(size_t startOffset, size_t endOffset) = 0;
 
   /**
-   * @brief Get number of all stored characters
+   * @brief Gets number of all stored characters.
    *
-   * @return number of characters
+   * @return The number of characters
+   * @remarks This method is `CharacterCount` in DBus method.
    */
   virtual size_t GetCharacterCount() = 0;
 
   /**
-   * @brief Get caret offset
+   * @brief Gets the cursor offset.
    *
-   * @return Value of caret offset
+   * @return Value of cursor offset
+   * @remarks This method is `CaretOffset` in DBus method.
    */
-  virtual size_t GetCaretOffset() = 0;
+  virtual size_t GetCursorOffset() = 0;
 
   /**
-   * @brief Set caret offset
+   * @brief Sets the cursor offset.
    *
-   * @param[in] offset Caret offset
+   * @param[in] offset Cursor offset
    *
    * @return True if successful
+   * @remarks This method is `SetCaretOffset` in DBus method.
    */
-  virtual bool SetCaretOffset(size_t offset) = 0;
+  virtual bool SetCursorOffset(size_t offset) = 0;
 
   /**
-   * @brief Get substring of stored text truncated in concrete gradation
+   * @brief Gets substring of stored text truncated in concrete gradation.
    *
-   * @param[in] offset position in stored text
-   * @param[in] boundary enumeration describing text gradation
+   * @param[in] offset The position in stored text
+   * @param[in] boundary The enumeration describing text gradation
    *
    * @return Range structure containing acquired text and offsets in original string
    *
@@ -955,43 +1075,45 @@ public:
   virtual Range GetTextAtOffset(size_t offset, TextBoundary boundary) = 0;
 
   /**
-   * @brief Get selected text
+   * @brief Gets selected text.
    *
-   * @param[in] selectionNum selection index
+   * @param[in] selectionIndex The selection index
    * @note Currently only one selection (i.e. with index = 0) is supported
    *
    * @return Range structure containing acquired text and offsets in original string
    *
+   * @remarks This method is `GetSelection` in DBus method.
    * @see Dali::Accessibility::Range
    */
-  virtual Range GetSelection(size_t selectionNum) = 0;
+  virtual Range GetRangeOfSelection(size_t selectionIndex) = 0;
 
   /**
-   * @brief Remove selection
+   * @brief Removes the whole selection.
    *
-   * @param[in] selectionNum selection index
+   * @param[in] selectionIndex The selection index
    * @note Currently only one selection (i.e. with index = 0) is supported
    *
    * @return bool on success, false otherwise
    */
-  virtual bool RemoveSelection(size_t selectionNum) = 0;
+  virtual bool RemoveSelection(size_t selectionIndex) = 0;
 
   /**
-   * @brief Get selected text
+   * @brief Sets selected text.
    *
-   * @param[in] selectionNum selection index
-   * @param[in] startOffset index of first character
-   * @param[in] endOffset index of first character after the last one expected
+   * @param[in] selectionIndex The selection index
+   * @param[in] startOffset The index of first character
+   * @param[in] endOffset The index of first character after the last one expected
    *
    * @note Currently only one selection (i.e. with index = 0) is supported
    *
    * @return true on success, false otherwise
+   * @remarks This method is `SetSelection` in DBus method.
    */
-  virtual bool SetSelection(size_t selectionNum, size_t startOffset, size_t endOffset) = 0;
+  virtual bool SetRangeOfSelection(size_t selectionIndex, size_t startOffset, size_t endOffset) = 0;
 };
 
 /**
- * @brief Interface representing objects which can store editable texts
+ * @brief Interface representing objects which can store editable texts.
  *
  * @note Paste method is entirely implemented inside bridge
  *
@@ -1001,49 +1123,49 @@ class DALI_ADAPTOR_API EditableText : public virtual Accessible
 {
 public:
   /**
-   * @brief Copy text in range to system clipboard
+   * @brief Copies text in range to system clipboard.
    *
-   * @param[in] startPosition index of first character
-   * @param[in] endPosition index of first character after the last one expected
+   * @param[in] startPosition The index of first character
+   * @param[in] endPosition The index of first character after the last one expected
    *
    * @return true on success, false otherwise
    */
   virtual bool CopyText(size_t startPosition, size_t endPosition) = 0;
 
   /**
-   * @brief Cut text in range to system clipboard
+   * @brief Cuts text in range to system clipboard.
    *
-   * @param[in] startPosition index of first character
-   * @param[in] endPosition index of first character after the last one expected
+   * @param[in] startPosition The index of first character
+   * @param[in] endPosition The index of first character after the last one expected
    *
    * @return true on success, false otherwise
    */
   virtual bool CutText(size_t startPosition, size_t endPosition) = 0;
 
   /**
-   * @brief Delete text in range
+   * @brief Deletes text in range.
    *
-   * @param[in] startPosition index of first character
-   * @param[in] endPosition index of first character after the last one expected
+   * @param[in] startPosition The index of first character
+   * @param[in] endPosition The index of first character after the last one expected
    *
    * @return true on success, false otherwise
    */
   virtual bool DeleteText(size_t startPosition, size_t endPosition) = 0;
 
   /**
-   * @brief Insert text at startPosition
+   * @brief Inserts text at startPosition.
    *
-   * @param[in] startPosition index of first character
-   * @param[in] text text content
+   * @param[in] startPosition The index of first character
+   * @param[in] text The text content
    *
    * @return true on success, false otherwise
    */
   virtual bool InsertText(size_t startPosition, std::string text) = 0;
 
   /**
-   * @brief Replace text with content
+   * @brief Replaces text with content.
    *
-   * @param[in] newContents text content
+   * @param[in] newContents The text content
    *
    * @return true on success, false otherwise
    */
@@ -1051,43 +1173,43 @@ public:
 };
 
 /**
- * @brief Interface representing objects which can store a set of selected items
+ * @brief Interface representing objects which can store a set of selected items.
  */
 class DALI_ADAPTOR_API Selection : public virtual Accessible
 {
 public:
   /**
-   * @brief Gets number of selected children
+   * @brief Gets the number of selected children.
    *
-   * @return number of selected children (zero if none)
+   * @return The number of selected children (zero if none)
    */
   virtual int GetSelectedChildrenCount() = 0;
 
   /**
-   * @brief Gets a specific selected child
+   * @brief Gets a specific selected child.
    *
-   * @param selectedChildIndex index of the selected child
+   * @param selectedChildIndex The index of the selected child
    *
    * @note @p selectedChildIndex refers to the list of selected children,
    * not the list of all children
    *
-   * @return selected child or nullptr if index is invalid
+   * @return The selected child or nullptr if index is invalid
    */
   virtual Accessible* GetSelectedChild(int selectedChildIndex) = 0;
 
   /**
-   * @brief Selects a child
+   * @brief Selects a child.
    *
-   * @param childIndex index of the child
+   * @param childIndex The index of the child
    *
    * @return true on success, false otherwise
    */
   virtual bool SelectChild(int childIndex) = 0;
 
   /**
-   * @brief Deselects a selected child
+   * @brief Deselects a selected child.
    *
-   * @param selectedChildIndex index of the selected child
+   * @param selectedChildIndex The index of the selected child
    *
    * @note @p selectedChildIndex refers to the list of selected children,
    * not the list of all children
@@ -1099,32 +1221,32 @@ public:
   virtual bool DeselectSelectedChild(int selectedChildIndex) = 0;
 
   /**
-   * @brief Checks whether a child is selected
+   * @brief Checks whether a child is selected.
    *
-   * @param childIndex index of the child
+   * @param childIndex The index of the child
    *
    * @return true if given child is selected, false otherwise
    */
   virtual bool IsChildSelected(int childIndex) = 0;
 
   /**
-   * @brief Selects all children
+   * @brief Selects all children.
    *
    * @return true on success, false otherwise
    */
   virtual bool SelectAll() = 0;
 
   /**
-   * @brief Deselects all children
+   * @brief Deselects all children.
    *
    * @return true on success, false otherwise
    */
   virtual bool ClearSelection() = 0;
 
   /**
-   * @brief Deselects a child
+   * @brief Deselects a child.
    *
-   * @param childIndex index of the child
+   * @param childIndex The index of the child.
    *
    * @return true on success, false otherwise
    *
@@ -1134,7 +1256,7 @@ public:
 };
 
 /**
- * @brief minimalistic, always empty Accessible object with settable address
+ * @brief The minimalistic, always empty Accessible object with settable address.
  *
  * For those situations, where you want to return address in different bridge
  * (embedding for example), but the object itself ain't planned to be used otherwise.
@@ -1144,72 +1266,86 @@ class DALI_ADAPTOR_API EmptyAccessibleWithAddress : public virtual Accessible
 {
 public:
   EmptyAccessibleWithAddress() = default;
+
   EmptyAccessibleWithAddress(Address address)
-  : address(std::move(address))
+  : mAddress(std::move(address))
   {
   }
 
   void SetAddress(Address address)
   {
-    this->address = std::move(address);
+    this->mAddress = std::move(address);
   }
 
   std::string GetName() override
   {
     return "";
   }
+
   std::string GetDescription() override
   {
     return "";
   }
+
   Accessible* GetParent() override
   {
     return nullptr;
   }
+
   size_t GetChildCount() override
   {
     return 0;
   }
+
   std::vector<Accessible*> GetChildren() override
   {
     return {};
   }
+
   Accessible* GetChildAtIndex(size_t index) override
   {
     throw std::domain_error{"out of bounds index (" + std::to_string(index) + ") - no children"};
   }
+
   size_t GetIndexInParent() override
   {
     return static_cast<size_t>(-1);
   }
+
   Role GetRole() override
   {
     return {};
   }
+
   std::string GetRoleName() override;
-  States      GetStates() override
+
+  States GetStates() override
   {
     return {};
   }
+
   Attributes GetAttributes() override
   {
     return {};
   }
+
   Address GetAddress() override
   {
-    return address;
+    return mAddress;
   }
+
   bool DoGesture(const GestureInfo& gestureInfo) override
   {
     return false;
   }
+
   std::vector<Relation> GetRelationSet() override
   {
     return {};
   }
 
 private:
-  Address address;
+  Address mAddress;
 };
 
 } // namespace Accessibility
index a8d0d35..33dc1e1 100644 (file)
@@ -77,9 +77,9 @@ enum class RelationType : uint32_t
 /**\r
  * @brief Enumeration describing if coordinates are relative to screen or window\r
  * @see Accessibility::Component::GetExtents\r
- * @see Accessibility::Component::Contains\r
+ * @see Accessibility::Component::IsAccessibleContainedAtPoint\r
  */\r
-enum class CoordType\r
+enum class CoordinateType\r
 {\r
   SCREEN, ///< Screen.\r
   WINDOW  ///< Window.\r
@@ -438,32 +438,32 @@ class BitSets
 {\r
   std::array<uint32_t, I> data;\r
 \r
-  void _set()\r
+  void Set()\r
   {\r
   }\r
 \r
-  static constexpr bool _accepts()\r
+  static constexpr bool Accepts()\r
   {\r
     return true;\r
   }\r
 \r
   template<typename T>\r
-  static constexpr bool _accepts()\r
+  static constexpr bool Accepts()\r
   {\r
     return std::is_enum<T>::value;\r
   }\r
 \r
   template<typename T, typename T2, typename... ARGS>\r
-  static constexpr bool _accepts()\r
+  static constexpr bool Accepts()\r
   {\r
-    return std::is_enum<T>::value && _accepts<T2, ARGS...>();\r
+    return std::is_enum<T>::value && Accepts<T2, ARGS...>();\r
   }\r
 \r
   template<typename T, typename... ARGS>\r
-  void _set(T t, ARGS... args)\r
+  void Set(T t, ARGS... args)\r
   {\r
     (*this)[t] = true;\r
-    _set(args...);\r
+    Set(args...);\r
   }\r
 \r
 public:\r
@@ -477,12 +477,12 @@ public:
   BitSets(const BitSets&) = default;\r
   BitSets(BitSets&&)      = default;\r
 \r
-  template<typename T, typename... ARGS, typename std::enable_if<_accepts<T, ARGS...>()>::type* = nullptr>\r
+  template<typename T, typename... ARGS, typename std::enable_if<Accepts<T, ARGS...>()>::type* = nullptr>\r
   BitSets(T t, ARGS... args)\r
   {\r
     for(auto& u : data)\r
       u = 0;\r
-    _set(t, args...);\r
+    Set(t, args...);\r
   }\r
 \r
   explicit BitSets(std::array<uint32_t, I> d)\r
@@ -742,7 +742,7 @@ struct DALI_ADAPTOR_API Size
 /**\r
  * @brief Helper class used to store data related with Accessibility::Text interface\r
  * @see Dali::Accessibility::Text::GetTextAtOffset\r
- * @see Dali::Accessibility::Text::GetSelection\r
+ * @see Dali::Accessibility::Text::GetRangeOfSelection\r
  */\r
 struct DALI_ADAPTOR_API Range\r
 {\r
index 563fe90..64ee565 100644 (file)
@@ -90,7 +90,7 @@ int Dali::AtspiAccessibility::GetStatus()
   {
     if(bridge->GetScreenReaderEnabled())
     {
-      if(bridge->GetIsEnabled())
+      if(bridge->IsEnabled())
       {
         return 3;
       }
@@ -101,7 +101,7 @@ int Dali::AtspiAccessibility::GetStatus()
     }
     else
     {
-      if(bridge->GetIsEnabled())
+      if(bridge->IsEnabled())
       {
         return 1;
       }
index b1bb36e..fb75de8 100644 (file)
@@ -48,9 +48,9 @@ std::vector<std::string> Accessible::GetInterfaces()
   {
     tmp.push_back(AtspiDbusInterfaceComponent);
   }
-  if(auto d = dynamic_cast<Action*>(this))
+  if(auto action = dynamic_cast<Action*>(this))
   {
-    if(d->GetActionCount() > 0)
+    if(action->GetActionCount() > 0)
     {
       tmp.push_back(AtspiDbusInterfaceAction);
     }
@@ -68,99 +68,101 @@ Accessible::Accessible()
 
 Accessible::~Accessible()
 {
-  auto b = bridgeData.lock();
-  if(b)
-    b->knownObjects.erase(this);
+  auto handle = mBridgeData.lock();
+  if(handle)
+  {
+    handle->mKnownObjects.erase(this);
+  }
 }
 
 void Accessible::EmitActiveDescendantChanged(Accessible* obj, Accessible* child)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitActiveDescendantChanged(obj, child);
+    bridgeData->mBridge->EmitActiveDescendantChanged(obj, child);
   }
 }
 
-void Accessible::EmitStateChanged(State state, int newValue1, int newValue2)
+void Accessible::EmitStateChanged(State state, int newValue, int reserved)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitStateChanged(this, state, newValue1, newValue2);
+    bridgeData->mBridge->EmitStateChanged(this, state, newValue, reserved);
   }
 }
 
-void Accessible::EmitShowing(bool showing)
+void Accessible::EmitShowing(bool isShowing)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitStateChanged(this, State::SHOWING, showing ? 1 : 0, 0);
+    bridgeData->mBridge->EmitStateChanged(this, State::SHOWING, isShowing ? 1 : 0, 0);
   }
 }
 
-void Accessible::EmitVisible(bool visible)
+void Accessible::EmitVisible(bool isVisible)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitStateChanged(this, State::VISIBLE, visible ? 1 : 0, 0);
+    bridgeData->mBridge->EmitStateChanged(this, State::VISIBLE, isVisible ? 1 : 0, 0);
   }
 }
 
-void Accessible::EmitHighlighted(bool set)
+void Accessible::EmitHighlighted(bool isHighlighted)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitStateChanged(this, State::HIGHLIGHTED, set ? 1 : 0, 0);
+    bridgeData->mBridge->EmitStateChanged(this, State::HIGHLIGHTED, isHighlighted ? 1 : 0, 0);
   }
 }
 
-void Accessible::EmitFocused(bool set)
+void Accessible::EmitFocused(bool isFocused)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitStateChanged(this, State::FOCUSED, set ? 1 : 0, 0);
+    bridgeData->mBridge->EmitStateChanged(this, State::FOCUSED, isFocused ? 1 : 0, 0);
   }
 }
 void Accessible::EmitTextInserted(unsigned int position, unsigned int length, const std::string& content)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitTextChanged(this, TextChangedState::INSERTED, position, length, content);
+    bridgeData->mBridge->EmitTextChanged(this, TextChangedState::INSERTED, position, length, content);
   }
 }
 void Accessible::EmitTextDeleted(unsigned int position, unsigned int length, const std::string& content)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitTextChanged(this, TextChangedState::DELETED, position, length, content);
+    bridgeData->mBridge->EmitTextChanged(this, TextChangedState::DELETED, position, length, content);
   }
 }
-void Accessible::EmitTextCaretMoved(unsigned int cursorPosition)
+void Accessible::EmitTextCursorMoved(unsigned int cursorPosition)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitCaretMoved(this, cursorPosition);
+    bridgeData->mBridge->EmitCursorMoved(this, cursorPosition);
   }
 }
-void Accessible::Emit(WindowEvent we, unsigned int detail1)
+void Accessible::Emit(WindowEvent event, unsigned int detail)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->Emit(this, we, detail1);
+    bridgeData->mBridge->Emit(this, event, detail);
   }
 }
-void Accessible::Emit(ObjectPropertyChangeEvent ev)
+void Accessible::Emit(ObjectPropertyChangeEvent event)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->Emit(this, ev);
+    bridgeData->mBridge->Emit(this, event);
   }
 }
 
 void Accessible::EmitBoundsChanged(Rect<> rect)
 {
-  if(auto b = GetBridgeData())
+  if(auto bridgeData = GetBridgeData())
   {
-    b->bridge->EmitBoundsChanged(this, rect);
+    bridgeData->mBridge->EmitBoundsChanged(this, rect);
   }
 }
 
@@ -176,37 +178,39 @@ std::vector<Accessible*> Accessible::GetChildren()
 
 std::shared_ptr<Bridge::Data> Accessible::GetBridgeData()
 {
-  auto b = bridgeData.lock();
-  if(!b)
+  auto handle = mBridgeData.lock();
+  if(!handle)
   {
-    auto p = Bridge::GetCurrentBridge();
-    b      = p->data;
+    auto bridge = Bridge::GetCurrentBridge();
+    handle = bridge->mData;
   }
-  return b;
+  return handle;
 }
 
 Address Accessible::GetAddress()
 {
-  auto b = bridgeData.lock();
-  if(!b)
+  auto handle = mBridgeData.lock();
+  if(!handle)
   {
-    b = GetBridgeData();
-    if(b)
-      b->bridge->RegisterOnBridge(this);
+    handle = GetBridgeData();
+    if(handle)
+    {
+      handle->mBridge->RegisterOnBridge(this);
+    }
   }
   std::ostringstream tmp;
   tmp << this;
-  return {b ? b->busName : "", tmp.str()};
+  return {handle ? handle->mBusName : "", tmp.str()};
 }
 
-void Bridge::RegisterOnBridge(Accessible* obj)
+void Bridge::RegisterOnBridge(Accessible* object)
 {
-  assert(!obj->bridgeData.lock() || obj->bridgeData.lock() == data);
-  if(!obj->bridgeData.lock())
+  assert(!object->mBridgeData.lock() || object->mBridgeData.lock() == mData);
+  if(!object->mBridgeData.lock())
   {
-    assert(data);
-    data->knownObjects.insert(obj);
-    obj->bridgeData = data;
+    assert(mData);
+    mData->mKnownObjects.insert(object);
+    object->mBridgeData = mData;
   }
 }
 
@@ -220,32 +224,37 @@ Accessible* Accessible::GetDefaultLabel()
   return this;
 }
 
-void Accessible::NotifyAccessibilityStateChange(Dali::Accessibility::States states, bool doRecursive)
+void Accessible::NotifyAccessibilityStateChange(Dali::Accessibility::States states, bool isRecursive)
 {
-  if(auto b = GetBridgeData())
+  if(auto data = GetBridgeData())
   {
-    auto s = GetStates() & states;
-    for(auto i = 0u; i < s.size(); i++)
+    auto currentState = GetStates() & states;
+    for(auto i = 0u; i < currentState.size(); i++)
     {
       auto index = static_cast<Dali::Accessibility::State>(i);
-      if(s[index])
-        b->bridge->EmitStateChanged(this, index, 1, 0);
+      if(currentState[index])
+      {
+        data->mBridge->EmitStateChanged(this, index, 1, 0);
+      }
     }
-    if(doRecursive)
+
+    if(isRecursive)
     {
       auto children = GetChildren();
-      for(auto c : children)
-        c->NotifyAccessibilityStateChange(states, doRecursive);
+      for(auto iter : children)
+      {
+        iter->NotifyAccessibilityStateChange(states, isRecursive);
+      }
     }
   }
 }
 
-void Accessible::FindWordSeparationsUtf8(const utf8_t* s, size_t length, const char* language, char* breaks)
+void Accessible::FindWordSeparationsUtf8(const utf8_t* string, size_t length, const char* language, char* breaks)
 {
-  set_wordbreaks_utf8(s, length, language, breaks);
+  set_wordbreaks_utf8(string, length, language, breaks);
 }
 
-void Accessible::FindLineSeparationsUtf8(const utf8_t* s, size_t length, const char* language, char* breaks)
+void Accessible::FindLineSeparationsUtf8(const utf8_t* string, size_t length, const char* language, char* breaks)
 {
-  set_linebreaks_utf8(s, length, language, breaks);
+  set_linebreaks_utf8(string, length, language, breaks);
 }
index 309be51..4021e83 100644 (file)
@@ -34,16 +34,16 @@ namespace {
 
 bool SortVertically(Component* lhs, Component* rhs)
 {
-  auto leftRect  = lhs->GetExtents(CoordType::WINDOW);
-  auto rightRect = rhs->GetExtents(CoordType::WINDOW);
+  auto leftRect  = lhs->GetExtents(CoordinateType::WINDOW);
+  auto rightRect = rhs->GetExtents(CoordinateType::WINDOW);
 
   return leftRect.y < rightRect.y;
 }
 
 bool SortHorizontally(Component* lhs, Component* rhs)
 {
-  auto leftRect  = lhs->GetExtents(CoordType::WINDOW);
-  auto rightRect = rhs->GetExtents(CoordType::WINDOW);
+  auto leftRect  = lhs->GetExtents(CoordinateType::WINDOW);
+  auto rightRect = rhs->GetExtents(CoordinateType::WINDOW);
 
   return leftRect.x < rightRect.x;
 }
@@ -52,7 +52,7 @@ std::vector<std::vector<Component*>> SplitLines(const std::vector<Component*>& c
 {
   // Find first with non-zero area
   auto first = std::find_if(children.begin(), children.end(), [](Component* component) -> bool {
-    auto extents = component->GetExtents(CoordType::WINDOW);
+    auto extents = component->GetExtents(CoordinateType::WINDOW);
     return extents.height != 0.0f && extents.width != 0.0f;
   });
 
@@ -62,7 +62,7 @@ std::vector<std::vector<Component*>> SplitLines(const std::vector<Component*>& c
   }
 
   std::vector<std::vector<Component*>> lines(1);
-  Dali::Rect<> lineRect = (*first)->GetExtents(CoordType::WINDOW);
+  Dali::Rect<> lineRect = (*first)->GetExtents(CoordinateType::WINDOW);
   Dali::Rect<> rect;
 
   // Split into lines
@@ -70,7 +70,7 @@ std::vector<std::vector<Component*>> SplitLines(const std::vector<Component*>& c
   {
     auto child = *it;
 
-    rect = child->GetExtents(CoordType::WINDOW);
+    rect = child->GetExtents(CoordinateType::WINDOW);
     if(rect.height == 0.0f || rect.width == 0.0f)
     {
       // Zero area, ignore
@@ -164,11 +164,11 @@ static bool ObjectIsCollapsed(Component* obj)
   return states[State::EXPANDABLE] && !states[State::EXPANDED];
 }
 
-static bool OobjectIsZeroSize(Component* obj)
+static bool ObjectIsZeroSize(Component* obj)
 {
   if(!obj)
     return false;
-  auto extents = obj->GetExtents(CoordType::WINDOW);
+  auto extents = obj->GetExtents(CoordinateType::WINDOW);
   return extents.height == 0 || extents.width == 0;
 }
 
@@ -195,7 +195,7 @@ static bool AcceptObject(Component* obj)
   }
   else
   {
-    if(OobjectIsZeroSize(obj))
+    if(ObjectIsZeroSize(obj))
     {
       return false;
     }
@@ -218,7 +218,7 @@ static std::string objDump(Component* obj)
   if(!obj)
     return "nullptr";
   std::ostringstream o;
-  auto               e = obj->GetExtents(CoordType::SCREEN);
+  auto               e = obj->GetExtents(CoordinateType::SCREEN);
   o << "name: " << obj->GetName() << " extent: (" << e.x << ", "
     << e.y << "), [" << e.width << ", " << e.height << "]";
   return o.str();
@@ -248,30 +248,40 @@ static std::string makeIndent(unsigned int maxRecursionDepth)
   return std::string(GET_NAVIGABLE_AT_POINT_MAX_RECURSION_DEPTH - maxRecursionDepth, ' ');
 }
 
-Component* BridgeAccessible::CalculateNavigableAccessibleAtPoint(Accessible* root, Point p, CoordType cType, unsigned int maxRecursionDepth)
+Component* BridgeAccessible::CalculateNavigableAccessibleAtPoint(Accessible* root, Point p, CoordinateType type, unsigned int maxRecursionDepth)
 {
   if(!root || maxRecursionDepth == 0)
+  {
     return nullptr;
+  }
+
   auto root_component = dynamic_cast<Component*>(root);
   LOG() << "CalculateNavigableAccessibleAtPoint: checking: " << makeIndent(maxRecursionDepth) << objDump(root_component);
 
-  if(root_component && !root_component->Contains(p, cType))
+  if(root_component && !root_component->IsAccessibleContainedAtPoint(p, type))
+  {
     return nullptr;
+  }
 
   auto children = root->GetChildren();
   for(auto childIt = children.rbegin(); childIt != children.rend(); childIt++)
   {
     //check recursively all children first
-    auto result = CalculateNavigableAccessibleAtPoint(*childIt, p, cType, maxRecursionDepth - 1);
+    auto result = CalculateNavigableAccessibleAtPoint(*childIt, p, type, maxRecursionDepth - 1);
     if(result)
+    {
       return result;
+    }
   }
+
   if(root_component)
   {
     //Found a candidate, all its children are already checked
     auto controledBy = GetObjectInRelation(root_component, RelationType::CONTROLLED_BY);
     if(!controledBy)
+    {
       controledBy = root_component;
+    }
 
     if(controledBy->IsProxy() || AcceptObject(controledBy))
     {
@@ -376,12 +386,12 @@ DBus::ValueOrError<bool> BridgeAccessible::DoGesture(Dali::Accessibility::Gestur
   return FindSelf()->DoGesture(Dali::Accessibility::GestureInfo{type, xBeg, xEnd, yBeg, yEnd, state, eventTime});
 }
 
-DBus::ValueOrError<Accessible*, uint8_t, Accessible*> BridgeAccessible::GetNavigableAtPoint(int32_t x, int32_t y, uint32_t coordType)
+DBus::ValueOrError<Accessible*, uint8_t, Accessible*> BridgeAccessible::GetNavigableAtPoint(int32_t x, int32_t y, uint32_t coordinateType)
 {
   Accessible* deputy     = nullptr;
   auto        accessible = FindSelf();
-  auto        cType      = static_cast<CoordType>(coordType);
-  LOG() << "GetNavigableAtPoint: " << x << ", " << y << " type: " << coordType;
+  auto        cType      = static_cast<CoordinateType>(coordinateType);
+  LOG() << "GetNavigableAtPoint: " << x << ", " << y << " type: " << coordinateType;
   auto component = CalculateNavigableAccessibleAtPoint(accessible, {x, y}, cType, GET_NAVIGABLE_AT_POINT_MAX_RECURSION_DEPTH);
   bool recurse   = false;
   if(component)
index d5bdc52..255dc44 100644 (file)
@@ -56,7 +56,7 @@ public:
   DBus::ValueOrError<std::array<uint32_t, 2>>                                                                  GetStates();
   DBus::ValueOrError<std::unordered_map<std::string, std::string>>                                             GetAttributes();
   DBus::ValueOrError<std::vector<std::string>>                                                                 GetInterfaces();
-  DBus::ValueOrError<Dali::Accessibility::Accessible*, uint8_t, Dali::Accessibility::Accessible*>              GetNavigableAtPoint(int32_t x, int32_t y, uint32_t coordType);
+  DBus::ValueOrError<Dali::Accessibility::Accessible*, uint8_t, Dali::Accessibility::Accessible*>              GetNavigableAtPoint(int32_t x, int32_t y, uint32_t coordinateType);
   DBus::ValueOrError<Dali::Accessibility::Accessible*, uint8_t>                                                GetNeighbor(std::string root_path, int32_t direction, int32_t search_mode);
   DBus::ValueOrError<Dali::Accessibility::Accessible*, uint32_t, std::unordered_map<std::string, std::string>> GetDefaultLabelInfo();
   using ReadingMaterialType = DBus::ValueOrError<
@@ -100,7 +100,7 @@ private:
   Dali::Accessibility::Accessible*              GetCurrentlyHighlighted();
   Dali::Accessibility::Accessible*              DirectionalDepthFirstSearchTryNonDefunctSibling(bool& all_children_visited, Dali::Accessibility::Accessible* node, Dali::Accessibility::Accessible* start, Dali::Accessibility::Accessible* root, unsigned char forward);
   Dali::Accessibility::Accessible*              GetNextNonDefunctSibling(Dali::Accessibility::Accessible* obj, Dali::Accessibility::Accessible* start, Dali::Accessibility::Accessible* root, unsigned char forward);
-  Dali::Accessibility::Component*               CalculateNavigableAccessibleAtPoint(Dali::Accessibility::Accessible* root, Dali::Accessibility::Point p, Dali::Accessibility::CoordType cType, unsigned int maxRecursionDepth);
+  Dali::Accessibility::Component*               CalculateNavigableAccessibleAtPoint(Dali::Accessibility::Accessible* root, Dali::Accessibility::Point p, Dali::Accessibility::CoordinateType type, unsigned int maxRecursionDepth);
   Dali::Accessibility::Component*               GetObjectInRelation(Dali::Accessibility::Accessible* obj, Dali::Accessibility::RelationType ralationType);
 };
 
index 3c1ca0b..1e47300 100644 (file)
@@ -126,7 +126,7 @@ BridgeBase::ForceUpResult BridgeBase::ForceUp()
   }
 
   con           = DBusWrapper::Installed()->eldbus_address_connection_get_impl(std::get<0>(addr));
-  data->busName = DBus::getConnectionName(con);
+  mData->mBusName = DBus::getConnectionName(con);
   dbusServer    = {con};
 
   {
@@ -166,7 +166,7 @@ void BridgeBase::ForceDown()
 const std::string& BridgeBase::GetBusName() const
 {
   static std::string empty;
-  return data ? data->busName : empty;
+  return mData ? mData->mBusName : empty;
 }
 
 Accessible* BridgeBase::FindByPath(const std::string& name) const
@@ -181,22 +181,22 @@ Accessible* BridgeBase::FindByPath(const std::string& name) const
   }
 }
 
-void BridgeBase::AddPopup(Accessible* obj)
+void BridgeBase::AddPopup(Accessible* object)
 {
-  if(std::find(popups.begin(), popups.end(), obj) != popups.end())
+  if(std::find(popups.begin(), popups.end(), object) != popups.end())
   {
     return;
   }
-  popups.push_back(obj);
+  popups.push_back(object);
   if(IsUp())
   {
-    obj->Emit(WindowEvent::ACTIVATE, 0);
+    object->Emit(WindowEvent::ACTIVATE, 0);
   }
 }
 
-void BridgeBase::RemovePopup(Accessible* obj)
+void BridgeBase::RemovePopup(Accessible* object)
 {
-  auto it = std::find(popups.begin(), popups.end(), obj);
+  auto it = std::find(popups.begin(), popups.end(), object);
   if(it == popups.end())
   {
     return;
@@ -204,7 +204,7 @@ void BridgeBase::RemovePopup(Accessible* obj)
   popups.erase(it);
   if(IsUp())
   {
-    obj->Emit(WindowEvent::DEACTIVATE, 0);
+    object->Emit(WindowEvent::DEACTIVATE, 0);
     if(popups.empty())
     {
       application.children.back()->Emit(WindowEvent::ACTIVATE, 0);
@@ -246,43 +246,46 @@ Accessible* BridgeBase::Find(const std::string& path) const
   {
     return &application;
   }
-  void*              p;
+
+  void* accessible;
   std::istringstream tmp{path};
-  if(!(tmp >> p))
+  if(!(tmp >> accessible))
   {
     throw std::domain_error{"invalid path '" + path + "'"};
   }
-  auto it = data->knownObjects.find(static_cast<Accessible*>(p));
-  if(it == data->knownObjects.end())
+
+  auto it = mData->mKnownObjects.find(static_cast<Accessible*>(accessible));
+  if(it == mData->mKnownObjects.end())
   {
     throw std::domain_error{"unknown object '" + path + "'"};
   }
-  return static_cast<Accessible*>(p);
+
+  return static_cast<Accessible*>(accessible);
 }
 
 Accessible* BridgeBase::Find(const Address& ptr) const
 {
-  assert(ptr.GetBus() == data->busName);
+  assert(ptr.GetBus() == mData->mBusName);
   return Find(ptr.GetPath());
 }
 
 Accessible* BridgeBase::FindSelf() const
 {
-  auto pth  = DBus::DBusServer::getCurrentObjectPath();
+  auto path  = DBus::DBusServer::getCurrentObjectPath();
   auto size = strlen(AtspiPath);
-  if(pth.size() <= size)
+  if(path.size() <= size)
   {
-    throw std::domain_error{"invalid path '" + pth + "'"};
+    throw std::domain_error{"invalid path '" + path + "'"};
   }
-  if(pth.substr(0, size) != AtspiPath)
+  if(path.substr(0, size) != AtspiPath)
   {
-    throw std::domain_error{"invalid path '" + pth + "'"};
+    throw std::domain_error{"invalid path '" + path + "'"};
   }
-  if(pth[size] != '/')
+  if(path[size] != '/')
   {
-    throw std::domain_error{"invalid path '" + pth + "'"};
+    throw std::domain_error{"invalid path '" + path + "'"};
   }
-  return Find(StripPrefix(pth));
+  return Find(StripPrefix(path));
 }
 
 void BridgeBase::IdSet(int id)
index ea6c746..fa46045 100644 (file)
@@ -130,8 +130,8 @@ public:
   const std::string& GetBusName() const override;
   void               AddTopLevelWindow(Dali::Accessibility::Accessible* window) override;
   void               RemoveTopLevelWindow(Dali::Accessibility::Accessible* window) override;
-  void               AddPopup(Dali::Accessibility::Accessible*) override;
-  void               RemovePopup(Dali::Accessibility::Accessible*) override;
+  void               AddPopup(Dali::Accessibility::Accessible* object) override;
+  void               RemovePopup(Dali::Accessibility::Accessible* object) override;
 
   Dali::Accessibility::Accessible* GetApplication() const override
   {
index bd85a23..d373bcf 100644 (file)
@@ -31,8 +31,12 @@ BridgeComponent::BridgeComponent()
 
 void BridgeComponent::RegisterInterfaces()
 {
+  // The second arguments below are the names (or signatures) of DBus methods.
+  // Screen Reader will call the methods with the exact names as specified in the AT-SPI Component interface:
+  // https://gitlab.gnome.org/GNOME/at-spi2-core/-/blob/master/xml/Component.xml
+
   DBus::DBusInterfaceDescription desc{AtspiDbusInterfaceComponent};
-  AddFunctionToInterface(desc, "Contains", &BridgeComponent::Contains);
+  AddFunctionToInterface(desc, "Contains", &BridgeComponent::IsAccessibleContainedAtPoint);
   AddFunctionToInterface(desc, "GetAccessibleAtPoint", &BridgeComponent::GetAccessibleAtPoint);
   AddFunctionToInterface(desc, "GetExtents", &BridgeComponent::GetExtents);
   AddFunctionToInterface(desc, "GetPosition", &BridgeComponent::GetPosition);
@@ -56,27 +60,27 @@ Component* BridgeComponent::FindSelf() const
   return s2;
 }
 
-DBus::ValueOrError<bool> BridgeComponent::Contains(int32_t x, int32_t y, uint32_t coordType)
+DBus::ValueOrError<bool> BridgeComponent::IsAccessibleContainedAtPoint(int32_t x, int32_t y, uint32_t coordType)
 {
-  return FindSelf()->Contains({x, y}, static_cast<CoordType>(coordType));
+  return FindSelf()->IsAccessibleContainedAtPoint({x, y}, static_cast<CoordinateType>(coordType));
 }
 DBus::ValueOrError<Accessible*> BridgeComponent::GetAccessibleAtPoint(int32_t x, int32_t y, uint32_t coordType)
 {
-  return FindSelf()->GetAccessibleAtPoint({x, y}, static_cast<CoordType>(coordType));
+  return FindSelf()->GetAccessibleAtPoint({x, y}, static_cast<CoordinateType>(coordType));
 }
 DBus::ValueOrError<std::tuple<int32_t, int32_t, int32_t, int32_t> > BridgeComponent::GetExtents(uint32_t coordType)
 {
-  auto p = FindSelf()->GetExtents(static_cast<CoordType>(coordType));
+  auto p = FindSelf()->GetExtents(static_cast<CoordinateType>(coordType));
   return std::tuple<int32_t, int32_t, int32_t, int32_t>{p.x, p.y, p.width, p.height};
 }
 DBus::ValueOrError<int32_t, int32_t> BridgeComponent::GetPosition(uint32_t coordType)
 {
-  auto p = FindSelf()->GetExtents(static_cast<CoordType>(coordType));
+  auto p = FindSelf()->GetExtents(static_cast<CoordinateType>(coordType));
   return {static_cast<int32_t>(p.x), static_cast<int32_t>(p.y)};
 }
 DBus::ValueOrError<int32_t, int32_t> BridgeComponent::GetSize(uint32_t coordType)
 {
-  auto p = FindSelf()->GetExtents(static_cast<CoordType>(coordType));
+  auto p = FindSelf()->GetExtents(static_cast<CoordinateType>(coordType));
   return {static_cast<int32_t>(p.width), static_cast<int32_t>(p.height)};
 }
 DBus::ValueOrError<ComponentLayer> BridgeComponent::GetLayer()
index f073148..4231843 100644 (file)
@@ -38,7 +38,7 @@ protected:
   Dali::Accessibility::Component* FindSelf() const;
 
 public:
-  DBus::ValueOrError<bool>                                            Contains(int32_t x, int32_t y, uint32_t coordType);
+  DBus::ValueOrError<bool>                                            IsAccessibleContainedAtPoint(int32_t x, int32_t y, uint32_t coordType);
   DBus::ValueOrError<Dali::Accessibility::Accessible*>                GetAccessibleAtPoint(int32_t x, int32_t y, uint32_t coordType);
   DBus::ValueOrError<std::tuple<int32_t, int32_t, int32_t, int32_t> > GetExtents(uint32_t coordType);
   DBus::ValueOrError<int32_t, int32_t>                                GetPosition(uint32_t coordType);
index 80b3fb4..11c580e 100644 (file)
@@ -99,18 +99,18 @@ public:
       return Consumed::NO;
     }
 
-    unsigned int evType = 0;
+    unsigned int keyType = 0;
 
     switch(type)
     {
       case KeyEventType::KEY_PRESSED:
       {
-        evType = 0;
+        keyType = 0;
         break;
       }
       case KeyEventType::KEY_RELEASED:
       {
-        evType = 1;
+        keyType = 1;
         break;
       }
       default:
@@ -119,7 +119,7 @@ public:
       }
     }
     auto m      = registryClient.method<bool(std::tuple<uint32_t, int32_t, int32_t, int32_t, int32_t, std::string, bool>)>("NotifyListenersSync");
-    auto result = m.call(std::tuple<uint32_t, int32_t, int32_t, int32_t, int32_t, std::string, bool>{evType, 0, static_cast<int32_t>(keyCode), 0, static_cast<int32_t>(timeStamp), keyName, isText ? 1 : 0});
+    auto result = m.call(std::tuple<uint32_t, int32_t, int32_t, int32_t, int32_t, std::string, bool>{keyType, 0, static_cast<int32_t>(keyCode), 0, static_cast<int32_t>(timeStamp), keyName, isText ? 1 : 0});
     if(!result)
     {
       LOG() << result.getError().message;
@@ -199,14 +199,14 @@ public:
 
   void ForceDown() override
   {
-    if(data)
+    if(mData)
     {
-      if(data->currentlyHighlightedActor && data->highlightActor)
+      if(mData->mCurrentlyHighlightedActor && mData->mHighlightActor)
       {
-        data->currentlyHighlightedActor.Remove(data->highlightActor);
+        mData->mCurrentlyHighlightedActor.Remove(mData->mHighlightActor);
       }
-      data->currentlyHighlightedActor = {};
-      data->highlightActor            = {};
+      mData->mCurrentlyHighlightedActor = {};
+      mData->mHighlightActor            = {};
     }
     highlightedActor     = {};
     highlightClearAction = {};
@@ -218,10 +218,10 @@ public:
 
   void Terminate() override
   {
-    if(data)
+    if(mData)
     {
-      data->currentlyHighlightedActor = {};
-      data->highlightActor            = {};
+      mData->mCurrentlyHighlightedActor = {};
+      mData->mHighlightActor            = {};
     }
     ForceDown();
     listenOnAtspiEnabledSignalClient = {};
@@ -314,17 +314,19 @@ public:
 
   void Initialize() override
   {
-    auto req = DBus::DBusClient{A11yDbusName, A11yDbusPath, A11yDbusStatusInterface, DBus::ConnectionType::SESSION};
-    auto p   = req.property<bool>("ScreenReaderEnabled").get();
-    if(p)
+    auto dbusClient = DBus::DBusClient{A11yDbusName, A11yDbusPath, A11yDbusStatusInterface, DBus::ConnectionType::SESSION};
+    auto enabled = dbusClient.property<bool>("ScreenReaderEnabled").get();
+    if(enabled)
     {
-      screenReaderEnabled = std::get<0>(p);
+      screenReaderEnabled = std::get<0>(enabled);
     }
-    p = req.property<bool>("IsEnabled").get();
-    if(p)
+
+    enabled = dbusClient.property<bool>("IsEnabled").get();
+    if(enabled)
     {
-      isEnabled = std::get<0>(p);
+      isEnabled = std::get<0>(enabled);
     }
+
     if(screenReaderEnabled || isEnabled)
     {
       ForceUp();
@@ -336,7 +338,7 @@ public:
     return screenReaderEnabled;
   }
 
-  bool GetIsEnabled()
+  bool IsEnabled()
   {
     return isEnabled;
   }
index 06bb80d..a0c157d 100644 (file)
@@ -111,11 +111,11 @@ void BridgeObject::Emit(Accessible* obj, Dali::Accessibility::ObjectPropertyChan
   }
 }
 
-void BridgeObject::Emit(Accessible* obj, WindowEvent we, unsigned int detail1)
+void BridgeObject::Emit(Accessible* obj, WindowEvent event, unsigned int detail)
 {
   if(!IsUp()) return;
   const char* name = nullptr;
-  switch(we)
+  switch(event)
   {
     case WindowEvent::PROPERTY_CHANGE:
     {
@@ -226,14 +226,14 @@ void BridgeObject::Emit(Accessible* obj, WindowEvent we, unsigned int detail1)
       AtspiDbusInterfaceEventWindow,
       name,
       "",
-      detail1,
+      detail,
       0,
       {0},
       {"", "root"});
   }
 }
 
-void BridgeObject::EmitStateChanged(Accessible* obj, State state, int newValue1, int newValue2)
+void BridgeObject::EmitStateChanged(Accessible* obj, State state, int newValue, int reserved)
 {
   if(!IsUp()) return;
   const char* stateName = nullptr;
@@ -487,8 +487,8 @@ void BridgeObject::EmitStateChanged(Accessible* obj, State state, int newValue1,
       AtspiDbusInterfaceEventObject,
       "StateChanged",
       stateName,
-      newValue1,
-      newValue2,
+      newValue,
+      reserved,
       {0},
       {"", "root"});
   }
@@ -521,7 +521,7 @@ void BridgeObject::EmitBoundsChanged(Accessible* obj, Dali::Rect<> rect)
   });
 }
 
-void BridgeObject::EmitCaretMoved(Accessible* obj, unsigned int cursorPosition)
+void BridgeObject::EmitCursorMoved(Accessible* obj, unsigned int cursorPosition)
 {
   auto        addr = obj->GetAddress();
   std::string p    = addr ? ATSPI_PREFIX_PATH + addr.GetPath() : ATSPI_NULL_PATH;
index d2b980d..f836c20 100644 (file)
@@ -38,10 +38,10 @@ protected:
   DBus::DBusInterfaceDescription::SignalId stateChanged;
 
   void EmitActiveDescendantChanged(Dali::Accessibility::Accessible* obj, Dali::Accessibility::Accessible* child) override;
-  void EmitCaretMoved(Dali::Accessibility::Accessible* obj, unsigned int cursorPosition) override;
+  void EmitCursorMoved(Dali::Accessibility::Accessible* obj, unsigned int cursorPosition) override;
   void EmitTextChanged(Dali::Accessibility::Accessible* obj, Dali::Accessibility::TextChangedState state, unsigned int position, unsigned int length, const std::string& content) override;
-  void EmitStateChanged(Dali::Accessibility::Accessible* obj, Dali::Accessibility::State state, int val1, int val2) override;
-  void Emit(Dali::Accessibility::Accessible* obj, Dali::Accessibility::WindowEvent we, unsigned int detail1) override;
+  void EmitStateChanged(Dali::Accessibility::Accessible* obj, Dali::Accessibility::State state, int newValue, int reserved) override;
+  void Emit(Dali::Accessibility::Accessible* obj, Dali::Accessibility::WindowEvent event, unsigned int detail) override;
   void Emit(Dali::Accessibility::Accessible* obj, Dali::Accessibility::ObjectPropertyChangeEvent we) override;
   void EmitBoundsChanged(Dali::Accessibility::Accessible* obj, Dali::Rect<> rect) override;
 };
index 8bcd277..9ca694c 100644 (file)
@@ -25,26 +25,32 @@ using namespace Dali::Accessibility;
 
 void BridgeText::RegisterInterfaces()
 {
+  // The second arguments below are the names (or signatures) of DBus methods.
+  // Screen Reader will call the methods with the exact names as specified in the AT-SPI Text interface:
+  // https://gitlab.gnome.org/GNOME/at-spi2-core/-/blob/master/xml/Text.xml
+
   DBus::DBusInterfaceDescription desc{AtspiDbusInterfaceText};
   AddFunctionToInterface(desc, "GetText", &BridgeText::GetText);
   AddGetPropertyToInterface(desc, "CharacterCount", &BridgeText::GetCharacterCount);
-  AddGetPropertyToInterface(desc, "CaretOffset", &BridgeText::GetCaretOffset);
-  AddFunctionToInterface(desc, "SetCaretOffset", &BridgeText::SetCaretOffset);
+  AddGetPropertyToInterface(desc, "CaretOffset", &BridgeText::GetCursorOffset);
+  AddFunctionToInterface(desc, "SetCaretOffset", &BridgeText::SetCursorOffset);
   AddFunctionToInterface(desc, "GetTextAtOffset", &BridgeText::GetTextAtOffset);
-  AddFunctionToInterface(desc, "GetSelection", &BridgeText::GetSelection);
-  AddFunctionToInterface(desc, "SetSelection", &BridgeText::SetSelection);
+  AddFunctionToInterface(desc, "GetSelection", &BridgeText::GetRangeOfSelection);
+  AddFunctionToInterface(desc, "SetSelection", &BridgeText::SetRangeOfSelection);
   AddFunctionToInterface(desc, "RemoveSelection", &BridgeText::RemoveSelection);
   dbusServer.addInterface("/", desc, true);
 }
 
 Text* BridgeText::FindSelf() const
 {
-  auto s = BridgeBase::FindSelf();
-  assert(s);
-  auto s2 = dynamic_cast<Text*>(s);
-  if(!s2)
-    throw std::domain_error{"object " + s->GetAddress().ToString() + " doesn't have Text interface"};
-  return s2;
+  auto self = BridgeBase::FindSelf();
+  assert(self);
+  auto textObject = dynamic_cast<Text*>(self);
+  if(!textObject)
+  {
+    throw std::domain_error{"object " + textObject->GetAddress().ToString() + " doesn't have Text interface"};
+  }
+  return textObject;
 }
 
 DBus::ValueOrError<std::string> BridgeText::GetText(int startOffset, int endOffset)
@@ -57,26 +63,26 @@ DBus::ValueOrError<int32_t> BridgeText::GetCharacterCount()
   return FindSelf()->GetCharacterCount();
 }
 
-DBus::ValueOrError<int32_t> BridgeText::GetCaretOffset()
+DBus::ValueOrError<int32_t> BridgeText::GetCursorOffset()
 {
-  return FindSelf()->GetCaretOffset();
+  return FindSelf()->GetCursorOffset();
 }
 
-DBus::ValueOrError<bool> BridgeText::SetCaretOffset(int32_t offset)
+DBus::ValueOrError<bool> BridgeText::SetCursorOffset(int32_t offset)
 {
-  return FindSelf()->SetCaretOffset(offset);
+  return FindSelf()->SetCursorOffset(offset);
 }
 
 DBus::ValueOrError<std::string, int, int> BridgeText::GetTextAtOffset(int32_t offset, uint32_t boundary)
 {
-  auto r = FindSelf()->GetTextAtOffset(offset, static_cast<TextBoundary>(boundary));
-  return {r.content, static_cast<int>(r.startOffset), static_cast<int>(r.endOffset)};
+  auto range = FindSelf()->GetTextAtOffset(offset, static_cast<TextBoundary>(boundary));
+  return {range.content, static_cast<int>(range.startOffset), static_cast<int>(range.endOffset)};
 }
 
-DBus::ValueOrError<int, int> BridgeText::GetSelection(int32_t selectionNum)
+DBus::ValueOrError<int, int> BridgeText::GetRangeOfSelection(int32_t selectionNum)
 {
-  auto r = FindSelf()->GetSelection(selectionNum);
-  return {static_cast<int>(r.startOffset), static_cast<int>(r.endOffset)};
+  auto range = FindSelf()->GetRangeOfSelection(selectionNum);
+  return {static_cast<int>(range.startOffset), static_cast<int>(range.endOffset)};
 }
 
 DBus::ValueOrError<bool> BridgeText::RemoveSelection(int32_t selectionNum)
@@ -84,7 +90,7 @@ DBus::ValueOrError<bool> BridgeText::RemoveSelection(int32_t selectionNum)
   return FindSelf()->RemoveSelection(selectionNum);
 }
 
-DBus::ValueOrError<bool> BridgeText::SetSelection(int32_t selectionNum, int32_t startOffset, int32_t endOffset)
+DBus::ValueOrError<bool> BridgeText::SetRangeOfSelection(int32_t selectionNum, int32_t startOffset, int32_t endOffset)
 {
-  return FindSelf()->SetSelection(selectionNum, startOffset, endOffset);
+  return FindSelf()->SetRangeOfSelection(selectionNum, startOffset, endOffset);
 }
index 7618b28..86c33d2 100644 (file)
@@ -33,12 +33,12 @@ protected:
 public:
   DBus::ValueOrError<std::string>           GetText(int startOffset, int endOffset);
   DBus::ValueOrError<int32_t>               GetCharacterCount();
-  DBus::ValueOrError<int32_t>               GetCaretOffset();
-  DBus::ValueOrError<bool>                  SetCaretOffset(int32_t offset);
+  DBus::ValueOrError<int32_t>               GetCursorOffset();
+  DBus::ValueOrError<bool>                  SetCursorOffset(int32_t offset);
   DBus::ValueOrError<std::string, int, int> GetTextAtOffset(int32_t offset, uint32_t boundary);
-  DBus::ValueOrError<int, int>              GetSelection(int32_t selectionNum);
+  DBus::ValueOrError<int, int>              GetRangeOfSelection(int32_t selectionNum);
   DBus::ValueOrError<bool>                  RemoveSelection(int32_t selectionNum);
-  DBus::ValueOrError<bool>                  SetSelection(int32_t selectionNum, int32_t startOffset, int32_t endOffset);
+  DBus::ValueOrError<bool>                  SetRangeOfSelection(int32_t selectionNum, int32_t startOffset, int32_t endOffset);
 };
 
 #endif // DALI_INTERNAL_ACCESSIBILITY_BRIDGE_TEXT_H
index 7e85d56..a94df86 100644 (file)
 
 using namespace Dali::Accessibility;
 
-bool Component::Contains(Point p, CoordType ctype)
+bool Component::IsAccessibleContainedAtPoint(Point point, Dali::Accessibility::CoordinateType type)
 {
-  auto extents = GetExtents(ctype);
-  return p.x >= extents.x && p.y >= extents.y && p.x <= extents.x + extents.width && p.y <= extents.y + extents.height;
+  auto extents = GetExtents(type);
+  return point.x >= extents.x && point.y >= extents.y && point.x <= extents.x + extents.width && point.y <= extents.y + extents.height;
 }
 
-Accessible* Component::GetAccessibleAtPoint(Point p, CoordType ctype)
+Accessible* Component::GetAccessibleAtPoint(Point point, Dali::Accessibility::CoordinateType type)
 {
   auto children = GetChildren();
   for(auto childIt = children.rbegin(); childIt != children.rend(); childIt++)
   {
     auto component = dynamic_cast<Component*>(*childIt);
-    if(component && component->Contains(p, ctype))
+    if(component && component->IsAccessibleContainedAtPoint(point, type))
     {
       return component;
     }
index 71cdb5e..716a2e7 100644 (file)
@@ -59,12 +59,12 @@ bool Accessibility::Component::IsScrollable()
   return false;
 }
 
-bool Accessibility::Component::Contains(Point p, CoordType ctype)
+bool Accessibility::Component::IsAccessibleContainedAtPoint(Point point, CoordinateType type)
 {
   return false;
 }
 
-Accessibility::Accessible* Accessibility::Component::GetAccessibleAtPoint(Accessibility::Point p, Accessibility::CoordType ctype)
+Accessibility::Accessible* Accessibility::Component::GetAccessibleAtPoint(Accessibility::Point p, Accessibility::CoordinateType ctype)
 {
   return nullptr;
 }
@@ -82,7 +82,7 @@ void Accessibility::Bridge::EnableAutoInit()
 {
 }
 
-void Accessibility::Accessible::EmitStateChanged(Accessibility::State state, int newValue1, int newValue2)
+void Accessibility::Accessible::EmitStateChanged(Accessibility::State state, int newValue, int reserved)
 {
 }
 
@@ -118,7 +118,7 @@ void Accessibility::Accessible::EmitTextDeleted(unsigned int position, unsigned
 {
 }
 
-void Accessibility::Accessible::EmitTextCaretMoved(unsigned int cursorPosition)
+void Accessibility::Accessible::EmitTextCursorMoved(unsigned int cursorPosition)
 {
 }
 
@@ -126,15 +126,15 @@ void Accessibility::Accessible::EmitActiveDescendantChanged(Accessibility::Acces
 {
 }
 
-void Accessibility::Accessible::FindWordSeparationsUtf8(const utf8_t* s, size_t length, const char* language, char* breaks)
+void Accessibility::Accessible::FindWordSeparationsUtf8(const utf8_t* string, size_t length, const char* language, char* breaks)
 {
 }
 
-void Accessibility::Accessible::FindLineSeparationsUtf8(const utf8_t* s, size_t length, const char* language, char* breaks)
+void Accessibility::Accessible::FindLineSeparationsUtf8(const utf8_t* string, size_t length, const char* language, char* breaks)
 {
 }
 
-void Accessibility::Accessible::NotifyAccessibilityStateChange(Accessibility::States states, bool doRecursive)
+void Accessibility::Accessible::NotifyAccessibilityStateChange(Accessibility::States states, bool isRecursive)
 {
 }
 
index bf93553..f48e878 100644 (file)
@@ -35,23 +35,23 @@ struct DummyBridge : Dali::Accessibility::Bridge
     return name;
   }
 
-  void AddTopLevelWindow(Accessibility::Accessible*) override
+  void AddTopLevelWindow(Accessibility::Accessible* object) override
   {
   }
 
-  void RemoveTopLevelWindow(Accessibility::Accessible*) override
+  void RemoveTopLevelWindow(Accessibility::Accessible* object) override
   {
   }
 
-  void AddPopup(Accessibility::Accessible*) override
+  void AddPopup(Accessibility::Accessible* object) override
   {
   }
 
-  void RemovePopup(Accessibility::Accessible*) override
+  void RemovePopup(Accessibility::Accessible* object) override
   {
   }
 
-  void SetApplicationName(std::string) override
+  void SetApplicationName(std::string name) override
   {
   }
 
@@ -60,7 +60,7 @@ struct DummyBridge : Dali::Accessibility::Bridge
     return nullptr;
   }
 
-  Accessibility::Accessible* FindByPath(const std::string& s) const override
+  Accessibility::Accessible* FindByPath(const std::string& path) const override
   {
     return nullptr;
   }
@@ -90,7 +90,7 @@ struct DummyBridge : Dali::Accessibility::Bridge
   {
   }
 
-  void EmitCaretMoved(Accessibility::Accessible* obj, unsigned int cursorPosition) override
+  void EmitCursorMoved(Accessibility::Accessible* obj, unsigned int cursorPosition) override
   {
   }
 
@@ -102,11 +102,11 @@ struct DummyBridge : Dali::Accessibility::Bridge
   {
   }
 
-  void EmitStateChanged(Accessibility::Accessible* obj, Accessibility::State state, int val1, int val2) override
+  void EmitStateChanged(Accessibility::Accessible* obj, Accessibility::State state, int newValue, int reserved) override
   {
   }
 
-  void Emit(Accessibility::Accessible* obj, Accessibility::WindowEvent we, unsigned int detail1) override
+  void Emit(Accessibility::Accessible* obj, Accessibility::WindowEvent event, unsigned int detail) override
   {
   }
 
@@ -148,7 +148,7 @@ struct DummyBridge : Dali::Accessibility::Bridge
     return false;
   }
 
-  bool GetIsEnabled() override
+  bool IsEnabled() override
   {
     return false;
   }
index c849f93..6338359 100644 (file)
@@ -308,7 +308,7 @@ void Adaptor::Initialize(GraphicsFactory& graphicsFactory)
   auto bridge  = Accessibility::Bridge::GetCurrentBridge();
   bridge->SetApplicationName(appName);
   bridge->Initialize();
-  Dali::Stage::GetCurrent().KeyEventSignal().Connect(&accessibilityObserver, &AccessibilityObserver::OnAccessibleKeyEvent);
+  Dali::Stage::GetCurrent().KeyEventSignal().Connect(&mAccessibilityObserver, &AccessibilityObserver::OnAccessibleKeyEvent);
 }
 
 void Adaptor::AccessibilityObserver::OnAccessibleKeyEvent(const Dali::KeyEvent& event)
index b69ad05..331ab9a 100644 (file)
@@ -691,7 +691,7 @@ private:                                          // Data
   public:
     void OnAccessibleKeyEvent(const Dali::KeyEvent& event);
   };
-  AccessibilityObserver accessibilityObserver;
+  AccessibilityObserver mAccessibilityObserver;
 
 public:
   inline static Adaptor& GetImplementation(Dali::Adaptor& adaptor)
index 0aa1cb1..44f8b66 100644 (file)
@@ -100,8 +100,8 @@ Window::~Window()
   if(mAdaptor)
   {
     auto bridge      = Accessibility::Bridge::GetCurrentBridge();
-    auto accessible2 = mScene.GetRootLayer();
-    auto accessible  = Accessibility::Accessible::Get(accessible2);
+    auto rootLayer = mScene.GetRootLayer();
+    auto accessible  = Accessibility::Accessible::Get(rootLayer);
     bridge->RemoveTopLevelWindow(accessible);
 
     mAdaptor->RemoveWindow(this);
@@ -171,8 +171,8 @@ void Window::OnAdaptorSet(Dali::Adaptor& adaptor)
   mEventHandler->AddObserver(*this);
 
   auto bridge     = Accessibility::Bridge::GetCurrentBridge();
-  auto v          = mScene.GetRootLayer();
-  auto accessible = Accessibility::Accessible::Get(v, true);
+  auto rootLayer  = mScene.GetRootLayer();
+  auto accessible = Accessibility::Accessible::Get(rootLayer, true);
   bridge->AddTopLevelWindow(accessible);
 
   // If you call the 'Show' before creating the adaptor, the application cannot know the app resource id.
@@ -746,15 +746,15 @@ void Window::OnFocusChanged(bool focusIn)
 
   mSurface->SetFullSwapNextFrame();
 
-  if(auto b = Dali::Accessibility::Bridge::GetCurrentBridge())
+  if(auto bridge = Dali::Accessibility::Bridge::GetCurrentBridge())
   {
     if(focusIn)
     {
-      b->ApplicationShown();
+      bridge->ApplicationShown();
     }
     else
     {
-      b->ApplicationHidden();
+      bridge->ApplicationHidden();
     }
   }
 }